dynamic image counters

Results 1 to 7 of 7

Thread: dynamic image counters

  1. #1
    fl1rt Guest

    Default dynamic image counters

    okay, you&#039ve seen them before..those cute little counters that render how many visitors have been to your site, as a single image.<BR><BR>one minute it could read:-<BR><BR>00102 then the next minute, 00103<BR><BR>now rather than render all those frames by hand in photoshop..<BR>: )<BR>is it possible to render this is in pure asp???<BR>...no componants in other words!<BR><BR>any reference on where to search would be a start at least...<BR><BR>fl1rt

  2. #2
    fl1rt Guest

    Default RE: double posting

    I&#039m surprised that Mr.Deans Message Board script doesn&#039t check for double posting...<BR><BR>naughty, naughty

  3. #3
    Ryan S. Guest

    Default RE: dynamic image counters


  4. #4
    fl1rt Guest

    Default RE: dynamic image counters

    hmmm...not quite what I had in mind.<BR><BR>nice fast dynamic reply but the enquiry was for a dynamic IMAGE counter not text. Text is easy to format bia global.asa and the filesystemobject.<BR><BR>the result of an enquiry to the ASP counter script should return a dynamically generated and UNIQUE graphic image with numbers (probably masked) onto an existing template background.<BR><BR>cheers<BR>fl1rt

  5. #5
    Ben Jones Guest

    Default RE: dynamic image counters

    I don&#039t think that you would want to create the images on the fly because of the performance hit to the server. What you could do is take a mono-spaced font and create equally-sized gifs numbered 1 through 10. To then display the images in ASP, you would have code something like the following:<BR><BR>Total page views: <BR>&#060;%<BR>&#039 assume "hits" is your variable<BR>for x = 1 to len(hits)<BR> if isNumeric(mid(hits, x, 1)) = TRUE then<BR> response.write "&#060;img src=""/images/" & mid(hits, x, 1) & ".gif"" width=""8"" height=""8"" alt=""""&#062;"<BR> elseif mid(hits, x, 1) = ":" then<BR> response.write "&#060;img src=""/images/colon.gif"" width=""8"" height=""8"" alt=""""&#062;"<BR> end if<BR>next<BR>%&#062;<BR><BR>note that I&#039m assuming a few things here ...<BR>1. image height and width<BR>2. all of your graphics will be in a directory named "images" which is located in the root of the wwwroot directory<BR>3. you&#039ll have to create a graphic of a colon too ":"<BR><BR>Alternatively you could use a program like Generator (macromedia).

  6. #6
    Ben Jones Guest

    Default RE: dynamic image counters

    one correction ... the images should be 0 - 9, not 1 - 10.<BR><BR>

  7. #7
    fl1rt Guest

    Default RE: dynamic image counters

    I&#039ve already done the code for generating mutiple pre-rendered (digit) images on my own server - thats easy to serve locally. The real problem is that I want to serve the dynamic counter to another web host from mine!<BR>So, if you have a non ASP site, you can install a simple javascript source with ref ID and that calls my ASP counter script and returns a dynamic image, rendered on the fly.<BR><BR>(I&#039ll be buggered if I&#039m going to sit down and render by hand in photoshop your image count of 4,203,00 if you&#039re that popular! hence the need for a dynamic solution)<BR><BR>ah! I hear you say - now that&#039s an entirely different problem...<BR><BR>I would also like to serve it as a direct one off hit.<BR><BR>You can use the example that you mentioned and loop round in javascript to serve multiple images from another host, but that&#039s a bit of a bodge that I&#039d like to avoid.<BR><BR><BR>fl1rt<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts