26-06-06, 12:28 | # 1 |
חבר על
|
תיבות INPUT ו JS
שלום,
רציתי לדעת איך אפשר לעשות משהו כזה בערך: יש 2 RAIDO BOTTOM ויש מתחתיהם 2 INPUT BOTTOM אם לוחצים על הכפתור רדיו הראשון הוא חוסם את הINPUT השני ואם לוחצים על הכפתור רדיו השני הוא חוסם את הINPUT הראשון... חוסם: לא מאפשר כתיבה בתוכו.. תודה |
26-06-06, 20:41 | # 2 | |
חבר חדש
|
ציטוט:
HTML קוד:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-8-i" /> <title>Untitled Document</title> <script type="text/javascript"> function disableInput(x) { if(x==1) { document.getElementById("input2").disabled=true; document.getElementById("input1").disabled=false; } else { document.getElementById("input1").disabled=true; document.getElementById("input2").disabled=false; } } </script> </head> <body> <form id="bla" method="post" action=""> <div><input type="radio" name="rButton" value="1" onclick="disableInput(1);" /> 1</div> <div><input type="radio" name="rButton" value="2" onclick="disableInput(2);" /> 2</div> <div><input type="text" id="input1" name="1" /></div><div><input type="text" id="input2" name="2" /></div> </form> <p> <a href="http://validator.w3.org/check?uri=referer"><img src="http://www.w3.org/Icons/valid-xhtml10" alt="Valid XHTML 1.0 Strict" height="31" width="88" /></a> </p> </body> </html> |
|
27-06-06, 06:25 | # 3 |
Permanently Banned
|
אתה יכול להשתמש בפונקציה IF
|
27-06-06, 13:37 | # 4 | |
חבר על
|
ציטוט:
אפשר שכאשר תיבה מסויימת נחסמת אז הרקע שלה הופך לאפור? תודה |
|
27-06-06, 13:53 | # 5 |
תודה על תרומתך.
|
עקרונית כן ב FIREFOX זה הופך לאפור ב IE פשוט אי אפשר ללחוץ עליו.
|
חברים פעילים הצופים באשכול זה: 1 (0 חברים ו- 1 אורחים) | |
|
|