0

I am getting this error....

Parse error: syntax error, unexpected '*' in /home/digital/public_html/administrator/components/com_myblog/admin.myblog.php on line 206

Here is the code: <MOVED TO ATTACHED AS IT IS BREAKING VIEW IN FIREFOX>

End of Code

I am not sure why I am getting the above error any help would be great...

Thaks

Attachments
<?php

(defined('_VALID_MOS') OR defined('_JEXEC')) or die('Direct Access to this location is not allowed.');



global $sectionid, $database, $_MY_CONFIG, $section, $catid, $jax, $sections, $mainframe;

include_once(dirname(dirname(dirname(dirname(__FILE__)))) . '/components/libraries/cmslib/spframework.php');



$cms  =& cmsInstance('CMSCore');

$cms->load('helper', 'url');





require_once($cms->get_path('root').'/components/com_myblog/defines.myblog.php');



if(cmsVersion() == _CMS_JOOMLA10 || cmsVersion() == _CMS_MAMBO){

	include_once($cms->get_path('root') . '/includes/sef.php');

}elseif(cmsVersion() == _CMS_JOOMLA15){

	//include_once($cms->get_path('root') . '/plugins/system/sef.php');

}



if(!class_exists('AzrulJXCachedTemplate'))

	include_once($cms->get_path('plugins') . '/system/pc_includes/template.php');



if(!defined('JAX_SITE_ROOT'))

	require_once ($cms->get_path('plugins') . '/system/pc_includes/ajax.php');



require_once ($cms->get_path('root') . '/components/com_myblog/functions.myblog.php');

require_once ($cms->get_path('root') . "/administrator/components/com_myblog/config.myblog.php");

require_once ($cms->get_path('root') . "/administrator/components/com_myblog/functions.admin.php");





$_MY_CONFIG = new MYBLOG_Config();



$sectionid = $_MY_CONFIG->sectionid;

$catid = $_MY_CONFIG->catid;

$sections = $_MY_CONFIG->get('managedSections');



if ($sections == "")

	$sections = "-1";

	

$jax = new JAX($cms->get_path('plugin-live') . "/system/pc_includes");

$jax->setReqURI($cms->get_path('live') . "/administrator/index2.php");

if(@isset($_REQUEST['task']) && ($_REQUEST['task'] == 'azrul_ajax')){

	// Only include ajax file if needed

	require_once('ajax.myblog.php');

}

$jax->process();



$cid = cmsGetVar('cid', 0,'REQUEST');

$task = cmsGetVar('task', '', 'POST');

$title = '';



if (empty ($task)){

	$task = cmsGetVar('task' ,'comments', 'GET');

}





