Meridious Posted April 14, 2008 Share Posted April 14, 2008 I have website using a php script. I have been able to add a users online script to it. The problem I have is that it doesn't show where I want it to. In html, if you want to have something centered on the page, you use the <center> function. How do you do this with php ? Or better yet, is it possible to do ? If it helps, the script uses the php and tpl files together. Quote Link to comment Share on other sites More sharing options...
unidox Posted April 14, 2008 Share Posted April 14, 2008 Can we see html and php code? Quote Link to comment Share on other sites More sharing options...
AndyB Posted April 14, 2008 Share Posted April 14, 2008 The php script generates the html that is displayed in your browser. Use whatever centering method you want by adding the necessary html in the right place in your script. Quote Link to comment Share on other sites More sharing options...
Caesar Posted April 14, 2008 Share Posted April 14, 2008 You can print out (Or echo) any HTML you like. <?php echo' <div id="online"> '.$users_online.' </div>'; ?> Quote Link to comment Share on other sites More sharing options...
Meridious Posted April 14, 2008 Author Share Posted April 14, 2008 Can we see html and php code? The html code is from the footer. Looks like this. <table width="75%" align="center" cellpadding="3" cellspacing="0" border="0"> <tr> <td align="right"> {$drop} </td> </tr> </table> <!--End content, begin footer--> {if $settings.stats}<div align="center">{$debug_info.0} Queries Used<br />{$debug_info.1} Seconds to execute</div>{/if} <p /> {*Don't touch the copyright!*} <div align="center"> Powered by <a href="http://www.phparena.net/scripts.php?script=pafiledb" target="_blank">paFileDB {$version}</a><br /> ©2005-2007 PHP Arena </div> </body> </html> Not exactly sure what you are wanting to see from the php code. Quote Link to comment 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.