This topic is locked
[SOLVED]

 Redirect to Search Page not working

9/18/2012 5:23:13 PM
PHPRunner General questions
M
mrohde author

PHPRUNNER 6.1 build 12662
I have set up a redirect after login, I am trying to go to my search page using the following code:
//** Redirect to another page ****

header("Location: entitlement_search.php");

exit();
// Place event code here.

// Use "Add Action" button to add code snippets.
I get the following error message:
Parse error: syntax error, unexpected '{', expecting T_FUNCTION in /home/mcrohde/fanparkingdecal.com/include/entitlement_events.php on line 55
Here is the content of the file entitlement_event.php
<?php

class eventclass_entitlement extends eventsBase

{

function eventclass_entitlement()

{

// fill list of events

$this->events["BeforeShowSearch"]=true;
// onscreen events
}

// Captchas functions
// handlers
// Before display

//function BeforeShowSearch(&$xt,&$templatefile)

{
//** Custom code ****

// put your custom code here
$smarty->assign("value_street_no","");

$smarty->assign("value_street_name","");
;

} // function BeforeShowSearch
// onscreen events
}

?>
If I set up the redirect to an external web page it works. I appears to work with the exception of the search page.
Mike <img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=question&id=20067&image=1&table=forumtopics' class='bbc_emoticon' alt=':blink:' />

Sergey Kornilov admin 9/18/2012

I guess it's related to the fact your BeforeShowSearch event contains non-working code.