@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4



Comments:

<0> http://www.neofuture.co.uk/media/index.php?filename=audio2.mp3
<1> I am trying to make a menu that changes the background color of the item clicked to blue while the rest remain white.
<1> My link for a menu item is: <a href="javascript:newsCat(\'tech\');" onClick="changeBkgrnd(this)" id="3"><b>Tech</b></a>
<1> that is the 3rd menu item , hence id="3"
<1> the function changeBkgrnd(thisitem) has a for loop for each menu item and a IF ELSE statement in it
<1> what condition would be in the IF (condidtion) statement?
<2> hmm, that <a> look horrible
<1> well it calls two functions
<1> I am working on the onClick one to change the background color
<1> any ideas on how to write the function?
<2> you can simply call changeBkgrnd in newsCat
<1> but I need to reset all the others back to white
<1> that is the problem
<1> I am having difficulty writing the changeBkgrnd function, can you help?
<2> i try to tell how to call 2 function first.
<1> ok



<2> usually, you don't need to loop, just check track what one is clicked last time, and swap back the bg
<1> ht312 how would I do that though?
<2> var _global_last_activeClicked =null; everytime you call newsCat, check if _global_last_activeClicked is null, if not, do something, then set _global_last_activeClicked to the current item
<1> woah, I am a JS noob
<1> so I am still learning
<1> I am coming from PHP
<2> js is just like other programming language, how to do stuff effectivily
<1> yes I am realizing that
<2> the proper term will be you are an ui/event driven programming noob. ;)
<1> yes
<1> thanks
<1> http://www.gabbr.com/beta/index.php can you take a look at my code?
<1> the News to Gabb menu is what I am trying to fix
<1> if someone clicks "popular" I want that menu background to change to blue
<1> I have partially written the function in the <script>
<1> I just cant get the if(condition) right
<0> i hate uploding large files ffs
<3> Delistick, the easiest way will be id your link with "newslink_blah", when changeBg can call document.getElementbyId("newslink_" + somevar) .....
<3> plus the global var thing i mention in the top, it will work
<1> ok will try it
<1> trying it..
<1> ht311, like this? http://www.phpriot.com/2678
<3> http://www.html-channel.com/pastebin.php?id=3
<4> Hey folks...I have a table with two columns. The rightmost column contains an iframe which loads pages selected from the leftmost column (id=sidebar). I want the row height to resize itself on each load (so there is only a scrollbar for the page, not the iframe).
<4> The following script works in Firefox, but not IE. Any ideas why? <body id="bcontents" onLoad="parent.document.getElementById('sidebar').height=document.body.scrollHeight;">
<0> scrollHeight ?
<0> (just a guess)
<1> how do you changed the background color of a <a href="javascript:newsCat(this)" id="1"> ?
<1> in the function newsCat()?
<0> document.getElementById("1").style.backgroundColor="red";
<1> Neo, thanks
<1> damn that doesnt work either
<1> here is my function that I am trying to make to change the bkground color of the clicked menu item to blue
<1>
<1> http://www.phpriot.com/2679
<1> can someone help me with this function?
<3> hi fb
<5> going nuts here, table_reference.appendChild(tr_reference); < works fine in fx - ie needs table_reference.childNodes[0].appendChild(tr_reference); to work
<5> best way to deal with it?
<5> ofcourse it doesnt work the otherway around in fx
<3> the later way shoudl work in both
<3> ever heard of tbody?
<3> i am suprise that ff there is no tbody in FF
<3> hmm, is time to take my pills
<5> hmm
<5> you're saying.. .. ?
<5> should i reference the tbody instead?
<5> and yeah i heard of it, but i seldom use it ;)
<5> when i add a tbody
<5> it works in ie (again) but not in firefox..
<5> but, if i change the index, to 1 it works in firefox but not ie :)
<3> the different of white space handling
<3> in ff , it could be a text node at 0
<5> so whats a good solution? reference the tbody?
<5> yay, that worked
<5> thanks
<3> mytable.getElementsByTagName("tbody").item(0);
<3> http://developer.mozilla.org/en/docs/Traversing_an_HTML_table_with_JavaScript_and_DOM_Interfaces
<5> cool, thanks
<5> awesome url ;)



<6> *BOOM*
<7>
<8> heh
<3> fb: the IT Crowd is fine
<3> quite funny even are common IT joke
<8> ok
<8> dl'ing
<9> dling what
<9> ah, that show
<8> ya.
<8> only found 2ep.
<3> there is only 2 ep
<3> 3rd is coming out
<0> oooh it crowd ep3 out yet ?
<0> yeah friday
<0> might be on ch4 site tho
<3> yup, on ch4 site
<3> but there is no Jack Bauer there (yet)
<8> hehe
<0> starst this week in the UK on skyOne
<0> mms://edge.channel4.com/theitcrowd/episode3.wmv
<0> a**** the link dont work
<0> http://www.neofuture.co.uk/media/index.php?filename=audio2.mp3
<0> this is somat else i do
<0> Music
<10>
<0> yeah yeah yeah im using a marquee so what
<3> you really using one? omg
<3> what kind of feature is that? you seem to have a lot of time on hand :D
<0> yeah i was lazy putting that media player together, come on it only took me 2 hours to do it all
<0> like my %age bar lol
<3> there is no seek function with that, not l337 enough ;)
<0> i couldnt work out how to do a "you clicked on % of the table"
<0> if i could i could do it
<3> i think you could ....
<0> show me how then (demo time)
<0> Jack Bauer can get MacDonalds breakfast after 10:30
<9> lol
<3> currentPosition , take a value with second, you cna get total time and compute the second by where it clicked
<3> i think you can actually display just the seek bar of the media player
<3> Jack Bauer removed the "Escape" button from his keyboard. Jack Bauer never needs to escape.
<3> bored
<0> nah you cant show just the seek bar
<0> tools or nuffin
<0> [02:40] <3> currentPosition , take a value with second, you cna get total time and compute the second by where it clicked
<0> huh
<0> i done the bar calc i need to know wht % in a table been clicked to calculte it back to current pos
<0> "you clicked at 77% of the table"
<3> that is your problem, not the media player
<0> yeah
<3> and you should know how to get it :D
<0> currentPosition is writable
<0> i been up for 4 days straight im brain fried
<0> im not good with clicky working stuff out stuff
<3> go sleep, you are nuts, and spend 2 hours on this toy instead of watching 24 or sleep
<0> sleep is for the weak
<3> event.offsetX , clientX .... should work, since you start from 0 anyway, can cheat on calculation
<0> awe you made me code it
<3> nope
<3> you know that you going to do it when you start asking that :D
<3> I want to stay home tomorrow.. getting cold agian
<9> we can hang out all day, talk, do our hair
<0> done
<0> http://www.neofuture.co.uk/media/index.php?filename=audio2.mp3 <<===--- working seek bar to amake me more 1773 in ht`s book
<0> 1773 lol
<0> i dont wana be 1337 1773 is a bigger number


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #javascript
or
Go to some related logs:

tutacamen
#java
#linuxhelp
psybnc arhive for free bsd
local root xploit for fedora core 4
mutilated dicks
#php
#php
heidi clum
#skype



Home  |  disclaimer  |  contact  |  submit quotes