Urgent help!!! Error after upgrading to vB4.2.2: "Warning: date() [function.date]: It is not safe..."

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • VertoPB
    New Member
    • Oct 2013
    • 6
    • 4.2.X

    [Suite] Urgent help!!! Error after upgrading to vB4.2.2: "Warning: date() [function.date]: It is not safe..."

    Hi,

    after updating my installation to version 4.2.2 I can not access the forum. I can not access the control panel. When I try to access any page of the forum or admin panel, I find the following errors:

    Control panel:

    Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 4912

    Warning: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 5104

    Warning: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 5104

    Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 5104
    Forum:

    Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 4912

    Warning: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 5104

    Warning: strftime() [function.strftime]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 5104

    Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in ..../includes/functions.php on line 5104
    I have hosted the forum on a shared host and I can not access the php.ini. Also I have no access to the administration panel.

    I added to the beginning of confih.php, the following lines:

    define('DISABLE_HOOKS', true);
    ini_set('display_errors', 'Off');

    But nothing happens. Everything is completely fallen.

    I have also agreed to the vB4 Jira project but do not know how to add this issue, or what to do there.

    I request urgent help please.

    Thanks and regards.

    Note: Sorry for my english
  • amagab
    Senior Member
    • May 2006
    • 194

    #2
    I have the same problem. In addition to that, it's not possible to post attachments anymore. :-( Worst upgrade ever!!!!

    Comment

    • Mark.B
      vBulletin Support
      • Feb 2004
      • 24286
      • 6.0.X

      #3
      Please both send tickets in with ftp credentials in the sensitive data field.

      MARK.B
      vBulletin Support
      ------------
      My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
      My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

      Comment

      • VertoPB
        New Member
        • Oct 2013
        • 6
        • 4.2.X

        #4
        Thanks.

        Following these instructions: http://www.vbulletin.com/forum/forum...-been-released
        And this helps: http://www.vbulletin.com/forum/forum...tstrap-php-561

        It works again.

        Regards

        Comment

        • xrayhead
          Member
          • Nov 2002
          • 94

          #5
          I'm running an upgrade on my VPS using a test domain and I also get the following:

          Code:
          [B]Warning[/B][COLOR=#000000][FONT=Times New Roman]: date() [[/FONT][/COLOR][URL="http://www.lbarrell.com/vb/admincp/function.date"]function.date[/URL][COLOR=#000000][FONT=Times New Roman]]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in [/FONT][/COLOR][B]..../includes/functions.php[/B][COLOR=#000000][FONT=Times New Roman] on line [/FONT][/COLOR][B]4912[/B]
          
          [B]Warning[/B][COLOR=#000000][FONT=Times New Roman]: date() [[/FONT][/COLOR][URL="http://www.lbarrell.com/vb/admincp/function.date"]function.date[/URL][COLOR=#000000][FONT=Times New Roman]]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in [/FONT][/COLOR][B]..../includes/functions.php[/B][COLOR=#000000][FONT=Times New Roman] on line [/FONT][/COLOR][B]5104[/B]
          
          [B]Warning[/B][COLOR=#000000][FONT=Times New Roman]: date() [[/FONT][/COLOR][URL="http://www.lbarrell.com/vb/admincp/function.date"]function.date[/URL][COLOR=#000000][FONT=Times New Roman]]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in [/FONT][/COLOR][B]..../includes/functions.php[/B][COLOR=#000000][FONT=Times New Roman] on line [/FONT][/COLOR][B]5104[/B]
          
          [B]Warning[/B][COLOR=#000000][FONT=Times New Roman]: date() [[/FONT][/COLOR][URL="http://www.lbarrell.com/vb/admincp/function.date"]function.date[/URL][COLOR=#000000][FONT=Times New Roman]]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/London' for 'BST/1.0/DST' instead in [/FONT][/COLOR][B]..../includes/functions.php[/B][COLOR=#000000][FONT=Times New Roman] on line [/FONT][/COLOR][B]5104[/B]
          I followed the links above and it seems there is just a file to upload and hid the error messages? Is there not a permanent fix for this? Anyway I need to get this sorted before I run the upgrade on my live site!! Please advise!

          LINK:

          Comment

          • xrayhead
            Member
            • Nov 2002
            • 94

            #6
            Sorted it - I just did the following

            2. For those who feel comfortable with editing files.

            In class_core.php locate lines 5683-5685 (class_core.php is in the 'includes' folder)
            Code:
              
            case E_NOTICE:            
            // Just ignore these completely //        
            break;
            Add lines for Deprecated and/or Strict errors as required ;

            Code:
              
            case E_NOTICE:        
            case E_STRICT:        
            case E_DEPRECATED:            
            // Just ignore these completely //        
            break;
            This will bypass the additional error reporting.

            Comment

            • Wayne Luke
              vBulletin Technical Support Lead
              • Aug 2000
              • 73981

              #7
              See: http://www.vbulletin.com/forum/forum...98#post4002398

              Does the same thing as above but in a way that will be supported by us.
              Translations provided by Google.

              Wayne Luke
              The Rabid Badger - a vBulletin Cloud demonstration site.
              vBulletin 5 API

              Comment

              • bogley
                Member
                • Dec 2009
                • 95
                • 3.8.x

                #8
                OK so please correct me if I'm wrong, but I'm reading about the system timezone errors, (which I'm getting too), and how "It is not safe to rely....", and the solution is to cover up the warnings so they don't appear?

                Is this really the solution??? I appreciate the tip on making it pleasing to the eye, but what about solving the actual issue rather than just putting a bandage on it? Why exactly is it "not safe"?

                Comment

                • Wayne Luke
                  vBulletin Technical Support Lead
                  • Aug 2000
                  • 73981

                  #9
                  The Timezone issue is because your PHP is not configured properly. Seems to be a common occurrence. Newer versions of PHP require that a timezone be set in the php.ini file. You can fix this by following the steps in this post:

                  When viewing a page, you get warning, notice or deprecated messages. First, search JIRA to see if there is a fix listed. If not, then add the following line to the top of your /includes/config.php file under


                  Replacing the Class Core file doesn't cover up errors though. It changes the vBulletin Error Handler so it doesn't catch warnings, notices, or deprecated notices. These will still be properly logged in your php error log but if they are not displayed on the screen there is no adverse affect on the application because they are informational not errors.
                  Translations provided by Google.

                  Wayne Luke
                  The Rabid Badger - a vBulletin Cloud demonstration site.
                  vBulletin 5 API

                  Comment

                  • VertoPB
                    New Member
                    • Oct 2013
                    • 6
                    • 4.2.X

                    #10
                    Thanks

                    Comment

                    • CLeslein
                      Senior Member
                      • Jun 2009
                      • 108
                      • 3.8.x

                      #11
                      I am having this exact problem. But I do not know enough to fix it. PLEASE HELP ME!
                      http://turftopics.com/ - my web forum for the lawn & landscaping industry



                      http://lesleinlawn.com/- my lawn & landscaping business site

                      Comment

                      • cwbullet2
                        New Member
                        • Jan 2009
                        • 17
                        • 3.8.x

                        #12
                        That did not fix it for me.

                        Comment

                        • Mark.B
                          vBulletin Support
                          • Feb 2004
                          • 24286
                          • 6.0.X

                          #13
                          Add the following line to your config.php under the <?php line:
                          PHP Code:
                          define('SKIP_ALL_ERRORS'true); 

                          If you need further assistance, please start your own topic with full details of the issue.
                          MARK.B
                          vBulletin Support
                          ------------
                          My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
                          My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

                          Comment

                          widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                          Working...