Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-16804

List of all users shows a fatal error message {Fatal error: Call to undefined method MoodleQuickForm_hidden::MoodleQuickForm_hidden() in F:\Moodle_WebSite\lib\pear\HTML\QuickForm\element.php on line 363}

    Details

    • Type: Task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.9
    • Fix Version/s: 1.9.6
    • Component/s: Installation
    • Labels:
      None
    • Environment:
      Windows Server 2003, MS-IIS v6.0, MySQL Server 5.0, PHP 5.3, PECL 5.2
    • Database:
      MySQL
    • Affected Branches:
      MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE

      Description

      From the Admin account I was able to create 4 user accounts. But the when I select List all users the following fatal error shows (Note: I have enabled Minimal debugging):-
      ------------------------------------------------------------------------------------
      Fatal error: Call to undefined method MoodleQuickForm_hidden::MoodleQuickForm_hidden() in F:\Moodle_WebSite\lib\pear\HTML\QuickForm\element.php on line 363
      ------------------------------------------------------------------------------------

      Any suggestions are welcome.

      Regards,

      Hammad Rauf

        Gliffy Diagrams

        1. Clip1.bmp
          2.19 MB
          Hammad Rauf

          Issue Links

            Activity

            hammad Hammad Rauf created issue -
            Hide
            skodak Petr Skoda added a comment -

            works fine for me, but I did not test it in PHP 5.3alpha - could you please try PHP 5.2.6?

            Show
            skodak Petr Skoda added a comment - works fine for me, but I did not test it in PHP 5.3alpha - could you please try PHP 5.2.6?
            skodak Petr Skoda made changes -
            Field Original Value New Value
            Priority Critical [ 2 ] Major [ 3 ]
            Hide
            phildriscoll Phil Driscoll added a comment -

            I'm experiencing the same issue here on Ubuntu 8.04 with PHP 5.3.0RC4

            Show
            phildriscoll Phil Driscoll added a comment - I'm experiencing the same issue here on Ubuntu 8.04 with PHP 5.3.0RC4
            Hide
            phildriscoll Phil Driscoll added a comment -

            I observe the same error when I'm logged into Moodle, and click on the 'Edit profile' link.

            Show
            phildriscoll Phil Driscoll added a comment - I observe the same error when I'm logged into Moodle, and click on the 'Edit profile' link.
            Hide
            phildriscoll Phil Driscoll added a comment -

            I can confirm that the problem does not exist when using php 5.2.9

            Show
            phildriscoll Phil Driscoll added a comment - I can confirm that the problem does not exist when using php 5.2.9
            skodak Petr Skoda made changes -
            Assignee Eloy Lafuente (stronk7) [ stronk7 ] Petr Skoda [ skodak ]
            Hide
            skodak Petr Skoda added a comment -

            yes, this was problem was already fixed last week, please update to next weekly build or downgrade your PHP to 5.2.x

            Show
            skodak Petr Skoda added a comment - yes, this was problem was already fixed last week, please update to next weekly build or downgrade your PHP to 5.2.x
            skodak Petr Skoda made changes -
            Status Open [ 1 ] Resolved [ 5 ]
            Fix Version/s 1.9.6 [ 10340 ]
            Resolution Fixed [ 1 ]
            Hide
            jlukar John Lukar added a comment -

            Hi,
            I am in a bit of a picke here. I am on shared hosting and they are on PHP Version 5.3.2 and can not downgrade to 5.2.x.

            I have a custom moodle (1.9.1) that is highly customized for my client and not able to upgrade to fixed moodle version as many core files have been modified.

            This problem occurs for me.

            Can you tell me what the fix is or patch fix so I can continue to run "Browse List of users" function ?

            All other functions seem to work fine.

            Help please.

            Show
            jlukar John Lukar added a comment - Hi, I am in a bit of a picke here. I am on shared hosting and they are on PHP Version 5.3.2 and can not downgrade to 5.2.x. I have a custom moodle (1.9.1) that is highly customized for my client and not able to upgrade to fixed moodle version as many core files have been modified. This problem occurs for me. Can you tell me what the fix is or patch fix so I can continue to run "Browse List of users" function ? All other functions seem to work fine. Help please.
            Hide
            skodak Petr Skoda added a comment -

            Hi John, the fix was to use standard PHP __construct for constructors in all quickforms classes. You can try to diff directories, but without CVS or Git I doubt you can maintain any "highly customised" installation. I hope you have backported all those security fixed we have fixed since the 1.9.1...

            Petr Skoda

            Show
            skodak Petr Skoda added a comment - Hi John, the fix was to use standard PHP __construct for constructors in all quickforms classes. You can try to diff directories, but without CVS or Git I doubt you can maintain any "highly customised" installation. I hope you have backported all those security fixed we have fixed since the 1.9.1... Petr Skoda
            Hide
            deligant Christian Deligant added a comment -

            Hi Petr, I downloaded a fresh MOODLE_19_STABLE ($release = '1.9.9+ (Build: 20101004)') and diffed through the files... but found no evidences of this kind of changes (the __construct bit) I have the same issue on about every single page that makes use of hidden fields... (using a 1.9.5 moodle installation with some integrations)

            Any clues?

            Show
            deligant Christian Deligant added a comment - Hi Petr, I downloaded a fresh MOODLE_19_STABLE ($release = '1.9.9+ (Build: 20101004)') and diffed through the files... but found no evidences of this kind of changes (the __construct bit) I have the same issue on about every single page that makes use of hidden fields... (using a 1.9.5 moodle installation with some integrations) Any clues?
            danmarsden Dan Marsden made changes -
            Link This issue is duplicated by MDL-25408 [ MDL-25408 ]
            dougiamas Martin Dougiamas made changes -
            Status Resolved [ 5 ] Closed [ 6 ]
            dougiamas Martin Dougiamas made changes -
            Workflow jira [ 28800 ] MDL Workflow [ 61080 ]
            dougiamas Martin Dougiamas made changes -
            Workflow MDL Workflow [ 61080 ] MDL Full Workflow [ 90262 ]
            Hide
            morfi Andrey added a comment - - edited

            quick fix:

            add in HTML_QuickForm_element (moodle/lib/pear/HTML/QuickForm/element.php)

             
            public function __call($name, $args) {
                $name = str_replace('MoodleQuickForm_', '', $name);
             
                if ($name == 'passwordunmask') {
                    $name = 'password';
                }
             
                return call_user_func_array(array($this, 'HTML_QuickForm_'.$name), $args);
            }

            Show
            morfi Andrey added a comment - - edited quick fix: add in HTML_QuickForm_element (moodle/lib/pear/HTML/QuickForm/element.php) public function __call($name, $args) { $name = str_replace('MoodleQuickForm_', '', $name);   if ($name == 'passwordunmask') { $name = 'password'; }   return call_user_func_array(array($this, 'HTML_QuickForm_'.$name), $args); }
            Hide
            kidakaka Prasad added a comment -

            Thanks Andrey for that quick fix. You are a life saver!!

            Show
            kidakaka Prasad added a comment - Thanks Andrey for that quick fix. You are a life saver!!
            Hide
            jsherk Jeff Sherk added a comment -

            Thank you Andrey!

            This saved me a whole lot of work!

            Show
            jsherk Jeff Sherk added a comment - Thank you Andrey! This saved me a whole lot of work!
            Hide
            rstuker Stuker Ramón added a comment -

            Save me too!...thks!.

            Show
            rstuker Stuker Ramón added a comment - Save me too!...thks!.
            Hide
            nadavkav Nadav Kavalerchik added a comment -

            Life saver!!! (had to install an old Moodle 1.9.5 for testing)

            Show
            nadavkav Nadav Kavalerchik added a comment - Life saver!!! (had to install an old Moodle 1.9.5 for testing)
            Hide
            kousarkhan Kousar added a comment -

            Thanks — You are a life saver!!

            Show
            kousarkhan Kousar added a comment - Thanks — You are a life saver!!
            Hide
            dpattyatl Diana Siachoque added a comment -

            Thanks!! It works perfectly!! Life saver!

            Show
            dpattyatl Diana Siachoque added a comment - Thanks!! It works perfectly!! Life saver!
            Hide
            stevepb Steve Bilton added a comment -

            I'm in the middle of a server migration as I type.....
            User testing before going live highlighted the same error, I couldn't create new users or edit user profiles.

            Your hack works adding the function in to a Moodle 1.8.8 also.
            You saved the day, I don't have to start messing with downgrading PHP versions from 5.3 to 5.2 or setting up nested php.

            Life saver!

            Thanks

            Show
            stevepb Steve Bilton added a comment - I'm in the middle of a server migration as I type..... User testing before going live highlighted the same error, I couldn't create new users or edit user profiles. Your hack works adding the function in to a Moodle 1.8.8 also. You saved the day, I don't have to start messing with downgrading PHP versions from 5.3 to 5.2 or setting up nested php. Life saver! Thanks

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  21/Oct/09