nkarafo Posted May 11, 2012 Share Posted May 11, 2012 Hello to everyone! we have a website: http://www.ierapostoli.gr/ I have used php require to load the top, left, center, right and bottom column pages in table. So far so good BUT I don't like it very much because it will load top, left, center and after some time it will load right and it's not looking so good. Top, bottom, left and right are always the same page. I would like to load firstly top, left and right and afterwards the main center which is somehow heavy in text and photos. Is there any solution or do I have to re configure the whole thing? Thank you very very much !!!! Here is my code for index.php <html> <head> <title>Ierapostoli</title> <meta http-equiv="Content-Type" content="text/html; charset=windows-1253"> <style type="text/css"> <!-- @import url(http://www.ierapostoli.gr/main.css); .style14 {font-weight: bold} .style9 {font-style: italic} .style16 {color: #003366} --> </style> <?php require ("/var/www/vhosts/ierapostoli.gr/httpdocs/top.htm"); ?> <style type="text/css"> <!-- p.MsoNormal { margin-top:0cm; margin-right:0cm; margin-bottom:10.0pt; margin-left:0cm; line-height:115%; font-size:11.0pt; font-family:"Calibri","sans-serif"; } .style24 {color: #FF0000} --> </style> </head> <body bgcolor="#000066" vlink="#0000FF" onLoad="goforit()"> <table width="100%" border="0" bordercolor="#000066" bgcolor="#000066"> <tr> <td width="10%" align="left" valign="top"> <?php require ("/var/www/vhosts/ierapostoli.gr/httpdocs/left.htm"); ?></td> <td width="80%" class="White"><table width="100%" border="0"> <tr> <td width="72%" class="main_index"><table width="100%" border="1" cellpadding="2" cellspacing="0" bordercolor="#999999" class="Dark-Blue"> <tr> <td height="26" class="New3"><p class="New3"><strong>(New !)</strong> A new article </p></td> </tr> </table> <table width="100%" border="0"> <tr> <td><p align="justify"> <a href="2012/images/Botsouanas.jpg" target="_blank"><img src="2012/images/Botsouanas_small.jpg" width="65" height="100" border="0" align="left"></a>A brief synopsis of the article </p></td> </tr> </table> <table width="100%" border="1" align="center" cellpadding="2" cellspacing="0" bgColor=#efefef> <TR> <TD align=middle><div align="center"><a target="_self" href="2012/I.Episkopi_Botsouanas.php">Read more ...</a></div></td> </tr> </table> </td> </tr> </table></td> <td width="10%" align="right" valign="top"><?php require ("/var/www/vhosts/ierapostoli.gr/httpdocs/right.htm"); ?> </td> </tr> </table> <?php require ("/var/www/vhosts/ierapostoli.gr/httpdocs/bottom.htm"); ?> <!-- Start of Google Analytics Code --> <script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', 'UA-16571507-2']); _gaq.push(['_trackPageview']); (function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script> <!-- End of Google Analytics Code --> </body> </html> Quote Link to comment https://forums.phpfreaks.com/topic/262417-php-with-3-columns/ Share on other sites More sharing options...
Drummin Posted May 11, 2012 Share Posted May 11, 2012 This is not really a php issue. Please consider looking into divisions and floats for your layout instead of nested tables. By learning this you can load top, left, right then center then foot. You'll need to learn basic floats but a very simple example. Take your post to the html section of this site. <div class="header"></div> <div class="clear"></div> <div class="wrapper"> <div class="leftcolumn"></div> <div class="rightcolumn"></div> <div class="center"></div> </div> <div class="clear"></div> <div class="foot"></div> Quote Link to comment https://forums.phpfreaks.com/topic/262417-php-with-3-columns/#findComment-1344844 Share on other sites More sharing options...
nkarafo Posted May 11, 2012 Author Share Posted May 11, 2012 This is not really a php issue. Please consider looking into divisions and floats for your layout instead of nested tables. By learning this you can load top, left, right then center then foot. You'll need to learn basic floats but a very simple example. Take your post to the html section of this site. <div class="header"></div> <div class="clear"></div> <div class="wrapper"> <div class="leftcolumn"></div> <div class="rightcolumn"></div> <div class="center"></div> </div> <div class="clear"></div> <div class="foot"></div> Thank you for your reply. Ok, I transfered the topic to HTML. I thought that using PHP files and the command require I should put it here in PHP but I made a mistake. I'm sorry. I don't understand the solution very well with divisions & floats, but I believe I will find an answer. Thanks again. Quote Link to comment https://forums.phpfreaks.com/topic/262417-php-with-3-columns/#findComment-1344848 Share on other sites More sharing options...
Maq Posted May 11, 2012 Share Posted May 11, 2012 Don't double post. In the future, place OR tags around your code. Quote Link to comment https://forums.phpfreaks.com/topic/262417-php-with-3-columns/#findComment-1344882 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.