i finished my website with magento in PHP 5.5 and the website work correctly the search work correctly in localhost

but when i moved the website online to my server that run in php 5.3 some errors appeared in search the error appeared in the inline copy

and i did all that steps to fix the errors 1-flush the cache and log out and in again? 2-Re-index 3-CatalogSearch enabled in config 4-upload all the files

is the error can be from php version or database !!

  • magento.com/resources/system-requirements
    – user2857
    Commented Nov 25, 2014 at 13:47
  • @ADM this is an answer, please post it. Commented Nov 25, 2014 at 13:50
  • check your magento index.php versioncompare()function to find the reqd version for that magento. Commented Nov 25, 2014 at 14:40
  • Did you actually make any searches? It looks to me like there have not been any searches made, hence the non-object, maybe because it's empty?
    – tecjam
    Commented Nov 25, 2014 at 15:47

3 Answers 3


Minimum PHP version required by Magento is 5.4.

Check requirements on Magento site:



Although Magento 1.9 should work with PHP 5.3.0 or newer, your error message (which is not from the database) referencing a core file seems to indicate that this is not the case.


You can follow System Requirements for Magento Enterprise Edition and Community Edition.

if you are working with php 5.5, there is no point to downgrade your live environment to 5.3, especially for security reason.

At 1.9.1 index.php

if (version_compare(phpversion(), '5.3.0', '<')===true) {
 echo  '
  <div style="font:12px/1.35em arial, helvetica, sans-serif;">
   <div style="margin:0 0 25px 0; border-bottom:1px solid #ccc;">
     <h3 style="margin:0; font-size:1.7em; font-weight:normal; text-transform:none; text-align:left; color:#2f2f2f;">Whoops, it looks like you have an invalid PHP version.
    <p>Magento supports PHP 5.3.0 or newer.
    <a href="http://www.magentocommerce.com/install" target="">Find out</a> how to install</a> Magento using PHP-CGI as a work-around.</p></div>';
            exit; }

Note: This question is not about: why im getting this error on admin page, the question about minimum php version

  • is it a good idea to modify the Magento source code? I doubt.
    – Raptor
    Commented Jan 1, 2015 at 10:46
  • what? i bet index.php is the most editable file in Magento,
    – user2857
    Commented Jan 1, 2015 at 10:54
  • Nope. There is a reason for having minimum PHP version. For example, If my environment is PHP 5.2, and I change the above code to bypass the check, errors will appear, as there are function changes in between different PHP versions
    – Raptor
    Commented Jan 1, 2015 at 10:58
  • lol, Who told you it is a good idea to downgrade? I only show that the requirements specified 5.4, but index.php has 5.3.0...
    – user2857
    Commented Jan 1, 2015 at 11:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.