WordPress.org

Forums

[Plugin: WP-Invites] PHP Parse Error (9 posts)

  1. scv0
    Member
    Posted 6 years ago #

    I've got this PHP error message when activating the plugin under Wordperss 2.9.2:

    Parse error: syntax error, unexpected '}' in /home/a3164889/public_html/wp-content/plugins/wp-invites/wp-invites.php on line 157

    http://wordpress.org/extend/plugins/wp-invites/

  2. scv0
    Member
    Posted 6 years ago #

    Tried to install automatically via WP - everything works fine! Oo

  3. JQmenn
    Member
    Posted 6 years ago #

    Help! I have the same thing! gives the error

    Parse error: syntax error, unexpected ')' i. ................................... ......... / htdocs / wp-content / plugins / wp-invites / wp-invites.php on line 157

    What? How to install a plugin ????? WordPress version 3.0

  4. Jehy
    Member
    Posted 5 years ago #

    That's trouble with your hosting or FTP manager.
    Try installing via wordpress admin tools.

  5. Gene53
    Member
    Posted 5 years ago #

    That's trouble with your hosting or FTP manager.
    Try installing via wordpress admin tools.

    Since a few people have reported this parse error, I think the problem lies in your code.

    I installed this plugin on 3 different WP sites with different hosting companies and I get the infamous parse error on line 157. I tried both the automatic installs and FTP but to no avail.

    While you're at it, you should also insert a space between Error: and Wrong in the Error:Wrong invite code line.

    Cheers

  6. lalitkishore
    Member
    Posted 5 years ago #

    I am having a peculiar problem. I am using the plugin along with the widget in wordpress 3.0.1. Everything works fine and the mails are delivering. But when an invite is send to a mail with a period as allowed by gmail it sends the mail to the email address including portion after the period. For example I sent an invite to lalit.kishore@gmail.com but when I checked the mail delivery logs the mail was sent to kishore@gmail.com and the result was that the mail was not delivered. This was not the only instance and the same behavior was shown in mails having similar ids. I am sure there must be some solution to it.

  7. Jehy
    Member
    Posted 5 years ago #

    Plugin does not send any emails by itself.
    If you mean registration emails - those are send with wordpress mechanics, and the trouble is wordpress bug.

  8. GoodSoul
    Member
    Posted 5 years ago #

    The plugin does not work on WP 3.1 and BP 1.2.8. Emails are not coming to users, although the plugin reports that the message was successfully sent.

  9. tritonBear
    Member
    Posted 5 years ago #

    I had the same thing happen on a fresh new wp install where using wp-invites widget and inviting emails containing periods resulted in a parsing error.

    Found the culprit here:
    file:
    plugins/wp-invites-widget/wp-invites-widget.php

    function ajax_wp_invites_widget () {
      preg_match_all ('/([a-zA-Z0-9])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-]+)+/i', $_POST ['email'], $emails);

    Changed preg_match_all regex to:

    preg_match_all ('/([a-zA-Z0-9\._-])+@([a-zA-Z0-9_-])+(\.[a-zA-Z0-9_-]+)+/i', $_POST ['email'], $emails);

    I added '_' and '-' to the regex as well since those are also common in emails. Is this regex even needed?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags