rickhudson Posted March 23, 2006 Posted March 23, 2006 I'm in the process of building a site using the latest osCommerce MS2.2 milestone 2 with the 051113 update. I've encountered a problem that appears when you navigate from a sub-category back to the main index.php page. It displays the following error message: Warning: strpos(): Empty delimiter. in /home/....../index.php on line 115 this error appears to be a problem with this line of line: if (isset($cPath) && strpos('_', $cPath)) { I've tried various items in posts on the forums but these merely seem to stop the categories from displaying at all on the main page. I have the Main Categories and Product Listing in Columns contributions installed, but these don't appear to interfere with this part of the code at all. Does anyone else have any ideas as to what may be causing this error and how I might fix it? Any help provided would be much appreciated. Regards Richard
Jack_mcs Posted March 23, 2006 Posted March 23, 2006 The arguments for that function are in the wrong order and you have to test the result. Try this: if (isset($cPath) && strpos($cPath, '_') !== FALSE) { Jack Support Links: For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc. All of My Addons Get the latest versions of my addons Recommended SEO Addons
rickhudson Posted March 23, 2006 Author Posted March 23, 2006 The arguments for that function are in the wrong order and you have to test the result. Try this:if (isset($cPath) && strpos($cPath, '_') !== FALSE) { Jack This works perfectly - thank you so much for replying. Given that this is a change to the standard code in the index.php file, maybe this fix should be reported via the Bug Reports on the osCommerce site! What do you think? Regards Richard
Recommended Posts
Archived
This topic is now archived and is closed to further replies.