Ironworks Gaming Forum

Ironworks Gaming Forum (http://www.ironworksforum.com/forum/index.php)
-   General Conversation Archives (11/2000 - 01/2005) (http://www.ironworksforum.com/forum/forumdisplay.php?f=28)
-   -   Need Help With JavaScripting (http://www.ironworksforum.com/forum/showthread.php?t=87642)

Dundee Slaytern 09-09-2003 03:19 AM

Maintaining a website for the Army, but came across a few hurdles regarding JavaScripting. I need to find out how to do the following, and while Google came up with a gazillion links, all of them have failed to address my issue because either,

1) Their f!@#$ing code is wrong and does not work.
2) They require me to BUY their code.

Can you tell I am starting to stress out a little here? [img]tongue.gif[/img]

--------

This is the scenerio.

I have a table.

<table align="center", border="1", cellspacing="0", cellpadding="0", width="100"><tr bgcolor="#FF0000"><td width="75">Title /\</td></tr></table>

What I want is... when I click on the <span style="color: #FFFFFF">Title /\ button, I get the following,

<table align="center", border="1", cellspacing="0", cellpadding="0", width="100"><tr bgcolor="#FF0000"><td width="75">Title \/</td></tr><tr><td>Link 01</td></tr><tr><td>Link 02</td></tr><tr><td>Link 03</td></tr><tr><td>Link 04</td></tr></table>

And when I click on the button again, the list of links goes back into hiding. Basically it is an expanding/contracting table.

--------

The second problem facing me is a Hit Counter. Since the Army website is on its' own personal intranet, the usual Hit Counters on the internet do not work. I need to make my own. Does anybody know where on the internet can I learn how to do this?

I would preferably like to learn how to get hits based on IP addresses, but Hit Counters based on pageviews are fine with me too.

Faceman 09-09-2003 04:43 AM

I remember a script that does exactly what you need from my old scripting HTML days. I'll try to find it.
Meanwhile www.webmonkey.com has always been my no.1 resource for scripting and HTML and I've never been disappointed by them.

ADD] Found that script from back then. Howeverthe site has grown and is not free anymore. Sorry :(

[ 09-09-2003, 04:55 AM: Message edited by: Faceman ]

Vaskez 09-09-2003 05:38 AM

I don't know how to do expanding tables but hit counter are easy....except not with Java Script :( The problem is that java script runs on the client side i.e. it is run by the client's browser. To make a hit counter you need to use server side scripting: i.e. either ASP, JSP or PHP. This is because to store the counter value, you need access to the server's hard-disk and giving access to clients to the server's hard disk is obiously insecure and not allowed! If you use ASP for example, making a counter is as simple as detecting a connection (there are pre-defined functions for this) and then reading a number from a text file, incrementing it and writing back to disk. Look at www.w3schools.com - it tells exactly how to do what you're after in ASP.


All times are GMT -4. The time now is 04:27 AM.

Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
©2024 Ironworks Gaming & ©2024 The Great Escape Studios TM - All Rights Reserved