Jump to content

[SOLVED] link from pic and db


tml

Recommended Posts

i have a code that works to get a picture from my db:

    echo "<img src='" . $row["sti"] . "' class='foto'/>";

my problem are to make it a link so it open the same picture but in larger view, i have tryid abit and this are what i could think of so fair

    echo "<a href='" . $row["stilarge"] . "'><img src='" . $row["sti"] . "' class='foto'/>"</a>;

but i wont work, i have 3 table, 1 id one, one url like pic/1.jpg(sti) and the last for the large pic (stilarge)

so all i need is the link where it select same id but the large picture. needs to open in same window not like target_new

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.