iGuest 3 Report post Posted January 14, 2005 A little more help please!Can I imbed php files into a html page?If so how? Im try to put a php counter on my index page http://forums.xisto.com/no_longer_exists/here what the instructions say -To embed the visitor counter in a web page, insert the following line of codeat the top of the PHP page: <?php include "phphits.php"; phphitsAddHit(); ?>Don't forget that phphits.php has to be in the same folder as the PHP page!Also, all files that include counter code should have a *.php-ending.If you want to use the counter in image mode, you need to have 10 GIF images(0.gif, 1.gif ... 9.gif) in the subdirectory specified in phphits.php. You caneither use the images that come with phphits, or create your own ones.a) If you want to show the total number of hits on the page, insert the following lineof code where you want the counter to appear: Hits total: <?php echo(phphitsShowHits(0)); ?> If you also would like to show the number of hits during the last x hours, includethis line of code: Last x hours: <?php echo(phphitsShowHits(x)); ?>where x is the number of hours. For example, Last 24 hours: <?php echo(phphitsShowHits(24)); ?>will show the number of hits counted within the last 24 hours.c) You might also want to give visitors of your site the possibility to see how manyusers are browsing the site at the moment. To add this feature, just add the followingline of code: <?php echo(phphitsShowOnlineUsers()); ?> users onlinewhere in the page do i put <?php include "phphits.php"; phphitsAddHit(); ?> Share this post Link to post Share on other sites
iGuest 3 Report post Posted January 14, 2005 why you want to write in html write in php ist easier Share this post Link to post Share on other sites
iGuest 3 Report post Posted January 14, 2005 why you want to write in html write in php ist easierIm still learning php, Im gonna buy php for dummies book.Any suggestions on my last post Share this post Link to post Share on other sites