atal error: Call to a member function add_current_page() on a non-object in /home/xx/xxx/includes/application_top.php on line 312
This is another of the common issues I encounter almost on every new instance I work on. Issue resolution is very simple. Following the steps as below:
1. open includes/application_top.php
2. find the section of code
// navigation history
 if (tep_session_is_registered('navigation')) {
       if (PHP_VERSION < broken_navigation =" $navigation;" navigation =" new">unserialize($broken_navigation);
       }
 } else {
       tep_session_register('navigation');
       $navigation = new navigationHistory;
 }
 $navigation->add_current_page();
3. Replace the section with the following segment of code:
 // navigation history
 if (tep_session_is_registered('navigation')) {
       if (PHP_VERSION < broken_navigation =" $navigation;" navigation =" new">unserialize($broken_navigation);
       } else {
         $navigation = new navigationHistory;
       }
 } else {
       tep_session_register('navigation');
       $navigation = new navigationHistory;
 }
 $navigation->add_current_page();
 
No comments:
Post a Comment