• Resolved wb1234

    (@wb1234)


    Thanks for the great plugin.

    Suddenly, on one of my WP blogs, SEO Framework crashed. In uninistalled and reinstalled. When I activate it I get:

    Parse error: syntax error, unexpected ‘)’ in /var/www/html/mywebsite.com/blog/wp-content/plugins/autodescription/bootstrap/upgrade.php on line 507

    i looked at the code:
    “SELECT 1 FROM $table WHERE meta_key IN (‘$indexes’) LIMIT 1″,

    So it looks like either $table or $indexes has an un-escaped ‘

    Any ideas of how to fix? I can get into SQL if needed.

Viewing 8 replies - 1 through 8 (of 8 total)
  • To add to the conversation, this is happening on older php version 7.2.24.

    In that version there is a parse error. When plugin author puts the ‘)’ on other line the script will work.

    Thread Starter wb1234

    (@wb1234)

    Ok. Let me update the php version there…

    Plugin Author Sybre Waaijer

    (@cybr)

    Hello! Thank you for the prompt report.

    This issue should only affect sites installing TSF for the first time. This line checks if old metadata from other SEO plugins is present and prompts for data migration. The input variables are escaped, but the escaping technique can differ per server.

    I wonder, are you using a Windows-based IIS web server on the new site?

    If you’re unsure, please go to /wp-admin/site-health.php?tab=debug and hit “Copy site info to clipboard”. Strip out any data you think we do not need and send it over to me at https://tsf.fyi/contact/. This data allows me to replicate the server environment.

    In the meantime, to get your site going with The SEO Framework, you can get the previous plugin version from here: https://downloads.wp.xz.cn/plugin/autodescription.4.2.6.zip, and upload that file archive via WordPress’s default plugin installer.

    Plugin Author Sybre Waaijer

    (@cybr)

    In that version there is a parse error. When plugin author puts the ‘)’ on other line the script will work.

    AH! Trailing commas. I did test for PHP 7.2 but didn’t try a fresh install. Thank you for that! Will send out a patch momentarily, but without a version change because it only affects new installations.

    This syntax error affects every site loading that file. I shall do a version bump after all.

    Correction, the comma needs to be removed.

    "SELECT 1 FROM$tableWHERE meta_key IN ('$indexes') LIMIT 1") ) {

    Thread Starter wb1234

    (@wb1234)

    Confirmed – update to php 7.4 fixed it.

    Sorry to bug you guys. Thanks for the speedy reply.

    Plugin Author Sybre Waaijer

    (@cybr)

    You should not be sorry at all! I claimed support for PHP 7.2, and I should’ve delivered.

    Thank you, @opicron, for the pointer. Cheers 🙂

    • This reply was modified 3 years, 7 months ago by Sybre Waaijer. Reason: grammar
    Plugin Author Sybre Waaijer

    (@cybr)

    TSF v4.2.7.1 is now available, addressing the issue.

    Have a beautiful day (and night)!

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘syntax error’ is closed to new replies.