Jump to content

how to set up file value


franknu

Recommended Posts

You want the picture to display in the input box? That is kind of absurd. This is what you would need to do:

 

<?php
echo '<input name="Picture1" type="file" value="" /><img src="' . $row['Picture1'] . '" />';
?>

 

That way the image will display next to the box. It is impossible to get it to display as the value.

my problem is that i want people to update the pictures and if the values doent show it meant that they will have to uodate pictures every time that they make changes to the pages here is my code

 


IF ($moved1=true  and $moved2=true and $moved3=true and $moved4=true and $moved5=true and $moved6=true) :
    
$query="UPDATE  business_info  SET BusinessName= ('$_POST[businessName]'), `Slogan`=('$_POST[slogan]'),
               Business_Address = ('$_POST[business_Address]'), Tel=('$_POST[Tel]'), Website= ('$_POST[Website]'),
               Email = ('$_POST[Email]'), Fax= ('$_POST[Fax]'), `type`='$type',
               make = '$make', Categories = ('$_POST[Categories]'), Keyword = ('$_POST[Keyword]'),  `Picture1` = '$fullpath1',
               Headline = ('$_POST[Headline]'), Slogan2 = ('$_POST[slogan2]'), Description1 = ('$_POST[Description1]'),
               Description2 = ('$_POST[Description2]'), Description3 =  ('$_POST[Description3]'),
               `Picture2` = '$fullpath2', `Picture3` = '$fullpath3',
                 `Picture4` = '$fullpath4', `Picture5` = '$fullpath5',
                 `Picture6` = '$fullpath6',
`Password`= '$Password' WHERE User_Name = '$User_Name'";


$result = mysql_query($query) or die ("Problem with the query: <pre>$query</pre><br>" . mysql_error());




  ENDIF;
ENDIF;


Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.