← Back to team overview

phpdevshell team mailing list archive

[Bug 664913] Re: System Admin tabs don't work

 

When I try to install beta4, after setting up DB and running install,
when I try to go to main page (after succesful install) I get the
following error:

Uncaught Exception while running

This page will try to provide as much information as possible so you can track down (and hopefully fix) the problem.
The error

The message of the error is as follow:

    Invalid argument supplied for foreach()

The error occurred in file
/home/mydomain/portal/beta4/includes/models/PHPDS_user.query.php at line
142

    136   <?php
            $found = false;
    137   <?php

    138   <?php
            // Fetch all instances which match the id crypt
    139   <?php
            $persistent_array = $this->db->invokeQuery('USER_selectCookieQuery', $id_crypt);
    140   <?php

    141   <?php
            // Loop and check for matching pass crypt
    142   <?php
            foreach ($persistent_array as $persistent_item){
    143   <?php
                if($pass_crypt == $persistent_item['pass_crypt']){
    144   <?php
                    $cookie_id = $persistent_item['cookie_id'];
    145   <?php
                    $user_id = $persistent_item['user_id'];
    146   <?php
                    $found = true;
    147   <?php
                    break;
    148   <?php
                }
    149   <?php
            }

The configuration
Configuration files actually used:

    * [ 0 ] => /home/mydomainportal/beta4/config/PHPDS-defaults.config.php
    * [ 1 ] => /home/mydomain/portal/beta4/config/single-site.config.php

Configuration files which would have been used if they were present:

    * [ 0 ] => /home/mydomain/portal/beta4/config/multi-host.config.php
    * [ 1 ] => /home/mydomain/portal/beta4/config/forerunnertv.com.config.php

The Backtrace:

All relative file pathes are relative to the server root (namely
/home/mydomain/ )

Click on the Book icon to access online documentation.
File path (relative) 	Line 	Call (with arguments)
...portal/beta4/includes/PHPDS_db.class.php	157	<?php
USER_selectUserPersistentQuery::invoke("USER_selectUserPersistentQuery", array[1])
151   <?php
     */
152   <?php
    public function invokeQueryWith($query_name, $params)
153   <?php
    {
154   <?php
        $query = $this->makeQuery($query_name);
155   <?php
        if (!is_a($query, 'PHPDS_query'))
156   <?php
                throw new PHPDS_databaseException('Error invoking query');
157   <?php
        return $query->invoke($params);
158   <?php
    }
159   <?php

160   <?php
    /**
161   <?php
     * Locates the query class of the given name, loads it, intantiate it, and returns the query object
162   <?php
     *
163   <?php
     * @date                20100219
164   <?php
     * @version     1.1
...portal/beta4/includes/PHPDS_db.class.php	139	  <?php
PHPDS_db::invokeQueryWith("USER_selectUserPersistentQuery", "ad73703dd9abb94a59d3a946ed534209165ca5")
133   <?php
     * @return array (usually), the result data of the query
134   <?php
     */
135   <?php
    public function invokeQuery($query_name) // actually more parameters can be given
136   <?php
    {
137   <?php
        $params = func_get_args();
138   <?php
        array_shift($params); // first parameter of this function is $query_name
139   <?php
        return $this->invokeQueryWith($query_name, $params);
140   <?php
    }
141   <?php

142   <?php
    /**
143   <?php
     * Locates the query class of the given name, loads it, intantiate it, send the query to the DB, and return the result
144   <?php
     *
145   <?php
     * @date 20100922 (1.0) (greg) added
146   <?php
     * @version 1.0
...portal/beta4/includes/PHPDS_user.class.php	219	  <?php
PHPDS_db::invokeQuery("ad73703dd9abb94a59d3a946ed534209165ca5")
213   <?php
     * @date 20100702 (v1.0.0) (ross) created from the lookup_user fct by jason and greg
214   <?php
     * @version 1.0.0
215   <?php
     * @author jason, greg, ross
216   <?php
     */
217   <?php
    public function lookupPersistentUser($cookie)
218   <?php
    {
219   <?php
        return $this->db->invokeQuery('USER_selectUserPersistentQuery', $cookie);
220   <?php
    }
221   <?php

