[SOLVED] misplaced HTML output

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Xelmepa
Forum Commoner
Posts: 41
Joined: Sat Aug 24, 2002 3:02 pm
Location: Athens, Greece
Contact:

misplaced HTML output

Post by Xelmepa »

Misplaced is possibly not the best word to describe it but anyway, here goes:


I have a script that accesses a MySQL database, querys it for information, echos the information it receives using a while loop, closes the mysql connection, and then echos a dynamic (in the sense that it is affected by a variable) html link.

While I would expect to get the table with the information from the database and underneath that, the link, for some reason the link appears over the table.

Any ideas?

PS: Sorry for not posting the code but it contains sensitive information which I am lazy to edit :P

Thanks in advance.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

without posting the code I can't say for any certainty, however, I would take a stab with: you are probably echoing the link outside a table row, in which case, it will appear above the table.

If you don't post the code, we can't help much..
User avatar
Xelmepa
Forum Commoner
Posts: 41
Joined: Sat Aug 24, 2002 3:02 pm
Location: Athens, Greece
Contact:

Post by Xelmepa »

Yes everything coming out of the database is in a table.

The link is a seperate echo.

So you're saying it appears above the table?
Any fix for that?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

can you post the finalized html?

What I was saying was, if the link is echo'd outside a table cell, but inside the table, it will appear above the table when rendered..
User avatar
Xelmepa
Forum Commoner
Posts: 41
Joined: Sat Aug 24, 2002 3:02 pm
Location: Athens, Greece
Contact:

Post by Xelmepa »

Yes that was the problem.
Thank you! :D
Post Reply