Retrieve dropdown menu and image path from the database

  • (2 Pages)
  • +
  • 1
  • 2

26 Replies - 6049 Views - Last Post: 18 August 2011 - 06:51 PM Rate Topic: -----

#16 aaron1178  Icon User is offline

  • Dovakiin, Dragonborn
  • member icon

Reputation: 98
  • View blog
  • Posts: 1,178
  • Joined: 22-October 08

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 05:56 PM

Ok, so in what directory did you store the image?
Was This Post Helpful? 0
  • +
  • -

#17 chukwuemmanuel09  Icon User is offline

  • D.I.C Head

Reputation: -10
  • View blog
  • Posts: 52
  • Joined: 18-August 11

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 05:58 PM

This dir <img src='Images/properties/.../>
Was This Post Helpful? 0
  • +
  • -

#18 aaron1178  Icon User is offline

  • Dovakiin, Dragonborn
  • member icon

Reputation: 98
  • View blog
  • Posts: 1,178
  • Joined: 22-October 08

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:07 PM

Ok try with this

<img src=<?php echo "Images/properties/".$file; ?> width=width height=height>


Was This Post Helpful? 0
  • +
  • -

#19 chukwuemmanuel09  Icon User is offline

  • D.I.C Head

Reputation: -10
  • View blog
  • Posts: 52
  • Joined: 18-August 11

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:10 PM

Should i insert it after the image value? where should i add it?
Was This Post Helpful? 0
  • +
  • -

#20 aaron1178  Icon User is offline

  • Dovakiin, Dragonborn
  • member icon

Reputation: 98
  • View blog
  • Posts: 1,178
  • Joined: 22-October 08

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:11 PM

Add the above to where you want to image to display
Was This Post Helpful? 0
  • +
  • -

#21 chukwuemmanuel09  Icon User is offline

  • D.I.C Head

Reputation: -10
  • View blog
  • Posts: 52
  • Joined: 18-August 11

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:17 PM

Hmm..That code just displayed the images. all i wanted was for it to add the image path to the upload field..
Was This Post Helpful? 0
  • +
  • -

#22 aaron1178  Icon User is offline

  • Dovakiin, Dragonborn
  • member icon

Reputation: 98
  • View blog
  • Posts: 1,178
  • Joined: 22-October 08

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:19 PM

You cannot directly set a default file for the file input type, I found a script that will do it for you though this is untested

<html>
<head></head>
<body>
<form name="test_form" method="post" action="test.jsp">
<input type=file name=browse style="display: none;">
<input type=text name=file value=c:/test.jpg>
<input type=button
style="font-style:veranda; font-size:12px; font-weight:bold;text-transform:lowercase;color:white;background-color:#A2C382;height:22px;border-style:ridge;text-align:center;"
onclick="browse.click();file.value=browse.value;"
value="Select a File..."> 
<br><br>
<!-- must be clicked twice for the form to submit! -->
<input type=submit
value="Submit The Form Now!"
style="font-style:veranda; font-size:12px;"> 
</form>
</body>
</html>



I've found this script but I cannot see how it works as I had just tested it :( Sorry, I cannot help on this one

This post has been edited by aaron1178: 18 August 2011 - 06:39 PM

Was This Post Helpful? 0
  • +
  • -

#23 chukwuemmanuel09  Icon User is offline

  • D.I.C Head

Reputation: -10
  • View blog
  • Posts: 52
  • Joined: 18-August 11

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:36 PM

Ok man..thx for the help so far...I am still with u
Was This Post Helpful? 0
  • +
  • -

#24 aaron1178  Icon User is offline

  • Dovakiin, Dragonborn
  • member icon

Reputation: 98
  • View blog
  • Posts: 1,178
  • Joined: 22-October 08

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:40 PM

Welcome to Dream.In.Code by the way

This post has been edited by aaron1178: 18 August 2011 - 06:51 PM

Was This Post Helpful? 0
  • +
  • -

#25 chukwuemmanuel09  Icon User is offline

  • D.I.C Head

Reputation: -10
  • View blog
  • Posts: 52
  • Joined: 18-August 11

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:43 PM

Hmmm..what does that line mean.I dont understand.
Was This Post Helpful? 0
  • +
  • -

#26 aaron1178  Icon User is offline

  • Dovakiin, Dragonborn
  • member icon

Reputation: 98
  • View blog
  • Posts: 1,178
  • Joined: 22-October 08

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:49 PM

I was trying to get rep, the green +1 :) Don't worry, and I welcomed you to the Dream.In.Code community
Was This Post Helpful? 0
  • +
  • -

#27 chukwuemmanuel09  Icon User is offline

  • D.I.C Head

Reputation: -10
  • View blog
  • Posts: 52
  • Joined: 18-August 11

Re: Retrieve dropdown menu and image path from the database

Posted 18 August 2011 - 06:51 PM

Ok man..Thx for everything..I appreciate.
Was This Post Helpful? 0
  • +
  • -

  • (2 Pages)
  • +
  • 1
  • 2