Page 1 of 1

Redirect URL after deleting guestbook entry

Posted: 02 Jun 2009, 14:02
by jbudd
The code in controllers/phocaguestbook.php to refresh the screen after deleting an item is

Code: Select all

// Redirect
$link	= 'index.php?option=com_phocaguestbook&view=phocaguestbook&id='.$id.'&Itemid='.$itemid.'&limitstart='.$limitstart;
$link	= JRoute::_($link);
$this->setRedirect( $link, $msg );
On my site (localhost with wampserver) it gets translated to

Code: Select all

index.php?option=com_phocaguestbook&view=phocaguestbook&id=1&Itemid=297&limitstart=0
(The & is replaced by &)

None of the guestbook parameters defined on the menu item are applied - presumably because the itemid is not correctly assigned.

Re: Redirect URL after deleting guestbook entry

Posted: 02 Jun 2009, 23:41
by Jan
Hi, this should be OK, these & are added by standard Jommla! method JRoute, so everything should run ok :idea:

Re: Redirect URL after deleting guestbook entry

Posted: 03 Jun 2009, 00:08
by jbudd
Jan wrote:Hi, this should be OK, these & are added by standard Jommla! method JRoute, so everything should run ok :idea:
For example: the parameters on the menu item specify font colours and that the form should be hidden. The page displayed after the redirection does not have these parameters applied.

The URL is otherwise correct, if I go through and delete all the amp;'s and refresh the page, it applys the parameters.

Re: Redirect URL after deleting guestbook entry

Posted: 04 Jun 2009, 15:38
by jbudd
The problem goes away if I turn on SEO - (because with SEO URLs Joomla goes and retrieves an itemid from the menu)?