Go Back   Winamp Forums > Community Center > General Discussions

Reply
Thread Tools Search this Thread Display Modes
Old 15th June 2004, 22:36   #1
Joel
Debian user
(Forum King)
 
Joel's Avatar
 
Join Date: Jan 2003
Location: Arch land
Posts: 4,898
Some JavaScript with CSS push, please

I having problems with this escenario....

1.- What is WTF?
<radiobutton1>A) Don't know.
<radiobutton2>B) Not yet.

of course, radiobuttonx is the real radio button by <form>.

now, I need to change the text color of the "A)" if the user selects "B)", otherwise "A)" will be changed....

Any ideas?

Thanks


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux w/ xfce4.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Debian unstable w/ xfce4.
Joel is offline   Reply With Quote
Old 16th June 2004, 01:06   #2
griffinn
Court Jester
(Forum King)
 
griffinn's Avatar
 
Join Date: May 2000
Location: Your local toystore
Posts: 3,502
Send a message via ICQ to griffinn
Did this sort of stuff with an online survey a few weeks ago, so I'll just customise it a bit:
code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<title>Survey</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<meta name="description" content="Survey" />
<style type="text/css"><!--
--></style>
<script language="JavaScript" type="text/javascript"><!--
function toggle(me,target) {
if (document.getElementById) {
document.getElementById(me).style.color="red";
document.getElementById(target).style.color="green";
}
}
// --></script>
</head>
<body>
<h1>Who is a terrorist?</h1>
<form id="frm" name="frm" action="" method="get"
onsubmit="return false;">
<input type="radio" name="rdo"
onclick="toggle('rdo1','rdo2');" /><span id="rdo1">Bin Laden</span>
<input type="radio" name="rdo"
onclick="toggle('rdo2','rdo1');" /><span id="rdo2">Bush</span>
</form>
</body>
</html>


The smiley slot machine! | Quotable Blog
griffinn is offline   Reply With Quote
Old 16th June 2004, 14:00   #3
Joel
Debian user
(Forum King)
 
Joel's Avatar
 
Join Date: Jan 2003
Location: Arch land
Posts: 4,898
Thanks griffinn

That did the trick


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux w/ xfce4.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Debian unstable w/ xfce4.
Joel is offline   Reply With Quote
Old 16th June 2004, 20:18   #4
eleet-2k2
Forum King
 
eleet-2k2's Avatar
 
Join Date: Aug 2001
Location: Mobil Ave.
Posts: 5,381
And to answer you're first question, I'll refer you to bash.org

Quote:
#6460
<studdud> what the fuck is wtf

"Welcome to the Island of people who know too much."..."Did you really think balloons would stop him?!"
See what I'm listening too.
eleet-2k2 is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Community Center > General Discussions

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump