SemiOT: HTML/CGI question

I’ve been pursuing the webcounter idea a little.

(By the way: Warren – I saw your post and will
include you on this soon.)

The script is in Ruby, so that’s my justification
for posting here. :slight_smile: Even though I don’t show the
code here.

I realized finally that I’m used to the graphical
counter that I’ve been using for ages. The IMG
tag itself invokes the CGI:

So the result of the CGI is an image that gets
embedded in the HTML document.

But I can’t see any equivalent technique for simple
text.

I’m opposed generally to server-side stuff. Never
mind why, it just annoys me a little.

I suppose it might be possible with Javascript (and
probably is). Though I’d like a Javascript solution
as opposed to nothing at all, my first choice would
be a pure HTML solution.

Anyone?

Hal

Hal E. Fulton wrote:

But I can’t see any equivalent technique for simple
text.

The only way to do this is to make sure that all pages load through a
certain Ruby script (using e-ruby or something similar). You can do this
in several ways. You can use one simple script that does the counting
and then reads a page from local disk (based on a parameter) and sends
it to the browser. Or you can rename all .html to .rhtml and add the
code (a simple call to your counter object) at the top of every single
page.

Most statistics scripts just use Apache’s log files to generate the
statistics (once every day). Or use an image counter (which isn’t as
reliable).

You could use JavaScript to load the counter image dynamically (but not
really showing it). But then again, there are more browsers capable of
loading an image (which can be as small as 1x1 pixels) then there are
browsers capable of running JavaScript. And a text browser like Lynx
can’t do either.

Regards,

Peter

doesn’t take into account what page is begin counted - etc. but how bout
something similar to:

http://eli.fsl.noaa.gov/eg/ruby/counter/

uses frames (ack) but…

-a

···

On Sat, 10 May 2003, Hal E. Fulton wrote:

I’ve been pursuing the webcounter idea a little.

(By the way: Warren – I saw your post and will
include you on this soon.)

The script is in Ruby, so that’s my justification
for posting here. :slight_smile: Even though I don’t show the
code here.

I realized finally that I’m used to the graphical
counter that I’ve been using for ages. The IMG
tag itself invokes the CGI:

So the result of the CGI is an image that gets
embedded in the HTML document.

But I can’t see any equivalent technique for simple
text.

I’m opposed generally to server-side stuff. Never
mind why, it just annoys me a little.

I suppose it might be possible with Javascript (and
probably is). Though I’d like a Javascript solution
as opposed to nothing at all, my first choice would
be a pure HTML solution.

Anyone?

Ara Howard
NOAA Forecast Systems Laboratory
Information and Technology Services
Data Systems Group
R/FST 325 Broadway
Boulder, CO 80305-3328
Email: ara.t.howard@fsl.noaa.gov
Phone: 303-497-7238
Fax: 303-497-7259
====================================

this doesn’t seem to work on IE though - am i mistaken?

-a

···

On Sat, 10 May 2003, Aredridel wrote:

On Fri, 2003-05-09 at 12:41, Nospam wrote:

Hal E. Fulton wrote:

But I can’t see any equivalent technique for simple
text.

this doesn’t seem to work on IE though - am i mistaken?

Microsoft invented it!

Doesn’t work in Netscape <= 4, though.

err. that’s what i meant. actually, i mis-read your post and saw ‘’
which does not work in IE, since netscape invented it :wink:

frames (or inline frames ) are the most logical way to go - see my example in
earlier post

-a

···

On Sat, 10 May 2003, Aredridel wrote:

this doesn’t seem to work on IE though - am i mistaken?

Microsoft invented it!

Doesn’t work in Netscape <= 4, though.

Ara Howard
NOAA Forecast Systems Laboratory
Information and Technology Services
Data Systems Group
R/FST 325 Broadway
Boulder, CO 80305-3328
Email: ara.t.howard@fsl.noaa.gov
Phone: 303-497-7238
Fax: 303-497-7259
====================================

Saluton!

this doesn’t seem to work on IE though - am i mistaken?

Microsoft invented it!

That does not relate to the question >;-> Anyway: Some of the
browsers that are used ignore it. Chances are better with frames.

Gis,

Josef ‘Jupp’ Schugt

···


e-mails that do not contain plain text, are larger than 50 KiB, are
unsolicited, or contain binarys are ignored unless payment from your
side or technical reasons give rise to a non-standard treatment.