/    Sign up×
Community /Pin to ProfileBookmark

Help (tables and text)

I have created a table on the left side of my page, now i want to have pictures on the right side of that page and text in the centre. How is this possible (sorry new to HTML)

to post a comment
HTML

4 Comments(s)

Copy linkTweet thisAlerts:
@Robert_WellockMay 09.2005 — It's best to use CSS for page layout but yes it is possible to align images within a <table> cell.
Copy linkTweet thisAlerts:
@Weeman03authorMay 09.2005 — not images in the table, images on the right of my page

this is roughtly what it is


-----

Table
-----



If i try and put the text on tob of the table code it goes above the table, if down it goes down but if i put the text in the middle it goes higher or lower. i have just started to understand HTML and don't think i could start CSS for a while.

this is what i would like

header

----- ------ ------
Table Text images

----- ------ ------
footer
Copy linkTweet thisAlerts:
@Robert_WellockMay 09.2005 — Like I said CSS, if you don't use CSS then you won't have a cat in hells chance of positioning the images like that if they aren't within the table.

This is really shoddy stuff though:

<table width="100%" border="1">
<tr>
<th colspan="3">
Lorem
</th>
</tr>
<tr>
<td>
Left 1
</td>
<td>
Right 1
</td>
<td>
<img src="image1.png" alt="" />
</td>
</tr>
<tr>
<td>
Left 2
</td>
<td>
Right 2
</td>
<td>
<img src="image1.png" alt="" />
</td>
</tr>
<tr>
<th colspan="3">
x
</th>
</tr>
</table>
Copy linkTweet thisAlerts:
@NogDogMay 09.2005 — It's not a question of learning HTML. HTML is for contextual markup of the text, not for visual presentation. You need to learn CSS if you want to manipulate the positioning and appearance of HTML elements. For example, to achieve your basic layout request:
<i>
</i>&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"&gt;
&lt;html lang='en'&gt;
&lt;head&gt;
&lt;META HTTP-EQUIV='Content-Type' CONTENT='text/html; charset=ISO-8859-1'&gt;
&lt;title&gt;Page title&lt;/title&gt;
&lt;style type="text/css"&gt;
&lt;!--
body {
margin: 0;
padding: 10px;
font: medium arial, sans-serif;
}
#header, #footer {
clear: both;
background-color: silver;
border: solid 1px black;
margin: 0;
padding: 5px 10px;
}
#header { margin-bottom: 10px; }
#footer {margin-top: 10px; }
table {
float: left;
margin: 0;
border-collapse: collapse;
border: solid 1px black;
width: 200px;
font-size: small;
}
th, td {
margin: 0;
padding: 3px 5px;
border: solid 1px black;
}
.right {
float: right;
width: 200px;
margin: 0;
border: solid 1px black;
}
#text {
margin: 0 220px;
padding: 10px;
border: solid 1px black;
}
--&gt;
&lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;h1 id=header&gt;This is the header&lt;/h1&gt;
&lt;table&gt;
&lt;tr&gt;&lt;th&gt;col1&lt;/th&gt;&lt;th&gt;col2&lt;/th&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;row1,col1&lt;/td&gt;&lt;td&gt;row1,col2&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;row2,col1&lt;/td&gt;&lt;td&gt;row2,col2&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;
&lt;img src="bogus.gif" alt="test image" class=right&gt;
&lt;div id=text&gt;
&lt;h2&gt;Text Section&lt;/h2&gt;
&lt;p&gt;This is a test. It is only a test.&lt;/p&gt;
&lt;/div&gt;
&lt;p id=footer&gt;This is the footer&lt;/p&gt;
&lt;/body&gt;
&lt;/html&gt;
×

Success!

Help @Weeman03 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 5.18,
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: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

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

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...