if ($task == "xajax") {

	showAjaxedAdmin();

} else {

	ob_start();

	showAjaxedAdmin($task);

	$panel = ob_get_contents();

	ob_end_clean();

	ob_start();



	$content = '';

	$title = '';

	switch ($task) {

		case "config" :

			if(cmsVersion() != _CMS_JOOMLA15)

				$title = 'Configuration';

			showConfig();

			break;



		case "savesettings" :

			saveConfig();

			break;



		case "license":

			if(cmsVersion() != _CMS_JOOMLA15)

				$title = 'License Agreement';

			showLicense();

			break;



		case "info" :

			showInfo();

			break;

		

		case "publish" :

		case "publishEntries" :

			publishBlog($cid, 1, $option);

			break;

		

		case "unpublish" :

		case "unpublishEntries" :

			publishBlog($cid, 0, $option);

			break;



		case "publishBots" :

			publishBots($cid, 1, $option);

			break;



		case "unpublishBots" :

			publishBots($cid, 0, $option);

			break;



		case "publishMambots" :

			publishMambots($cid, 1, $option);

			break;



		case "unpublishMambots" :

			publishMambots($cid, 0, $option);

			break;



		case "addBot" :

			addBot();

			break;



		case "saveBot" :

			saveBot();

			break;



		case "deleteBots" :

			deleteBots($cid, $option);

			break;



		case "frontpage" :

			frontpageBlog($cid, 1, $option);

			break;



		case "unfrontpage" :

			frontpageBlog($cid, 0, $option);

			break;



		case "category" :

			if(cmsVersion() != _CMS_JOOMLA15)

				$title = 'Manage Tags';

			showCategories();

			break;



		case "about" :

			showAbout();

			break;



// 		case "bots" :

// 

// 			showBots();

// 			break;



		case "orderup" :

		case "orderdown" :

			orderBot(intval($cid[0]), ($task == 'orderup' ? -1 : 1), $option, $client);

			break;



		case "install" :

			showInstallWizard();

			break;



		case "saveInstall" :

			saveInstall();

			break;



		case "exitInstall" :

			cmsRedirect("index2.php?option=com_myblog", "Installation complete.Thank you for using MyBlog!");

			break;

		

		case "remove":

		case "deleteEntries" :

			removeBlogs($cid);

			break;



		case "contentmambots" :

			if(cmsVersion() != _CMS_JOOMLA15)

				$title = 'Content mambots integration';

			showMambots();

			break;



		case "maintenance":

			if(cmsVersion() != _CMS_JOOMLA15)

				$title = 'Maintenance';

			showMaintenance();

			break;



		case "fixlinks":

			myFixLinks();

			cmsRedirect("index2.php?option=$option&task=maintenance", "$new_permalinks new permalinks added. $modified_permalinks permalinks modified.");

			break;

		case "clearcache":

		    myClearCache();

		    cmsRedirect('index2.php?option=com_myblog&task=maintenance', 'Cache cleared.');

		    break;

		case 'fixdashboardlinks':

			myFixDashboardLinks();

			cmsRedirect("index2.php?option=$option&task=maintenance", "My Blog dashboard link fixed.");

			break;



		case "fixIntrotext":

			fixIntrotext();

			break;

/*		case 'latestnews':

			/**

		     * Show latest news for My Blog

		     **/

		    if(cmsVersion() != _CMS_JOOMLA15)

		    	$title = "Latest updates";

			showLatestNews();

			break;*/

		case 'dashboard':

			/**

		     * Show dashboard

		     **/

			//showDashboard();

			showNewDashboard();

			break;

		case "blogs" :

		default :

			if(cmsVersion() != _CMS_JOOMLA15)

				$title = 'List blog entries';

			showBlogs();

			break;

	}



	$content = ob_get_contents();

	ob_end_clean();

	$content = str_replace(array('{CONTENT}', '{TITLE}'), array($content, $title), $panel);

	echo $content;

}





function _recreateTables() {

	global $database, $option;



	$db =& cmsInstance('CMSDb');



	$db->query("DROP TABLE `#__myblog_categories`");

	$db->query("CREATE TABLE IF NOT EXISTS `#__myblog_categories` ( `id` int(10) unsigned NOT NULL auto_increment,`name` varchar(50) NOT NULL default '',PRIMARY KEY (`id`) ) TYPE=MyISAM");

	$db->query("DROP TABLE `#__myblog_content_categories`");

	$db->query("CREATE TABLE IF NOT EXISTS `#__myblog_content_categories` ( `id` int(10) unsigned NOT NULL auto_increment,`contentid` int(10) unsigned NOT NULL default '0',`category` int(10) unsigned NOT NULL default '0',PRIMARY KEY (`id`) ) TYPE=MyISAM");

	$db->query("DROP TABLE `#__myblog_images`");

	$db->query("CREATE TABLE IF NOT EXISTS `#__myblog_images` ( `id` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,`filename` TEXT NOT NULL DEFAULT '',`contentid` INTEGER UNSIGNED NOT NULL DEFAULT 0,`user_id` INTEGER UNSIGNED NOT NULL DEFAULT 0,PRIMARY KEY(`id`) ) TYPE=MYISAM");

	$db->query("DROP TABLE `#__myblog_permalinks`");

	$db->query("CREATE TABLE IF NOT EXISTS `#__myblog_permalinks` ( `contentid` INTEGER UNSIGNED NOT NULL,`permalink` TEXT NOT NULL DEFAULT '',PRIMARY KEY(`contentid`) ) TYPE=MYISAM");

	return;

}



/**

 *	Create sample data for My Blog if new installation

 */ 

