Announcement

Collapse
No announcement yet.

How can I change default time for all existing users?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How can I change default time for all existing users?

    After conversion from UBB all of registered users have default time in GMT, but my forum time is GMT+4. Is it possible to change the default time for all registered users?

  • #2
    First make sure your server's time zone is set correctly:

    Admin CP -> vBulletin Options -> Date and Time Options -> Default Time Zone Offset

    Then you can change everyone's time zone offset by running this query on your database:

    UPDATE user SET timezoneoffset = X

    Where X is the hour offset from GMT. You can use negative or positive numbers. If you use table prefixes then you need to change user to include the prefix.

    You can run this query in your:

    Admin CP -> Import & Maintenance -> Execute SQL Query

    Make sure your userid is entered into your includes/config.php file so you have permission to run queries:

    // ****** USERS WITH QUERY RUNNING PERMISSIONS ******
    // The users specified here will be allowed to run queries from the control panel.
    // See the above entries for more information on the format.
    // Please note that the ability to run queries is quite powerful. You may wish
    // to remove all user IDs from this list for security reasons.
    $canrunqueries = '';

    Comment


    • #3
      I've got the following error:

      An error occurred while attempting to execute your query. The following information was returned.
      error number: 1146
      error desc: Table 'my_database_name.user' doesn't exist

      I also need to make one more modification for all existing users. I need to set by default "instant e-mail notification" for everybody. I did it for new users, but don't know how to set it for existing.

      Comment


      • #4
        Originally posted by user 1-2-3
        I've got the following error:

        An error occurred while attempting to execute your query. The following information was returned.
        error number: 1146
        error desc: Table 'my_database_name.user' doesn't exist
        You are probably using table prefixes, so you need to change user in the query to include the prefix. The table prefix is specified in the includes/config.php file:

        // Prefix that your vBulletin tables have in the database.
        // For example: $tableprefix = 'vb3_';
        $tableprefix = '';


        Originally posted by user 1-2-3
        I also need to make one more modification for all existing users. I need to set by default "instant e-mail notification" for everybody. I did it for new users, but don't know how to set it for existing.
        Go to your:

        Admin CP -> Import & Maintenance -> Execute SQL Query

        In the menu there is a prefined option named Instant email notification. Run that option.

        Comment


        • #5
          Many thanks. Fixed!

          Comment


          • #6
            Hi Jake,

            How do I update if "X" = +5.30

            Could you give me an example on how to make changes in hours and minutes??

            Thanks.

            Comment


            • #7
              Originally posted by Jake Bunce View Post
              First make sure your server's time zone is set correctly:

              Admin CP -> vBulletin Options -> Date and Time Options -> Default Time Zone Offset

              Then you can change everyone's time zone offset by running this query on your database:

              UPDATE user SET timezoneoffset = X

              Where X is the hour offset from GMT. You can use negative or positive numbers. If you use table prefixes then you need to change user to include the prefix.

              You can run this query in your:

              Admin CP -> Import & Maintenance -> Execute SQL Query

              Make sure your userid is entered into your includes/config.php file so you have permission to run queries:

              // ****** USERS WITH QUERY RUNNING PERMISSIONS ******
              // The users specified here will be allowed to run queries from the control panel.
              // See the above entries for more information on the format.
              // Please note that the ability to run queries is quite powerful. You may wish
              // to remove all user IDs from this list for security reasons.
              $canrunqueries = '';
              Thanks Jake for the tip. It took me some time though to understand since I'm a newbies. But here's an example for future newbies like that will come upon this problem.

              My tables prefix is vb_
              And my time zone is GMT -5
              so the query is :
              UPDATE vb_user SET timezoneoffset = -5

              It work well!

              Comment

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