/    Sign up×
Community /Pin to ProfileBookmark

Insert images into table cells

Hi, I want to insert images into the table cells. Is it possible?
My code is here but failed.
Just tried one cell!Thanks.

[CODE]<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>

<html xmlns=”http://www.w3.org/1999/xhtml”>
<head>
<title></title>
<style type=”text/css”>
.style1
{
font-size: large;
}
.style2
{
width: 100&#37;;
height: 584px;
}
.style8
{
height: 130px;
width: 218px;
}

</style>
</head>
<body>

<p class=”style1″ style=”text-align: center”>
<strong>2010 AAAAA Activities</strong></p>

<table class=”style2″>
<tr>
<td class=”style8″>
<img src=”Photos/2010/DSC_0113one.jpg” width=”200″ /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”height: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”height: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
</tr>
<tr>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 220px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”height: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”height: 200px” /></td>
</tr>
<tr>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
</tr>
<tr>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
</tr>
<tr>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
<td class=”style8″>
<img alt=”” src=”” style=”width: 200px” /></td>
</tr>
</table>

</body>
</html>
[/CODE]

to post a comment
HTML

4 Comments(s)

Copy linkTweet thisAlerts:
@tirnaJan 07.2011 — are you sure the path to the file in your src is correct and that the file exists? Probably better to start path names with either / or ./ or ../
Copy linkTweet thisAlerts:
@zhshqzycauthorJan 07.2011 — are you sure the path to the file in your src is correct and that the file exists? Probably better to start path names with either / or ./ or ../[/QUOTE]
I am sure and I did tried ./ something. I heard that only text or background img can be placed in the cells. Is it true?
Copy linkTweet thisAlerts:
@J0106PrestonJan 07.2011 — No. You can put images in cells. I do it all of the time for Email advertisements.

If you're doing it for email ads, it's best to upload the images before linking them, because some emailer clients will break the link of the image. Here's table based email page from me for you to check out the code of:

http://jonprestonstudios.com/images/colemans/010411.html

<tr style="background-color:#FFF">

<td width="180"><img src="sleepbag.jpg" alt="US GI Modular Sleep System &quot;MSS&quot;" width="180" height="155" /></td>

<td style="font-family:Verdana, Geneva, sans-serif; color:#333; font-size:12px; padding:5 10 10 10">

<div align="center"; style="padding-bottom:10px"><strong style="font-size:16px; font-weight:bold;">US GI Modular Sleep System "MSS"</strong></div>

Never wake up cold and wet again! This is the real deal, not an imported after market product that has been showing up in other surplus stores! This U.S. G.I. four part modular sleep system was designed to be used together for temperatures as low as -30&deg;. Here's what's included... One Compression sack (black) for compact storage, one cold weather patrol sleeping bag (black), one intermediate sleeping bag (olive), and one Waterproof/Breathable Bivy cover (woodland camouflage) to keep the whole system dry. This system was designed in layers to trap in pockets of air and heat. The complete system, including the compression sack, weighs roughly twelve pounds. Compare our pricing to others, selling for up to $400.00. Made in the U.S.A. Some compression sacks may have imperfections. Used, Good Condition.<br /><br />
<span style="color:#003; font:Verdana, Geneva, sans-serif; font-weight:bold;">Price: $125</span></td>
</tr>
Copy linkTweet thisAlerts:
@DrPepperJan 07.2011 — Your problem is most certainly a path error, but just in case go ahead and validate the html just to rule out any minuscule errors that could have slipped by.

http://validator.w3.org/

Your next step would be to use a FULL path because its guaranteed to work.

FULL path example.

http://www.krazyexample.com/folder/supersecretphoto.jpg

If that works, you can shorten it to /folder/supersecretphoto.jpg

I have never used ./ like was suggested earlier, but if thats what floats your boat, and it works, go for it.

Now, if using the FULL path doesn't work you have a couple of possibilities for what could be the problem.
[LIST]
  • [*]misspelled/wrong file name

  • [*]file was not uploaded yet

  • [*]file was placed in the wrong directory

  • [*]misspelled FULL path

  • [*]file is corrupt

  • [*]the government is foiling your plot to take over the world through the censorship of your table photo

  • [/LIST]
    ×

    Success!

    Help @zhshqzyc spread the word by sharing this article on Twitter...

    Tweet This
    Sign in
    Forgot password?
    Sign in with TwitchSign in with GithubCreate Account
    about: ({
    version: 0.1.9 BETA 6.1,
    whats_new: community page,
    up_next: more Davinci•003 tasks,
    coming_soon: events calendar,
    social: @webDeveloperHQ
    });

    legal: ({
    terms: of use,
    privacy: policy
    });
    changelog: (
    version: 0.1.9,
    notes: added community page

    version: 0.1.8,
    notes: added Davinci•003

    version: 0.1.7,
    notes: upvote answers to bounties

    version: 0.1.6,
    notes: article editor refresh
    )...
    recent_tips: (
    tipper: @meenaratha,
    tipped: article
    amount: 1000 SATS,

    tipper: @meenaratha,
    tipped: article
    amount: 1000 SATS,

    tipper: @AriseFacilitySolutions09,
    tipped: article
    amount: 1000 SATS,
    )...