function _importSampleData() {

	global $database, $option, $my, $sectionid;

	$cms    =& cmsInstance('CMSCore');

	$db		=& cmsInstance('CMSDb');



	$cms->load('libraries', 'user');

	$title		= mysql_real_escape_string('Welcome to MyBlog!');

	$content	= mysql_real_escape_string('<p>Hello,</p><p> Thank you for using <strong>MyBlog!</strong>,the premier blogging tool for the popular Content Management System-Joomla!.<strong>MyBlog!</strong> is a feature packed,AJAX enabled replacement for the Joomla! Blog component.</p><p>&nbsp;</p><div style="text-align:center"><img src="components/com_myblog/images/icon.png" border="0" alt="icon.png" hspace="4" vspace="4" width="199" height="60" /></div><p>&nbsp;</p><p>&nbsp;Among the features currently implemented are:</p><ul><li><strong>MyBlog! </strong>Dashboard</li></ul><blockquote> <ul><li>Quick search and linking of previous posts while writing a blog entry</li><li>Tags / Tagclouds</li><li> Easy image upload and browsing using MyBlog!'s own image browser</li><li>SEF friendly permanent links for each blog entry</li><li> Single-click publishing/unpublishing</li><li>AJAXed page view of my blog entries </li></ul></blockquote> <ul><li><strong>MyBlog! </strong>Admin</li></ul><blockquote><ul><li>Publishing/posting permissions</li><li>3rd party MyBlog! addons support similar to Mambots</li><li><a href="http://www.azrul.com/product/joomla_comment_system.html">Jomcomment</a> integration</li><li>Moderate blogs,tags/categories</li></ul></blockquote><ul><li> <strong>MyBlog!</strong> Frontpage view</li></ul><blockquote><ul><li>Browse blogs by keyword,blogger,or tags</li><li>Simple and easy view of all blog entries / my blog entries <br /></li><li>Templating support</li><li><a href="http://del.icio.us">del.icio.us</a> &bull;<a href="http://www.digg.com/">digg</a> &bull;<a href="http://www.spurl.net">spurl</a> &bull;<a href="http://reddit.com/">reddit</a> &bull;<a href="http://www.furl.net">furl</a> social bookmarking support</li></ul></blockquote><ul><li> Future features:</li></ul><ul><li>RSS feeds</li><li>Trackbacks</li><li>More ready-made templates</li><li>Community-builder support</li><li>Archived view of posts</li><li> and more...! </li></ul><p>As part of our product improvement process,we would like you to submit any queries,suggestions,or comments regarding MyBlog! on our <a href="http://www.azrul.com/forum/index.php/board,6.0.html">forums at Azrul.com</a>.</p><p> Thank you!</p><p>-MyBlog Dev Team.</p><p>&nbsp;</p>');



	$strSQL	= "INSERT INTO #__content SET "

			. "created_by='{$cms->user->id}', "

			. "title='{$title}', "

			. "introtext='{$content}', "

			. "state='1', "

			. "created='2007-01-18 09:58:56', "

			. "modified='2007-01-18 10:01:34', "

			. "sectionid='{$sectionid}'";



	$db->query($strSQL);

	$insertid = $db->insertid();

	$db->query("INSERT into #__myblog_permalinks SET contentid='$insertid',permalink='welcome-to-myblog.html'");

	$categories = array (

	'gadgets',
2
Contributors
3
Replies
4
Views
8 Years
Discussion Span
Last Post by ShawnCplus
0

A), use [code] tags
B) Don't nest comments (If you would've used code tags you would have seen the error, or you could just use an editor that actually highlights your code)

/* case 'latestnews':

/**

* Show latest news for My Blog

**/

if(cmsVersion() != _CMS_JOOMLA15)

$title = "Latest updates";

showLatestNews();

break;*/
0

Thank you...so can you tell me what should I correct...as I am not sure...


Thanks

A), use [code] tags
B) Don't nest comments (If you would've used code tags you would have seen the error, or you could just use an editor that actually highlights your code)

/* case 'latestnews':

/**

* Show latest news for My Blog

**/

if(cmsVersion() != _CMS_JOOMLA15)

$title = "Latest updates";

showLatestNews();

break;*/
0

The error PHP gives you essentially tells you EXACTLY what to do already. Remove the errant end comment which I pointed out in my snippet

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.