@# Quotes DB     useful, funny, interesting





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



Comments:

<0> but I want to call 'onchange', I want it to run wahtever is in 'onchange'
<0> think of it as a general thing
<0> I have multiple selects and this does it for all of them
<0> I tried **** like eval(document.getElementById('myid').onchange)
<0> it gives me this:
<1> endra: I see...... huh.... have you tried yet using the .selected property on an option instead?
<2> select.onchange();
<1> changing .selected may do it
<0> when I do:
<0> alert(document.getElementById(elemid).onchange);
<0> I get:
<0> function anonymous() { genderSelected(this.options[this.selectedIndex].value) }
<0> the genderSelected line is IN my onchange
<2> so call that function
<0> I dont know why it put function anonymous
<0> which function, anonymous?



<2> because you made an anonymous function
<3> if I focus the element before it's appended I don't get the error, but it doesn't focus
<0> I didnt make anonymous
<2> you did
<0> I made genderSelected
<0> how? lol
<0> its not in my code
<0> its only when I do alert(foo.onchange)
<2> what you gave as the value of the onchange attribute became the body of a function
<0> precisely!
<2> and that's the function you're seeing, and the function that gets called
<0> so how can I call it?
<0> eval(document.getElementById(elemid).onchange()) ?
<2> select.onchange();
<2> yes
<2> no eval
<2> it is a function
<0> oh, sec
<1> ..
<1> mutalisk_h: I think I know the issue, one sec, there may be 2 objects, the var and the appended node, not necessarily hte same
<3> so how do you focus on an input element that your appending to the dom?
<0> it not working
<0> lol
<1> meaning, appending the var content, doens't automatically makes it a pointer
<2> mutalisk_h: you can't set focus to something that isn't rendered
<2> so add it first, then focus
<0> document.getElementById(elemid).selectedIndex = elemindex;
<0> document.getElementById(elemid).onchange();
<0> that is what I did
<1> mutalisk_h: try -> crackhead=td_1.appendChild(input_1); crackhead.focus()
<3> Delta: when I add it and then focus I get that error
<0> is that what you meant, deltab?
<1> mutalisk_h: checking the refs, the method returns the node being appended, but the variable, remains oblivious of the node appended
<2> mutalisk_h: oh, that might be a bug in Mozilla
<0> whoa
<0> it worked
<0> thanks man
<0> my browser wasn't reloading js
<0> I had to clear cache
<0> frigg I wonder what else was working that it showed wasn't :-/
<3> CommandPrompt and deltab: http://pastebin.com/717582, look at like 39
<4> The paste 717582 has been moved to http://erxz.com/pb/1608
<3> I tried it this way, foo = td_1.appendChild(input_1); foo.focus();
<3> CommandPrompt and deltab: I just changed the code and moved foo.focus() below ingredient_table_body.appendChild(tr);
<3> I'm still getting the Exception error
<1> ..
<2> mutalisk_h: you shouldn't even have a XULElement though
<2> I suspect it's a Mozilla bug
<2> maybe try navigating to it rather than using the stored reference
<0> how can I check if an element exists?
<1> endra: if (obj)
<0> sorry
<0> element by id exist
<0> without crashing js :-/
<5> getElementById returns a true value (the element object) if it exists and a false value (null, usually) if it doesn't.
<0> okay
<0> well
<0> thats what I based my code upon but when IE hits the line
<0> let me just double check
<0> sec
<3> CommandPrompt and deltab: looks like it's a bug with firefox, http://forums.mozillazine.org/viewtopic.php?t=313755&;



<3> Can't seem to find a work around
<3> doesn't seem to work in IE
<6> Is there any set of javascript "libraries" or common code that masks some of the easier differences between IE/Firefox/Etc?
<7> is there a way to tie a String object to an HTMLElement in such a way that re***igning the string updates the contents of the HTMLElement?
<7> i find the differences between javascript objects and DOM objects highly undefined and confusing...
<2> kismet_: you can create an object and use its wach method
<2> watch
<8> what is the difference between 'resume' and 'skip' ?
<8> when uploading via ftp
<8> you know I should ask in #freenode-social
<2> I guess resume will continue an interrupted upload and skip won't
<8> hrm
<8> well it's a prompt I get when uploading a file already on the server
<8> override, resume, and skip
<2> it doesn't know whether a previous upload was interrupted
<7> i've found a watch() method of Netscape v4, but nothing modern
<2> and more recent browsers aren't allowed to implement that?
<7> according to my sources, it's not implemented in IE or Mozilla
<2> works for me in Firefox
<9> can i ask a dumb js question?
<9> :|
<8> yes
<10> wuf: go for it
<9> ok, here goes
<10> wuf: I'll go first - "What's the J in JavaScript represent ?"
<9> if i'm using:
<9> function new_window(url) {
<9> link = window.open(url,"Link","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=550,height=560,");
<9> }
<8> ack
<8> :/
<8> paste code in a pastebin
<8> !paste
<9> can i tell it where on screen to open the new window
<8> `paste
<11> paste: Paste links, not code ( http://pastebin.bafserv.com/ , http://sial.org/pbot/ , http://tnx.nl/scribble.plp , http://www.coldfugitive.com/paste/ )
<9> did you understand the question?
<8> yes
<8> I believe it is possible to do that
<8> I'd have to look it up
<0> try window.top and window.left
<0> not 100% it'll work.. but usually properties .top and .left designate where to put a form
<9> still having issues...
<9> oh well....
<12> heyas
<12> I have an list in li that is navigatable via keyboard and mouse and I want an event tied to a click of a mouse or enter button. I'm trying <li onclick="javascript:func()" onkeypress="javascript:func()">something</li>
<12> hitting the enter key doesn't respond by performing the action?
<12> why is that?
<1> well
<1> Lis are read-only and wouldn't have keypress event
<12> ahh
<1> not that the user will have a chance either
<12> Could I emulate the behavior through setting an event handler for onkeypress?
<13> i am trying to get an rss feed through ajax from a third party website
<13> but the browser gives a security warning
<13> how to get rid of that
<14> To access a textbox field from outside an iframe, would you do window.frames.iframe.formname.textboxname.value = 'value'; ?
<15> question...what does it mean when you have something like this: var x: { p1: something, p2: somethingElse }; ?
<15> oops - I typed that wrong it should be var x = { p1: something, p2: somethingElse };
<5> It's an Object literal
<5> {} is a new Object()
<5> like [] is a new Array()
<15> hm
<15> ok
<15> thank you for that - I haven't seen it before
<16> requestion
<16> how do I writed javascripts??
<15> Ponijs, that's a pretty open-ended question.
<16> is it
<17> lol
<16> someone who hasn't seen literal notation
<16> there should be a link for them
<1> <5> {} is a new Object()
<1> Ponijs: ^


Name:

Comments:

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






Return to #javascript
or
Go to some related logs:

mount -t cifs username c drive
#css
#python
freefontpath in gentoo
smoke image sequnce
#web
downgrade nvidia driver ubuntu
#sdl
#linux
configured mouse cannot open device xorg vmware



Home  |  disclaimer  |  contact  |  submit quotes