222   <?php
    /**
223   <?php
     * Set a persistent cookie to be used as a remember me function
224   <?php
     *
225   <?php
     * @param string $cookie
226   <?php
     * @return array or false the user record
...portal/beta4/includes/PHPDS_security.class.php	240	  <?php
PHPDS_user::lookupPersistentUser("ad73703dd9abb94a59d3a946ed534209165ca5")
234   <?php
     * @date 20100702 (v1.0.0)(ross) created from the lookup_user fct by jason and greg
235   <?php
     * @version    1.0.0
236   <?php
     * @author jason, greg, ross
237   <?php
     */
238   <?php
    public function lookupPersistentUser($cookie)
239   <?php
    {
240   <?php
        return $this->user->lookupPersistentUser($cookie);
241   <?php
    }
242   <?php

243   <?php
    /**
244   <?php
     * Set a persistent cookie to be used as a remember me function
245   <?php
     *
246   <?php
     *
247   <?php
     * @param string $cookie
...portal/beta4/includes/PHPDS.inc.php	395	  <?php
PHPDS_security::lookupPersistentUser()
389   <?php
        $this->copySettings(array('crypt_key', 'loginandout', 'front_page_id', 'front_page_id_in', 'date_format', 'date_format_short', 'scripts_name_version', 'footer_notes', 'charset_format', 'locale_format', 'charset', 'language', 'debug_language', 'region', 'system_timezone', 'default_template', 'default_template_id', 'printable_template', 'root_id', 'root_role', 'root_group', 'setting_admin_email', 'custom_logo', 'url_append', 'skin', 'meta_keywords', 'meta_description'));
390   <?php
        $this->copySettings(array('allow_remember', 'system_down', 'demo_mode', 'force_core_changes', 'system_logging', 'access_logging', 'email_critical', 'sef_url', 'queries_count'), 'boolean');
391   <?php
        // Prepare user. /////////////////////////////////////////
392   <?php
        $this->PHPDS_user();
393   <?php
        if (!empty($this->configuration['allow_remember']) && empty($_SESSION['user_id']) && isset($_COOKIE['pdspc'])) {
394   <?php
            // Menu id is an integer.
395   <?php
            $this->PHPDS_security()->lookupPersistentUser($_COOKIE['pdspc']);
396   <?php
        }
397   <?php
        // Set crucial user settings. //////////////////////////////////////////////////////
398   <?php
        $this->writeUserConfig();
399   <?php
        ////////////////////////////////////////////////////////////////////////////////////
400   <?php
        // Asign locale to use /////////////////////////////////////////////////////////////
401   <?php
        $this->configuration['locale'] = $this->configuration['user_locale']; //////////////
402   <?php
        // Set environment. ////////////////////////////////////////////////////////////////
...portal/beta4/includes/PHPDS.inc.php	483	  <?php
PHPDS::configCoreSettings()
477   <?php

478   <?php
        // various init subroutines
479   <?php
        $this->configSession()->configDb();
480   <?php

481   <?php
        $this->db->getEssentialSettings();
482   <?php

483   <?php
        $this->configCoreSettings();
484   <?php

485   <?php
        $this->db->installedPlugins();
486   <?php

487   <?php
        // load core language
488   <?php
        $this->PHPDS_core()->loadMenuLanguage();
489   <?php

490   <?php
        // This is both for templates and security: it builds the list of resources the current user is allowed to
...portal/beta4/includes/PHPDS.inc.php	141	  <?php
PHPDS::config()
135   <?php
    {
136   <?php
        // Start Ob.
137   <?php
        ob_start();
138   <?php
        $this->embedded = $embedded;
139   <?php
        $this->basepath = realpath(dirname(__FILE__) . DIRECTORY_SEPARATOR . '..') . DIRECTORY_SEPARATOR;
140   <?php
        try {
141   <?php
            $this->config();
142   <?php
        } catch (Exception $e) {
143   <?php
            $this->PHPDS_errorHandler()->doHandleException($e);
144   <?php
        }
145   <?php
        return $this;
146   <?php
    }
147   <?php

148   <?php
    /**
...portal/beta4/index.php	33	  <?php
PHPDS::__construct()

-- 
You received this bug notification because you are a member of
PHPDevShell, which is subscribed to PHPDevShell.
https://bugs.launchpad.net/bugs/664913

Title:
  System Admin tabs don't work

Status in Open Source PHP RAD Framework with UI.:
  In Progress

Bug description:
  v3.0.0-Beta-2 with Firefox 3.6.10

When you click on System Managemnt > System Admin none of the tabs are highlighted. If you click on a tab it adds the tab information to the bottom of the page without removing the information from the previous tab, so the page gets longer and longer!





References