View Full Version : Cgi Hit Counter
Okay, I'm Very new to CGI but I've created my own ickle hit counter. it's at http://www.brit-celebs.co.uk/cgi-bin/counter.cgi and I was wandering If there's anyway that I can make this output goto a webpage at all.. say http://www.brit-celebs.co.uk
Any Ideas?
Fragmast3r
15-06-2001, 13:54
id imagine on the page u have your counter on you must of typed some sort of code that looks roughly like this
<!--#exec cgi="cgi-bin/mycounter.pl" --> (or something similar)
all u need to do is in your website where ever u want the counter to be just put the code in where the counter is to appear
ohhh, sounds good, sounds quick 'n' easy too :) Cheers bud!
Will have a go at that now!
Erm,Didn't work , I've tried this code as the test.htm page but it doesn't display anything.
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<font face="Tahoma" size="2"><b>
<!--#exec cgi="cgi-bin/counter.cgi" -->
</b></font>
</body>
</html>
the cgi-code which I saved as counter.cgi works fine by itself though.
Try renaming the page as test.shtml. If you want to use SSI you'll usually have to use the .shtml extension.
Cheers,
Chas
Do, I didn't know that line was SSI.... Never mind :)
Thanks CHAS 'n' Fragmast3r
http://www.brit-celebs.co.uk/test.shtml
same code...still doesn't appear to work though....
How and whether you can include CGI scripts like that is server-dependant. The classic way to use CGI is to have a CGI script return an entire HTML page. There are many ways of organising this, but as what seems to be a commercial site, you'll need to be paying consultancy rates for specific detailed advice :)
AEF
...awwww, I'll have to get in-touch with my good buddy Christoph to see about changing servers p'haps
vBulletin® v3.7.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.