| |
| |
| |
|
Page: 1 2 3
Comments:
<[Torgo]> you have to manually remove the dom references <sk8ing> how? <ht311> set it to null <sk8ing> thanks, another two questions: can I specify a destructor? <sk8ing> so it will remove the references when t leaves the scope? <ht311> nope, i hope there is one <sk8ing> hmm <sk8ing> and the 2nd: how do I specify a reference, like THIS IS REFERENCE not a copy <sk8ing> ? <ht311> it is always a reference <[Torgo]> all non primitives are p***ed by reference <sk8ing> it is a primitive <sk8ing> at least I think so <[Torgo]> then it cannot be by ref <sk8ing> hmm <sk8ing> tx <sk8ing> no work-around for this? <[Torgo]> work around? you ask as though it's a bad thing <sk8ing> it is not a good thing <[Torgo]> why would you want a reference to an integer? <sk8ing> that's for sure <sk8ing> heh, consider this: <sk8ing> scrollTop <[Torgo]> an integer <sk8ing> for cross-browser compatibility you have to search for it in more places <sk8ing> now, if you want to set it <sk8ing> you have to search again <[Torgo]> what? <[Torgo]> whatever book you're reading, burn it <sk8ing> I'm not reading a book <[Torgo]> figure of speech <sk8ing> I think you don't follow <[Torgo]> not sure why i try to help you <sk8ing> it's a discussion, I'm not asking help right now <[Torgo]> but you clearly are in need of it <sk8ing> let's say you want to set the scroll to some value <sk8ing> are you following? <sk8ing> you want to scroll the page to some value <sk8ing> now, to do that, you'll have to look in document.documentElement <[Torgo]> wrong <sk8ing> in document.body <sk8ing> wrong? <[Torgo]> wrong <sk8ing> where do you have to look then? <[Torgo]> scrollTop is a member of the window cl*** <sk8ing> unfortunatly it isn't there most of the time <[Torgo]> you need to ***ert it <sk8ing> by the way, scrollTop doesn't appear as a property of the window element, not from what w3c is saying about it <[Torgo]> and yet, there it is <[Torgo]> what's your point? <sk8ing> the point is that a value may not reside in the same place <sk8ing> and a global reference will be really useful <[Torgo]> best pick a better example then <sk8ing> when you want to set it <sk8ing> well, you got the point <[Torgo]> you're talking about a cross-browser api <[Torgo]> setScrollTop <sk8ing> why execute a function every time you have to set something when you could just use the reference <[Torgo]> because there is no reference -- have you not been following? <sk8ing> that's the point, now do you see why it's not a good thing that it's missing? <[Torgo]> nope <sk8ing> k... <[Torgo]> you clearly need a better grasp of the js language if you cannot see why primitives need to p*** be value <sk8ing> why would they have to be p***ed by value? come on, and those references are not eaven real references <sk8ing> are pointers <sk8ing> since you can set them to null after you're done with them <[Torgo]> so you'd have 1+1 use references? <sk8ing> 1+1 is a constant <[Torgo]> 1 is a primitive <sk8ing> 1 is a constant. x = 1; x is a variable <[Torgo]> wrong <sk8ing> x is a primitive type <sk8ing> as in "defined inside the core" <[Torgo]> check typeof on both <sk8ing> they're both ints probably <sk8ing> but 1 is a constant <[Torgo]> wrong <ht311> there is no constant in js, primitive is primitive <sk8ing> so there's no difference between 1 and x? <sk8ing> where var x = 1; <sk8ing> ? <[Torgo]> nope <sk8ing> lol <sk8ing> than 1 = 3; should make sens <sk8ing> sense <[Torgo]> you can just lol yourself out the door <[Torgo]> getting a bit tired of this <sk8ing> well, I think I have a point <[Torgo]> nope <sk8ing> k <VaranG|aN> what is the code to create a new HTML image ? <VaranG|aN> the line of code <[Torgo]> document.appendChild(document.createElement("IMG").src = "foo.gif"); <VaranG|aN> thanks [Torgo] :) <[Torgo]> np <sk8ing> can I define custom operators for my objects? <[Torgo]> such as? <sk8ing> = <[Torgo]> to ***ign an object? <sk8ing> no, the = operator <[Torgo]> yes, the ***ignment operator <sk8ing> or any other <sk8ing> something like this <sk8ing> var x = new MyCl***(); x = 4; - and that would be evaluated to x = 4*2; let's say <sk8ing> x being some private member of MyCl*** <sk8ing> the second x <[Torgo]> nope <sk8ing> k, tx <sk8ing> question: how do I refer to a higher scoper var? function () { this.x = 1; function () { xspace } } <sk8ing> how do I refer to x from xspace? <sk8ing> *scope <[Torgo]> should already be in scope <sk8ing> I see, so x = 3; should be ok? <[Torgo]> try <sk8ing> I've been forced several times to use this.x; <sk8ing> but I'm in a lower scope and this.x will refer to that scope <Ruy> hello <Ruy> if I have a HTML code, with 4 select object with the same name "country", how can I know by javascript, what select object have a ONCHANGE event ???? <Tarantino> how do you write " signs to html text with document.write? <Tarantino> ahh- single quotes:-P <freed> Hi, am wondering if anyone can point me in the right direction with a link or some info. Am wanting to have the bullets in my html <ul><li> list be visiable upon mouseOver. <sk8ing> css <sk8ing> look for display property <furtive> it's not display <sk8ing> oh, he doesn't want the whole list to be shown <sk8ing> sorry, I haven't understood the question <freed> hmmm, maybe i could use li:hover or something <furtive> just the bullets, or the whole list? <sk8ing> list-style I guess <freed> the bullets <furtive> liRef.style.listStyleImage = "??? <furtive> " <freed> so you mouse over and one shows up for the item you moused over, by default you see no bullets <furtive> or .listStyleType = "???" <furtive> yeah, can probably do it with li:hover <freed> i dunno, ill read up on thoes though <freed> hmmm ok <furtive> check that IE supports it too <freed> k, thanx <sk8ing> no <sk8ing> it doesn't <sk8ing> ie supports :hover only for anchors <furtive> so you'll have to onmouesover it <freed> li:hover{display: inline;} to show it, and display: block to hide it works <freed> ie...what a pain <sk8ing> lol <sk8ing> no man <sk8ing> display: block; shows it <sk8ing> but as a block element <sk8ing> you need display: none; <sk8ing> that's what I thought first time I saw it too :P that it blocks the displaying :D
Return to
#javascript or Go to some related
logs:
+Knoppix +install gmake #linux phillipiano sex
#windows #MissKitten #linuxhelp mysql console into outfile csv #windows lofl lis ppc instruction
|
|