Forums

File Gallery
Parse error (7 posts)

  1. grollaz
    Member
    Posted 4 months ago #

    Hi, i have installed file galleri on my wp 3.3.1 and in top of admin i see always this message:

    Parse error: syntax error, unexpected T_STRING, expecting ')' in /myurl/domain.ext/wp-content/plugins/file-gallery/includes/media-settings.php(287) : runtime-created function on line 5

    What i can do?
    Thanks

    http://wordpress.org/extend/plugins/file-gallery/

  2. Aesqe
    Member
    Posted 4 months ago #

    @grollaz: which version of the plugin do you have installed?

  3. grollaz
    Member
    Posted 4 months ago #

    I use the last version of plugin

  4. Aesqe
    Member
    Posted 3 months ago #

    @grollaz: I hope you're still around, because I'd love to fix this.

    Could you please try installing the latest beta of the plugin, and tell me if you still get this notice?

    You can download it from here: http://downloads.wordpress.org/plugin/file-gallery.zip.

    Thank you! :)

  5. amandajoonline
    Member
    Posted 2 months ago #

    I tried the new version and have the same error. I am using Instant WordPress offline

    Parse error: syntax error, unexpected T_STRING, expecting ')' in D:\Documents\Amanda's Work\InstantWP_4.1\iwpserver\htdocs\wordpress\wp-content\plugins\file-gallery\includes\media-settings.php(287) : runtime-created function on line 5

    As soon as I activate the plugin the dashboard goes funky.

    -Thanks!
    Amanda

  6. Aesqe
    Member
    Posted 2 months ago #

    @grollaz, @amandajoonline: I haven't been able to reproduce this error yet :/

    Which other plugins do you have installed?

  7. crmart
    Member
    Posted 2 weeks ago #

    Hi guys

    We got the same error and figured out why it happened and how you can fix it.

    If you take a look at the file: plugins/file-gallery/includes/media-settings.php on line 270 (version 1.7.4.1), you'll see this line:
    $values = isset($val['values']) ? "'" . $val['values'] . "'" : 0;

    The problem occurs if in the $val['values'] content a single quote is present.
    So we fixed it as follows:
    $values = isset($val['values']) ? "'" . str_replace("'", "'", $val['values']) . "'" : 0;

    I'm not 100% sure this is the actual correct way to fix it, but it seems to work perfectly fine on our site.

Reply

You must log in to post.

About this Plugin

About this Topic