Jump to content



Latest News: (loading..)

dr_lucas

Member Since 18 Mar 2004
Offline Last Active Jan 25 2013 05:43 AM
-----

Issues I've Posted

    E_NOTICE in all osC versions (navigation_history.php)_

    Posted 6 Dec 2012

    Issue:
    File includes/classes/navigation_history.php  Error Type: [E_NOTICE] Undefined index: get File includes/classes/navigation_history.php  Error Type: [E_NOTICE] Undefined index: post


    Proposed Fix:
    CHANGE:
    
    function set_snapshot($page = '') {
    	  global $PHP_SELF, $HTTP_GET_VARS, $HTTP_POST_VARS, $request_type;
    
    	  if (is_array($page)) {
    		$this->snapshot = array('page' => $page['page'],
    								'mode' => $page['mode'],
    								'get' => $this->filter_parameters($page['get']),
    								'post' => $this->filter_parameters($page['post']));
    	  } else {
    		$this->snapshot = array('page' => basename($PHP_SELF),
    								'mode' => $request_type,
    								'get' => $this->filter_parameters($HTTP_GET_VARS),
    								'post' => $this->filter_parameters($HTTP_POST_VARS));
    	  }
    	}
    

    To:
    
    function set_snapshot($page = '') {
    	  global $PHP_SELF, $HTTP_GET_VARS, $HTTP_POST_VARS, $request_type;
    
    	  if (is_array($page)) {
    		$this->snapshot = array('page' => $page['page'],
    								'mode' => $page['mode'],
    								'get' => (isset( $this->filter_parameters($page['get'])) ? $this->filter_parameters($page['get']) : ''),
    								'post' => (isset($this->filter_parameters($page['post'])) ? $this->filter_parameters($page['post']) : ''));
    	  } else {
    		$this->snapshot = array('page' => basename($PHP_SELF),
    								'mode' => $request_type,
    								'get' => (isset($this->filter_parameters($HTTP_GET_VARS)) ? $this->filter_parameters($HTTP_GET_VARS) : ''),
    								'post' => (isset($this->filter_parameters($HTTP_GET_VARS)) ? $this->filter_parameters($HTTP_POST_VARS) : ''));
    	  }
    	}