/    Sign up×
Community /Pin to ProfileBookmark

Positioning a table inside another table problem

Hello,

I have a problem positioning a table inside another table. The main table has 2 rows with 2 cells each. The first row is supposed to have, the inside company selection table in the first cell and the company building picture into the other cell, my problem is that the company building picture is bigger than the inside company selection table so it makes the whole row as big to fit the company picture and then it keeps on placing the inside company selection table center into the first cell. I do not want the inside company selection table to be on the center, I want it to be on the top of the cell. I have already try with “ALIGN=Top” into the image tag and into the TD tag but nothing works. Do you have any idea what I can do?

?

Thank you,
Veronica

to post a comment
HTML

8 Comments(s)

Copy linkTweet thisAlerts:
@the_treeMar 29.2005 — Although I can't get why you're nesting tables. The awnser (assuming I'm reading the question right) isn't difficult.[code=html]<td style="vertical-align: middle;">
<img style="margin: auto;" />
</td>[/code]
Copy linkTweet thisAlerts:
@vlealauthorMar 29.2005 — Well, you know I am pretty new at this. My inside table is my "content" that link to the other pages.

Thank you for your help. I will try it.
Copy linkTweet thisAlerts:
@the_treeMar 29.2005 — Well I presumed that your table would contain content, but if the inner table serves that purpose, then what the outer table for?
Copy linkTweet thisAlerts:
@vlealauthorMar 29.2005 — Well in order to display the "company building picture" beside the "content" table, I needed a table right? I am not sure I am doing it right but it works.

By the way, I tried what you told me and it worked. I have another question: What is the purpose of <IMG STYLE="MARGIN:AUTO;">?

I just did the <TD STYLE="VERTICAL-ALIGN:... and it did what I wanted.

Thank you again.
Copy linkTweet thisAlerts:
@the_treeMar 29.2005 — Well in order to display the "company building picture" beside the "content" table, I needed a table right?[/QUOTE]I don't think so. From what your describing, you'd just need to apply [i]stlye="float:left;"[/i] to the picture of the company building.
I have another question: What is the purpose of <IMG STYLE="MARGIN:AUTO;">?

I just did the <TD STYLE="VERTICAL-ALIGN:... and it did what I wanted.[/QUOTE]
Force of habbit mostly, when your using text-align you'll find that you need the margins to get the image to move with the text.

By the way, the technical specifications use all lower case HTML, try to keep to that.
Copy linkTweet thisAlerts:
@vlealauthorMar 29.2005 — Ok. I did as you recommend. I have now my content table vertical align to the top and the image is not in a table anymore but <img style="float:right;"> But, I have another problem: I want my text align to the right and justify. How can I do it?


Thank you.
Copy linkTweet thisAlerts:
@ray326Mar 30.2005 — Well, you know I am pretty new at this. My inside table is my "content" that link to the other pages.

Thank you for your help. I will try it.[/QUOTE]

If you're "new at this" then don't learn the wrong way to do it. You shouldn't be using tables for layout. Learn how to do it correctly from the start.
Copy linkTweet thisAlerts:
@the_treeMar 30.2005 — If you're "new at this" then don't learn the wrong way to do it. You shouldn't be using tables for layout. Learn how to do it correctly from the start.[/QUOTE]Ray! I was getting there! I didn't see that she needed to be told that [url=http://hotdesign.com/seybold]tables for layout are stupid[/url] when it sounds like her "content" uses a table legitimetly. Of course she shouldn't learn the wrong way, wich is why I've already corrected the use of her containing table.

I want my text align to the right and justify. How can I do it?[/quote]I'm not to sure about that, [i]text-align: justify;[/i] will justify you're text, and [i]text-align: right;[/i] will put it to the right, it doesn't seem possible to do a hybrid of the two. You might get better results asking in the CSS forum but if not, you'll just have to settle with one or the other.
×

Success!

Help @vleal 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.17,
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: @nearjob,
tipped: article
amount: 1000 SATS,

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

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