CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Apr 2008
    Posts
    1

    Parse error: syntax error

    Please help me ...

    Code:
    Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/sycn664/public_html/phpbb/includes/functions.php on line 3438

    And here is the line on functions.php that is showing the error ..

    Code:
    $lasttimechecked = $row['user_last_comm_check'];

    thanks

  2. #2
    Join Date
    Apr 2002
    Location
    Egypt
    Posts
    2,210

    Re: Parse error: syntax error

    Sometimes errors are related to lines before the one mentioned in the error message. So try to look there too.
    Hesham A. Amin
    My blog , Articles


    <a rel=https://twitter.com/HeshamAmin" border="0" /> @HeshamAmin

  3. #3
    Join Date
    May 2002
    Posts
    10,943

    Re: Parse error: syntax error

    To add to what hspc has already said...Since you are using a variable named $row, I am assuming that this is an associative array from a database row. Is this the case?

    If so, you might want to double-check your SQL query as well.
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

  4. #4
    Join Date
    Nov 2004
    Location
    Slough, UK
    Posts
    184

    Re: Parse error: syntax error

    Quote Originally Posted by PeejAvery
    To add to what hspc has already said...Since you are using a variable named $row, I am assuming that this is an associative array from a database row. Is this the case?

    If so, you might want to double-check your SQL query as well.
    Parsing is carried out by the interpreter before the code is executed so therefore there won't be any distinction between weather the variable is an array / string or any other type.

    The text of the error "unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING" suggests you may have forgotten a semi colon on the previous line.
    PHP || MySql || Apache || Get Firefox || OpenOffice.org || ClickOnline ||

    Did I ever say I was an expert?

    | PHP Session --> Database Handler * Custom Error Handler * Installing PHP * HTML Form Handler * PHP 5 OOP * Using XML * Ajax | VB6 Winsock - HTTP POST / GET * Winsock - HTTP File Upload

    Please mark threads resolved by going to the thread tools menu and clicking the Mark Thread Resolved button.

    Has a post really helped you? Please Rate it.

  5. #5
    Join Date
    May 2002
    Posts
    10,943

    Re: Parse error: syntax error

    Yes, you are correct visualAd, but...I saw that the OP also posted the same problem here. You will notice that his/her problem is incorrect quotations and setup of the SQL query. Hence what I said.

    Issue was resolved in that forum.
    If the post was helpful...Rate it! Remember to use [code] or [php] tags.

  6. #6
    Join Date
    Nov 2004
    Location
    Slough, UK
    Posts
    184

    Re: Parse error: syntax error

    That's where syntax highlighters come in useful. Error by colours
    PHP || MySql || Apache || Get Firefox || OpenOffice.org || ClickOnline ||

    Did I ever say I was an expert?

    | PHP Session --> Database Handler * Custom Error Handler * Installing PHP * HTML Form Handler * PHP 5 OOP * Using XML * Ajax | VB6 Winsock - HTTP POST / GET * Winsock - HTTP File Upload

    Please mark threads resolved by going to the thread tools menu and clicking the Mark Thread Resolved button.

    Has a post really helped you? Please Rate it.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured