| |
| |
| |
|
Page: 1 2
Comments:
<0> I am trying to change an image. It works fine in IE, but in firefox the image won't change <1> uninstall firefox then <1> hehehe <0> blasphemy <0> I'm using this line document.getElementById("image").src=document.getElementById("filename_"+pos).innerText; <2> innerText doesn't work in moz, it's IE only <3> [Torgo], the site still have caching issue, after a post , when it go back to the home page, it didn't see the updated forum posts <4> very likely <4> in order to fix the image flickering in the example pages i needed to enforce caching everywhere <3> i trying to push down that license post off the front page :D <4> hrrm <4> grumble grumble <3> he may have his point, jsut start off with a very wrong foot <4> that really made my day :/ <2> yeah, not very cool <3> if he say that in the channel, you already slap/kick/ban him :)
<4> guess he doens't quite grasp the amount of work that went into writing 4.0 <4> what would be my motivation to work on it for 3 years and then just give it away? <4> ridiculous <3> hope it won't need 3 years for 5,0 ;) <3> 1 more post to go <2> hey [Torgo] i just watched March of the Penguins and I hate to say it but the bub has some stiff competetion from those baby penguins when it comes to cuteness. <4> lol <4> don't eg him on ;) <3> http://www.cuteoverload.com/ <2> http://justalittleguy.blogspot.com/ <4> sheesh, you guys need a hobby <4> don't make me pull out the baby elmo pic <4> http://www.spinning-jennie.com/cats/elmo.htm <2> in china you are allowed one child and two pandas: http://www.pandafix.com/photos/uncategorized/1179.jpg <2> hehe, new cat? that is pretty cute, better put it up on http://www.kittenwars.com <3> missio accomplish, that post is off the front page now. ;) <4> :P <4> if it gets out of hand, i reserve the right to delete it altogether <4> nite <5> hello.. what is the good syntax to use the active form elements ? <5> i don't want to precise the name of my form in forms['name'] <3> there is no concept of active element <3> you can set that manually by handling onfocus on the fields <5> onfocus on the <form> and use a JS variable ? <4> you may be able to get away with one event on the form, yes <3> yes, and check srcElement of the event (different in FF) <4> failing that you'll need to attach an event to every element using a loop <5> ok i see <5> thanks you for your help.. it's appreciate <6> salutations matinales / morning greetings <7> hi all <8> is it possible to upload files with ajax ? <9> Doubt it. <9> You could probably upload file content though and have your serverside script create the file. <9> However, it wouldn't be like regular file upload. <8> ok how would i get the file content for posting ? <9> Copy&paste. :-P <9> You could always try with a regular file input. <10> Anyone know of a way to do something PHP's Variable Variable in javascript? basically... got a function func(var) which is called with something like func(SOME_CONSTANT), so I get the content of SOME_CONSTANT in my var param, however... I need to know the constant as well... ideas? <11> I can't understand <3> skins: you need to stop thing there is relationship between your severside script and javascript in the browser. from js point of view, all it want to know is var abc="blah"; now , you need to make the serverside to output that. var abc="${myjava_var}"; (<-jsp syntax here, replace with your php syntax <3> s/thing/thinking <12> can anyone tell me if there is a way to increase font size or bold text within a confirm popup window? <3> no <12> so just plain text is my only option? <3> yes <12> bummer! <12> thanks anyways! <13> Hi, I am working on a page where I can add div's with javascript (that works okay, i can set all the attributes I want, like height,bgcolor,...), but I want to add some onMouseOver and onMouseDown event handlers (specific for each div) to the DIV I add. How can I do that? <2> divRef.onmouseover = function (){//your code here} <13> and should it be document.getElementById(divid).onmouseover <2> sure, that's fine <13> hmmm, I first do: newdiv = document.createElement("div"); <13> then newdiv.onMouseOver=function(){alert("blaat"); and then document.body.appendChild(newdiv); <13> and the layer gets added, I can see it, but when I go with my mouse over it nothing happens <9> ***uming you didn't forget the last } in your code, that's just about right <2> onmouseover needs to be lowercase <9> Yes. Lowercase <13> lowercase?
<9> Yes. <13> why is that? isnt the correct syntax OnMouseOver ? <9> No. <9> Never was. <13> ah... where did I get that then? <9> That's just something some people did to make it easier to read. <13> ah ok <9> You don't have to do it that way in HTML either. HTML isn't case sensitive after all. :-) <13> ok <13> with onmouseover it works now. thanks <2> xhtml is case sensitive, so you're better off in the long term to leave it lowercase <9> Indeed <13> okay. Another problem: When i add a div manually (so I really type it into the HTML code), and I add this: onMouseUp="ReleaseLayer(this.id);" it works, but when I do in the JS this: newdiv.onmouseup=function(){ReleaseLayer(this.id);} it doesnt work (i cant move the layer). Why is that? <13> (the ReleaseLayer function works correctly) <9> Why do you p*** the id btw? <9> If you use the id for getElementById, then you might as well just p*** the reference. <13> ah yes <9> As for the question... function() { ReleaseLayer(newdiv.id); } <9> Or just ReleaseLayer(newdiv) if you follow my advice. :-) <13> I will add that later, its a good one <13> but for function() { ReleaseLayer(newdiv.id); }, it doesnt work neither <13> I now have this: newdiv.onmousedown=function() { PickupLayer(newdiv.id); } <2> that's no good because newdiv won't be anything when the function is called <2> i'm never sure of the syntax, but you need something like newdiv.onmousedown=function(arg){PickupLayer(arg.id)} if you know what i'm saying. pilum or definitely fatbrain should be able to elaborate. <13> http://cpp.enisoc.com/pastebin/6653 here is the piece of code thats relevant (for actually adding the layer) <9> Should apply the functions after you've added it to the body. <2> yeah, i agree with pilum <13> k <2> back in 20 <13> It still doesnt work: I posted some more code here: http://cpp.enisoc.com/pastebin/6654 <13> hmm, never mind, it isnt in the event handlers <13> the functions are cales (i tested it with an alert() inthe function) <13> Okay, I got it, the clou was that I had to add the newdiv.position="absolute" to the new layer... <14> it's the reference to the object from within the function <14> ah <3> i hope you mean newdiv.style.position = "absolute" <13> yes <13> I meant that, sorry <13> Is there an opposite of document.body.appendChild ? (I suppose so :) ) <15> .removeChild <2> .asplodeChild <13> ok <15> heheh <2> better go with RoBorg's choice ;-) <15> mine is safe for indoor use <13> :) <3> is hot today in montreal ... <2> yup <2> in an hour i'll know if i'm going back to work next week. <13> can you overload functions in JS? <13> like in JAVA? <3> no <13> pitty :( <3> but you can detect have you p*** in a certain parameter <3> function a(p1,p2) {} .... you can just call it with a(myp1); <13> ah ok <3> furtive: you sign the contract just in time ;) <2> yup <16> persons = xmlDoc.getElementsByTagName("name"); persons.length returns 2 but persons[0].nodeValue returns null despite the XML element containing cdata "Sanchez" <2> i don't know of any tag called <name> <4> xml <4> JasonMog, what parser? <13> I am making a fairly big Javascript application, that is supposed to be ran from the internet. Now I have 6 different .js files with the functions in, so I easily know wich function is where. Is that good, or should the number of .js files be limited? <4> Joske, that's good <2> yeah. you can pick and chose what needs to be included in which page. <4> JasonMog, try without nodeValue <13> ok... But I need every file on every page (it is becomming some kind of windows like GUI, with windows etc, so there is just 1 "page") <13> but then I will continue splitting up the files inthe future <4> great idea, they will be cached <13> Is there another argument against NOT using global variables in JS besides the regular ones that are there for any language? <4> used responsibly there is no problem with them <4> you're better off placing them in your own namespace though <4> like var globals = {}; globals.mySetting = 123; <13> ah yeah, that is indeed safer
Return to
#javascript or Go to some related
logs:
#php #php funnyinside;com #AllNiteCafe #linux #AllNiteCafe reddiena What sport was Boris Onishchenko caught cheating at in the Montreal Olympics ?
#c shrunkgirl
|
|