Advertisement
Guest User

temp1

a guest
Aug 30th, 2015
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.37 KB | None | 0 0
  1. [12:17] <KeenScripter> Hey guys, how's it going?
  2. [12:17] <KeenScripter> I have a question.
  3. [12:17] <@robotmayo> sup
  4. [12:17] <@olivierrr> hi
  5. [12:18] <KeenScripter> Is it possible to have two html input-radio buttons, and when one or the other is selected, it will display a form (or the other form) on the webpage?
  6. [12:18] <KeenScripter> !m chippah
  7. [12:18] <ziggy-js> You're doing great work, chippah!
  8. [12:19] <@robotmayo> attach a click event to the radio buttons to change the forms when clicked
  9. [12:19] <KeenScripter> hmm
  10. [12:19] <KeenScripter> onClick?
  11. [12:19] <KeenScripter> I see
  12. [12:20] <KeenScripter> but how would I get the forms created, but not shown on the page, until a radio-button is pressed?
  13. [12:20] <@robotmayo> the simplest way is to use css classes to hide/show the forms and toggle the classes depending on what button was clicked
  14. [12:21] == Coldblackice [~Coldblack@unaffiliated/coldblackice] has joined #learnjavascript
  15. [12:21] <KeenScripter> So I should use html input-radio-buttons, to toggle CSS classes that hide/show html forms, that are linked to my javascript
  16. [12:22] <KeenScripter> ok, sounds good. Thanks @robotmayo!
  17. [12:23] <KeenScripter> I can of course do this all using internal CSS?
  18. [12:23] <KeenScripter> :)
  19. [12:24] <@robotmayo> probably can do it with pure css now that I think about it
  20. [12:24] <KeenScripter> ok
  21. [12:24] <KeenScripter> cool.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement