Ronniebootwest Posted September 5, 2005 Report Share Posted September 5, 2005 Now that I have a working Web Site, I would like to be able to determine the number of visits made to the site. How can I add a 'counter' to the site that will update each time someone calls?Ron Quote Link to comment Share on other sites More sharing options...
Michel Posted September 5, 2005 Report Share Posted September 5, 2005 Ron,your site is "writed" in HTML or PHP ? Quote Link to comment Share on other sites More sharing options...
Ronniebootwest Posted September 5, 2005 Author Report Share Posted September 5, 2005 Hi Michel,The site is in html code. Quote Link to comment Share on other sites More sharing options...
Conflow Posted September 5, 2005 Report Share Posted September 5, 2005 Web CountersHi Ron,Try out this one (Hundreds of Styles)..Free.....www.free-counter.com....you need to type it in.Brian.Conflow. Quote Link to comment Share on other sites More sharing options...
Michel Posted September 6, 2005 Report Share Posted September 6, 2005 In the index page, you can also create your counter with a script; one example:http://javascriptkit.com/script/script2/counter.shtmlThis script with options (colors...):Step 1: copy in your HTML beetween <head> and </head><!--Counter--><style>.counter{background-color:black;color:yellow;font-weight:bold;}</style><script>//Personal Counter- by Jaafar Bin Yusof, Singapore (jaafar66@yahoo.com)//Modified by JavaScript Kit (http://javascriptkit.com)//Visit [URL=http://javascriptkit.com]http://javascriptkit.com[/URL] for this scriptexpireDate = new DateexpireDate.setMonth(expireDate.getMonth()+6)jcount = eval(cookieVal("jaafarCounter"))jcount++document.cookie = "jaafarCounter="+jcount+";expires=" + expireDate.toGMTString()function cookieVal(cookieName) {thisCookie = document.cookie.split("; ")for (i=0; i<thisCookie.length; i++){ if (cookieName == thisCookie[i].split("=")[0]){ Â return thisCookie[i].split("=")[1] }}return 0}function page_counter(){for (i=0;i<(7-jcount.toString().length);i++)document.write('<span class="counter">0</span>')for (y=0;y<(jcount.toString().length);y++)document.write('<span class="counter">'+jcount.toString().charAt(y)+'</span>')}</script><!--End of Counter-->Step 2: copy in your HTML beetween <body> and </body> where you want<!--Counter-->This website was visited <script>page_counter(jcount);</SCRIPT> times.<!--End of Counter-->PS:- it's just to see how it works...you can modify the text, the color...edit also the part 2- the counter you can find on the web are sometimes with publicity- try...we learn so !- you can find also other counters html on the web, but I prefer in PHP Quote Link to comment Share on other sites More sharing options...
Ken Cox Posted September 6, 2005 Report Share Posted September 6, 2005 Ron has his counter working and it worksken Quote Link to comment Share on other sites More sharing options...
Michel Posted September 6, 2005 Report Share Posted September 6, 2005 Ok, ...but with some counters, it's false . When we look at the tutorials and we go again home, the counter increase...as we update the index page.With a cookie, it's better... Quote Link to comment Share on other sites More sharing options...
d67 Posted September 6, 2005 Report Share Posted September 6, 2005 Now that I have a working Web Site, I would like to be able to determine the number of visits made to the site. How can I add a 'counter' to the site that will update each time someone calls?RonI use this site, Moostik, wich gives you a code to incorporate to your html page.You have the possibility to add invisible counters for your visitors to whatever page you want.Very very easy to use and customize... and it is free I use i t since a few years. Quote Link to comment Share on other sites More sharing options...
Ronniebootwest Posted September 6, 2005 Author Report Share Posted September 6, 2005 Michel,Yes I have noticed that the counter goes up whenever I go from page to page. This is not very good is it. I would like the counter to increas just when someone log on to the Web Site - do you have some code (html) that would achieve this?Not sure what you mean by 'cookies is best' please explain.d67,Thanks for the link, I will have a look at that this afternoon - will it meet my requirements though, i.e. just ipdate when someone logs on the the site?Ron Quote Link to comment Share on other sites More sharing options...
d67 Posted September 6, 2005 Report Share Posted September 6, 2005 d67,Thanks for the link, I will have a look at that this afternoon - will it meet my requirements though, i.e. just ipdate when someone logs on the the site?Ron The best is to try it. It's free,very easy to customize, invisible and easy to inplement in your html code !For a first approach it's a very interesting tool. 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.