Jump to content

Milshak

Members
  • Posts

    7
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Milshak's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Hi I want to create a photo gallery using PHP/MySQL. I'm having trouble comming up with the algorythm to put more than one record per line. any input would be appreciated
  2. try putting the variables in an include file such as configure.php
  3. I think what's happening is that $ans is an array and the user imputs are separate elements try to concatinate the user imput try this $ans = $_POST[first] .$_POST[calc] .$_POST[second]; note the periods
  4. on one of my sites I use this; if($row[4]==""){ echo"<td class=\"producttext\"><a href=\"details.php?id=$row[0]&storeID=$storeID&currency=$currency\"><img src=\"../images/savers/image_not_available.jpg\"></a></td>"; }else{ echo "<TD valign=\"top\" class=\"producttext\"><a href=\"details.php?id=$row[0]&storeID=$storeID&currency=$currency\"> <img src=\"../images/savers/$row[4]\"></a> </TD>"; } where row[4] would be my image variable
  5. if there is a null in the image varialbe it will not display the image but the HTML is still there so you get a image missing x on the browser. Try a n if statement to check that the image exits first if so display it other wise display a default image or don't sent any html. if(row_Bilder[1}( img src=<?php echo $row_Bilder['bilde1]; } else{ display either a default image or no image.
  6. Try to send the the record id which should be part of the databse as an autoincrement colum like this page.php?id=$id Then use this id to modify your query with; select * from tablename where id=$id.
×
×
  • 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.