Jump to content

Parse error: syntax error, unexpected T_LNUMBER, expecting ',' or ';' in /var/ww


frijole

Recommended Posts

Not sure what is wrong with this, any ideas?

 

<?php

    if($_POST) {

        echo "<table border="1" align=\"center\">";
        
        foreach($artists as $artist) {

          switch ($artist) {


           case "dali":     //show Dali picture
                echo "<tr><td><b>Salvador dali</b></td><td><img src="http://upload.wikimedia.org/wikipedia/commons/thumb/2/24/Salvador_Dal%C3%AD_1939.jpg/180px-Salvador_Dal%C3%AD_1939.jpg"></td></tr>";

                break;

           case "vanGogh":  //show Van Gogh picture
                echo "<tr><td><b>Vincent Van Gogh</b></td><td><img src="http://upload.wikimedia.org/wikipedia/commons/thumb/3/38/VanGogh_1887_Selbstbildnis.jpg/170px-VanGogh_1887_Selbstbildnis.jpg"></td></tr>";

                break;

           case "escher":   //show Escher picture
                echo "<tr><td><b>M. C. Escher</b></td><td><img src="http://upload.wikimedia.org/wikipedia/en/thumb/4/43/EscherSelf1929.jpg/220px-EscherSelf1929.jpg"></td></tr>";

                break;

           case "picasso":   //show Picasso picture
                echo "<tr><td><b>Pablo Picasso</b></td><td><img src="http://upload.wikimedia.org/wikipedia/commons/thumb/9/98/Pablo_picasso_1.jpg/180px-Pablo_picasso_1.jpg"></td></tr>";

                break;
           }

      echo "</table>";

    } else {

?>

<form action="<?php echo $_SERVER[php_SELF]; ?>" method="POST">

<input type="text" name="firstName" size="25"><br />
<select name="options[]" size="4" multiple id="options[]">

               <option value="dali">Salvador Dali</option>
               <option value="vanGogh">Vincent Van Gogh</option>
               <option value="escher">M. C. Escher</option>

               <option value="picasso">Pablo Picasso</option>       
                         
</select><br />
<INPUT TYPE="image" SRC="./images/kaufen.jpg" BORDER=0 ALT="Submit">

<input type="reset" value="Reset">


<?php } ?>

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.