• All Purchases made this month instantly go into the draw to win a USD $ 100.00 credit to your HoP account.
 

ber seal


The Official London juggling ber spy. shh! dont tell any one
Location: the world (London)

Total posts: 419
Posted:I'm trying to set up a web site at the mo biggrin

and I had an ubbidea for the log book http://twistedjuggler.tripod.com/aboutme/index.html.dates
br>
what I want to do is turn all the dates in to onclick buttons.
and have text come up in the textarea next to it.

but beacuse I only found out what java was a week ago, I have no idea how to do this. confused

if any of you geeks out there in geekdom kown how I can do this, know of a web site where I can find out or could just do it for me.
I will ubblove you for a very long time.


When people says "plz" cause its shorter than "please" I say "no" cause its shorter than "yes"

Delete Topic

mcp
PLATINUM Member since May 2003

mcp

Flying Water Muppet
Location: Edin-borrow.

Total posts: 5276
Posted:Sounds like you want to be using forms:



look here for a tutorial:



w3c school



Or google for XHTML (and or forms) to come up with more.



The thing is, webpages were never designed to be interactive, (and still aren't) So if you do put a form in your webpage, it will 'POST' its inputed data (like: I was clicked!) back to a server, where the server will decide what to do: like update the webpage. The client won't really do any processing at all.



This is a bit superpowered and hardcore for what you want to do. Instead I suggest client side includes and javascript ( mad2 ) Bear in mind: javascript has ABSOLUTELY NO RELATION TO JAVA. They are not the same thing, decended from the same thing, or indeed similar.



There are plenty of javascript sites out there, check google or try:



javascript1



javascript2



ubbloco


"the now legendary" - Kaskade
"the still legendary" - Kaskade

I spunked in my friend's aquarium and the fish ate it. I love all fish. Especially the pink ones. They are my bitches. - Anon.

Delete

ber seal


The Official London juggling ber spy. shh! dont tell any one
Location: the world (London)

Total posts: 419
Posted:thanks mpc. I did mean javascript, as aposed to java.

I'll give them a look over.

or i'll just throw the comp out of the house.

one way I'll sort out the problem


When people says "plz" cause its shorter than "please" I say "no" cause its shorter than "yes"

Delete

borismcnorris


borismcnorris

professional pedant
Location: Bristol

Total posts: 137
Posted:I think all you need to do is put 'onClick="the_text.value='your text here';"

I think... It's been a while since i coded any web stuff but it should just be a case of getting the name of your text area (the_text i think from looking at your source) and setting it's value. You shouldn't need any POST or GET or any of that form stuff.

hope this helps peace


A warrior always returns to the fray. He never does so out of stubbornness, but because he has noticed a change in the weather - Paulo Coelho

Delete

Durbs
BRONZE Member since Sep 2001

Durbs

Classically British
Location: Epsom, Surrey, England

Total posts: 5688
Posted:Ooooh, pardon my thickness - but what IS the difference between Java (as in applets?) and Javascript?

Burner of Toast
Spinner of poi
Slacker of enormous magnitude

Delete

musashii


musashii

starring Skippy the green llama
Location: Seattle, WA

Total posts: 1148
Posted:Java is compiled, not always into an executable, but into byte code

First intention, then enlightenment..
Ars Pyronomica

" Life is programmed. Whether death is programmed or not is yet to be determined."

Delete

mcp
PLATINUM Member since May 2003

mcp

Flying Water Muppet
Location: Edin-borrow.

Total posts: 5276
Posted:Java is java, javascript is a scripting language that came out a little after java and attempted to steal some of it's popularity by nicking it's name. Sometimes javascripts is also refered to as SCMAScript or somesuch, which as you can tell sounds nothing like java. Plus they aren't even made by the same people.

"the now legendary" - Kaskade
"the still legendary" - Kaskade

I spunked in my friend's aquarium and the fish ate it. I love all fish. Especially the pink ones. They are my bitches. - Anon.

Delete

borismcnorris


borismcnorris

professional pedant
Location: Bristol

Total posts: 137
Posted:Java is a proper programming language (like C) for writing proper applications or applets (little applications that run in a web-browser).

Javascript is like mini-java and is used for writing little bits of interactivity into web pages. It can also be used to make kick-ass pages like www.htmlguru.com without the need for flash or anything like that

Hope that makes things clearer. I think i've just confused myself confused ubbloco


A warrior always returns to the fray. He never does so out of stubbornness, but because he has noticed a change in the weather - Paulo Coelho

Delete

flid
BRONZE Member since Aug 2002

flid

Carpal \'Tunnel
Location: Warwickshire

Total posts: 3136
Posted:Javascript has no relationship to Java, completely seperate languages, one of which ripped the name off the other because they thought it'd sound cool

Delete

borismcnorris


borismcnorris

professional pedant
Location: Bristol

Total posts: 137
Posted:They're actually very similar in the way you write the code. Same format for method declarations, variable declarations and loops. And the way you access the DOM in javascript is almost identical to the Class structure of java. They may have been developed by different people but it is called Javascript for a reason

/geek


A warrior always returns to the fray. He never does so out of stubbornness, but because he has noticed a change in the weather - Paulo Coelho

Delete

mcp
PLATINUM Member since May 2003

mcp

Flying Water Muppet
Location: Edin-borrow.

Total posts: 5276
Posted:That reason is to rip off Java. Java isn't called C++++ (Or ++++C) (Or D) (Or even E).

Javascript is a blatant trademark infringement if you ask me.


"the now legendary" - Kaskade
"the still legendary" - Kaskade

I spunked in my friend's aquarium and the fish ate it. I love all fish. Especially the pink ones. They are my bitches. - Anon.

Delete

borismcnorris


borismcnorris

professional pedant
Location: Bristol

Total posts: 137
Posted:tongueuts on pedant hat:

Written by:
Netscape and Sun jointly announced the new language on December 4, 1995, calling it a "complement" to both HTML and Java.




from http://www.oreillynet.com/pub/a/javascript/2001/04/06/js_history.html
br>
/pedant
more ubblove less confused
cool weavesmiley


A warrior always returns to the fray. He never does so out of stubbornness, but because he has noticed a change in the weather - Paulo Coelho

Delete

Gidg
BRONZE Member since Apr 2003

Gidg

Super Gidg!!!!
Location: Portland Oregon USA

Total posts: 8506
Posted:offtopic
I love coffee, I love tea,
I love the Java Jive and it loves me
Coffee and tea and the java and me,
A cup, a cup, a cup, a cup, a cup!

I love java sweet and hot,
Whoops, Mister Moto, I'm a coffee pot
Shoot me the pot, and I'll pour me a shot,
A cup, a cup, a cup, a cup, a cup!


Growing old is mandatory; growing up is NOT.
Proud member of the HoP DPS.
Sanity is a highly overrated state of mind.
I'm normal ... it's everyone else that's crazy.

Gidg

Delete

ber seal


The Official London juggling ber spy. shh! dont tell any one
Location: the world (London)

Total posts: 419
Posted:my head hurts.

I see why people get payed to do all of this now.


When people says "plz" cause its shorter than "please" I say "no" cause its shorter than "yes"

Delete

musashii


musashii

starring Skippy the green llama
Location: Seattle, WA

Total posts: 1148
Posted:to answer your original question tho

<script>
//declare date text array
arDateText = new Array(x); //replace x with the number of dates
//initialize the array of date text that you want to appear
arDateText[0] = "This will appear when Date 1 is clicked";
arDateText[1] = "This will appear when Date 2 is clicked";
//repeat as many times as necessary
function displayText(ID)
{
dateDiv.innerText = arDateText[ID];
}
</script>

then setup your dates as such

<a href="#" onClick="displayText(0);">Date 1</a>
<a href="#" onClick="displayText(1);">Date 2</a>

for the area you want to display the text, it doesn't have to be a textarea, use a div instead. I've added a style to it so that the height and width remain the same, scroll if the text is longer
than the alloted height.

<div id="dateDiv" style="width: 200px; height: 350px; overflow: auto;"></div>


First intention, then enlightenment..
Ars Pyronomica

" Life is programmed. Whether death is programmed or not is yet to be determined."

Delete

ber seal


The Official London juggling ber spy. shh! dont tell any one
Location: the world (London)

Total posts: 419
Posted:thanks for the help in hurting my head more.

think I should leave this one for now.

will work on it again some time.

ubbloco


When people says "plz" cause its shorter than "please" I say "no" cause its shorter than "yes"

Delete

musashii


musashii

starring Skippy the green llama
Location: Seattle, WA

Total posts: 1148
Posted:biggrin

confused I thought I made it pretty easy tho, ah well


First intention, then enlightenment..
Ars Pyronomica

" Life is programmed. Whether death is programmed or not is yet to be determined."

Delete


Similar Topics

Using the keywords [java] we found the following similar topics.
1. Forums > Juggling Java simulator [1 reply]
2. Forums > help me with java [16 replies]
3. Forums > Java Styles
4. Forums > unable to create record instance ... [2 replies]
5. Forums > lightSequencer [5 replies]

     Show more..