Jump to content

Archived

This topic is now archived and is closed to further replies.

metaphziks

Error in my search page.

Recommended Posts

Hello I'm having an issue with my site's search page.  The search app I'm using is called Site Search Pro.  Their customer service sucks, so I have no options other than to search online.  I'm getting this error at the top of my search page:

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /vservers/infadesign/htdocs/searchpro/index.php:10) in /vservers/infadesign/htdocs/searchpro/index.php on line 121

I'm not a php developer, so it's frustrating when I get stuck.  This error happens when I wrap my page around the code Site Search Pro
generates, for you to plug into your own designed page.  Now, when the code is generated by SSP, there is no error, but when I wrap my design around it, it gives me that error above.

I also checked my page for errors and there is none. I was told that if there is a space before my opening and closing php tag that may cause the error, but there are no spaces. Here is a link to my site, to see the error just click on the search putton on the side nav.

http://www.metaphiziks.com

If anyone can help me I would appriciate it.

Thanks

Rob.

Share this post


Link to post
Share on other sites
Looks like you are using cookie based sessions.  You must call session_start() before anything is output to the browser.  When you wrap your site around the search function, you are outputting information to the browser before the call to session_start() happens. 

This might be fixed by simply adding the following to the very top of your index.php page for your search:

<?php
  session_start();
?>

Then go on with your page processing.  Note: remove the call to session_start() from later on in the page.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.