• Resolved SteveAx

    (@steveax)


    Having the same issue as another post here, but my issue isn’t resolved… here is the error I am getting after updating WP and all plugins:

    Fatal error: Uncaught exception ‘Exception’ with message ‘DateTimeZone::__construct() [datetimezone.–construct]: Unknown or bad timezone (+0000)’ in /home/content/45/5449545/html/GaryGulman/wp-content/plugins/timed-content/timed-content.php:1414 Stack trace: #0 /home/content/45/5449545/html/GaryGulman/wp-content/plugins/timed-content/timed-content.php(1414): DateTimeZone->__construct(‘+0000’) #1 [internal function]: timedContentPlugin->serverShowHTML(Array, ‘??<tr>??<td cla…’, ‘timed-content-s…’) #2 /home/content/45/5449545/html/GaryGulman/wp-includes/shortcodes.php(325): call_user_func(Array, Array, ‘??<tr>??<td cla…’, ‘timed-content-s…’) #3 [internal function]: do_shortcode_tag(Array) #4 /home/content/45/5449545/html/GaryGulman/wp-includes/shortcodes.php(199): preg_replace_callback(‘/\[(\[?)(timed\…’, ‘do_shortcode_ta…’, ‘<center><img sr…’) #6 /home/content/45/5449545/html/GaryGulman/wp-includes/class-wp-hook in /home/content/45/5449545/html/GaryGulman/wp-content/plugins/timed-content/timed-content.php on line 1414

    The short code I am using is:
    [timed-content-server hide="2019-03-22 03:01:00 -0800"]

    Please advise,
    Steve

    The page I need help with: [log in to see the link]

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Arno Welzel

    (@awelzel)

    I am sorry, but I can not reproduce this error. On my demo site it works fine, see the last section where I added the shortcode:

    https://wordpress-demo.arnowelzel.de/timed-content/

    The other problem is, that line 1414 does not contain a call of new DateTimeZone(). Furthermore all DateTimeZone constructions are embedded in try { ... } catch { ... } blocks . So an unhandled exception like this is technically not possible with the current version of the plugin.

    Also see https://github.com/arnowelzel/timed-content/blob/2.55/timed-content.php for reference and the published version in the WordPress repository: https://downloads.www.ads-software.com/plugin/timed-content.2.55.zip

    Please check, that the plugin was installed properly. At the moment it looks like the server has an outdated version of timed-content.php. If in doubt, download the plugin manually, extract the ZIP file and upload it to wp-content/plugins on the webserver.

    Thread Starter SteveAx

    (@steveax)

    So I deactivated and deleted the timed-content files and folder from the server. I downloaded the zip file from the link you provided, unzipped and uploaded the files to the plug-ins directory. I activated the plug-in and still get the same results..

    https://www.garygulman.com/?page_id=2086

    The current timed-content.php file in the /wp-content/plugins/timed-content folder has a file size of 111,942 and it says:

    Plugin Name: Timed Content
    Text Domain: timed-content
    Domain Path: /lang
    Plugin URI: https://www.ads-software.com/plugins/timed-content/
    Description: Plugin to show or hide portions of a Page or Post based on specific date/time characteristics. These actions can either be processed either server-side or client-side, depending on the desired effect.
    Author: K. Tough, Arno Welzel
    Version: 2.55
    Author URI: https://www.ads-software.com/plugins/timed-content/

    In the top of the file…

    If you provide privet contact method I will give you access to the admin area and server if needed.

    Thanks,
    Steve

    • This reply was modified 5 years, 8 months ago by SteveAx.
    Plugin Author Arno Welzel

    (@awelzel)

    Feel free to contact my via e-mail.

    You will find my privat address on my website: https://arnowelzel.de/en/about-me

    Thread Starter SteveAx

    (@steveax)

    sent

    Plugin Author Arno Welzel

    (@awelzel)

    The problem was an outdated PHP version on your website. Version 2.56 should work now even with this old PHP version. However you should update PHP to a supported version to avoid security problems (also see https://www.php.net/supported-versions.php).

    Plugin Author Arno Welzel

    (@awelzel)

    Please also note: Using a numerical timezone like “-0800” is NOT POSSIBLE in PHP 5.5 or older and Timed Content will then always fall back to UTC and all given times are used as UTC and not local time!

    So eventhough Timed Contend may work with even older PHP 5 versions, you must use “America/Los_Angeles” instead of “-0800” to get the correct time. Beginning with PHP 5.6 timezones can specified as offset to UTC, but older PHP version require one of the timezones as documented here: https://www.php.net/manual/en/timezones.php

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Still seeing: Fatal error: Uncaught exception’ is closed to new replies.