unexpected T_STRING problem..

Ask a Question related to PHP Development, Design and Development.

  1. #1

    Default unexpected T_STRING problem..

    hi

    with this function i get:

    function retournlisteartricle($nosection)
    {
    echo '<table>';

    $requete = mysql_query("SELECT art_noarticle, art_titre FROM ARTICLE
    WHERE sou_nosoussection=$nosection");
    // affiche l'article en question
    if ( mysql_num_rows($requete) != 0 )
    {
    while ($ligne = mysql_fetch_assoc($requete))
    {
    echo'<tr><td><a
    href="lsttutoriel.php?art_noarticle='.$ligne["art_noarticle"].'">'.$ligne["art_titre"].'</a></td></tr>';
    }
    }
    echo '</table>';

    }

    Parse error: parse error, unexpected T_STRING, expecting ']'


    any idea
    --
    Borland rulez [url]http://pages.infinit.net/borland[/url]
    Marc Collin Guest

  2. Similar Questions and Discussions

    1. unexpected T_STRING in (newbe)
      Hi, I am trying to fill a database mysql with php. if (!$db){ echo "Error: Could not connect to database. Please try again later."; exit; }...
    2. #40790 [NEW]: List interface parsed as T_LIST instead of T_STRING
      From: markpk at gmail dot com Operating system: PHP version: 5.2.1 PHP Bug Type: Scripting Engine problem Bug description: ...
    3. PHP Parse error: parse error, unexpected t_string
      Thanks for your advice. It was a painstaking exercise and highly frustrating not being able to start Live data. Peter Kamstra
    4. Problem with Unexpected quits in Adobe Software
      Hi, just wanted to see if anyone has any good suggestions on this topic. I am running a G3 Mac with a 400mhz processor and running OS 9.1 and I am...
    5. parse error, unexpected T_STRING
      in the line "include(sign.php);" the file name should be in quotes; like include("sign.php"); hth Kurt Milligan sky2070 wrote:
  3. #2

    Default Re: unexpected T_STRING problem..

    "Marc Collin" <os2@videotron.ca> wrote in message
    news:Iq_jc.119258$Tu2.2280758@weber.videotron.net. ..
    > hi
    >
    > with this function i get:
    >
    > function retournlisteartricle($nosection)
    > {
    > echo '<table>';
    >
    > $requete = mysql_query("SELECT art_noarticle, art_titre FROM ARTICLE
    > WHERE sou_nosoussection=$nosection");
    > // affiche l'article en question
    > if ( mysql_num_rows($requete) != 0 )
    > {
    > while ($ligne = mysql_fetch_assoc($requete))
    > {
    > echo'<tr><td><a
    >
    href="lsttutoriel.php?art_noarticle='.$ligne["art_noarticle"].'">'.$ligne["a
    rt_titre"].'</a></td></tr>';
    > }
    > }
    > echo '</table>';
    >
    > }
    >
    > Parse error: parse error, unexpected T_STRING, expecting ']'
    You probably need to \" up your quotes in the echo...

    --
    Gorf


    Gorf Guest

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139