| |
| |
| |
|
Page: 1 2 3 4 5
Comments:
<0> now my stuff in other editors becomes peppered with :w's and 1G's <1> tried emacs too, but the curve was too steep. I just keep going back to textpad as "good enough" <2> sukotto: once you get proficient with vi and learn some shortcuts and macros, you'll be flying around your files like you wouldn't believe <1> yeah, that's my most common mistake with any editor. :wq <0> i even type :wq instead of /part in irc ;) <2> Tangram: heh yeah me too, especially when i'm forced to use a windows box <2> hah <1> expanding/collapsing code segments. now that makes my mouth water. <0> :) <2> yeah, i just found out about folds 1-2 months ago. now my files are filled with {{{ and }}} <2> sukotto: give vi/vim/gvim another shot, and stick with it for a week+. you'll be glad you did <1> I'm not totally happy with textpad right now. Am doing asp/javascript apps and it's a pain (especially writing asp fucntions that output javascript functions that do work :-) <1> Pilum , sorry to go off /topic <2> btw guys, i've got an on-topic question =P <0> :) <2> if i specify an html file like so to open a new window: document.open('foo.html'); and then write to the new window with document.write(), the contents of the new window are completely overwritten. why is that?
<0> i think you're looking for window.open() ? <1> You might want to name the child window <2> Tangram: ah yeah, typo <0> hmm ok <0> i don't generally use document.write(), but doesn't it overwrite the page contents? <2> summary of my question: http://rafb.net/paste/results/f3CLyB93.html <2> Tangram: so document.write() overwrites the contents of the target? <0> i'm not 100% sure, as i don't generally use it, but that's my recollection <2> Tangram: is there a way to append? <0> well what i do is just use document.createTextNode('foo'); <0> and append the node into the DOM using element.appendChild() <2> thanks, i'll google that <2> btw, is that valid in ie5? <0> yes <2> sweet <2> and firefox/opera too, i ***ume? <0> yup <3> document.write() clears the current document if called after window.onload has been triggered. <0> http://www.quirksmode.org/dom/w3c_core.html <3> Use DOM methods instead. <3> Or even innerHTML <0> there's your confirmation... ;) <2> thanks. playing with it now <2> can you include html code within createTextNode() ? <0> hmm... if it works, it won't work the way you want. you need to use document.createElement('tagname') <4> ppl> hi..._ <2> Tangram: i'm trying to append a whole block of html code to the end of an existing html page. is that possible, or do i have to break up the html block? <0> the 'easiest' way would be to use innerHTML i guess <0> document.body.innerHTML += 'string of new HTML to append' <3> Hi ]stalker[ <3> As for editors I agree with fatbrain. <2> Tangram: hrmm, i must be doing something wrong, because using innerHTML, my content isn't being written: var foobar = window.open('foobar.html', 'foobar'); foobar.document.body.innerHTML += 'extra content'; foobar.document.close(); <0> as an aside, why not just put the extra content straight into foobar.html? <2> Tangram: it's dynamically generated <0> ok <0> well other than the obvious recommendation of using a server side language to generate it ;) let me think for a minute <3> As could the document in the popup be. :-) <3> foobar.document.close()? <3> You haven't opened it heh. <0> yah, i'm not sure about that part either <5> anyone know how to print without scaling in ie7 ? or control the scalling <2> Tangram: this is exactly what i'm doing: http://rafb.net/paste/results/M2UgEz10.html <3> Line 4: receipt.document.body.innerHTML+='extra content'; <3> And drop line 5. <2> Pilum: what about line 4? <2> Pilum: i commented out line 5, but the same behaviour occurs <3> I pasted the correction. <3> Although a text string as a direct child of body isn't right. <2> omg hah, why the heck do i have brackets around the text??! =P <3> Beats me. <5> IE7 is **** with .print(); <5> :@ <2> Pilum: with the change on line 4 and removal of line 5, "extra content" isn't written: http://rafb.net/paste/results/XsaBtJ54.html <3> And no errors? <5> Pilum you played with print scaling <5> know ifits possile to turn off <2> Pilum: unfortunately, no errors <3> NeoFuture: No, I haven't and I don't know. <2> Pilum: any other suggestions? <3> I would do it serverside. <2> Pilum: i think the reason innerHTML isn't working is because the page hasn't fully loaded yet. is there a way to wait until the page loads before setting .innerHTML?
<0> window.onload <3> Yes. <0> http://dean.edwards.name/weblog/2006/06/again/ <6> that is far too advance for him :) <2> if i use var foo = window.open(..); should i end it with foo.close(); or something similar? <0> ht311: fair enough <2> heh <0> litage: no. that will actually just close the popup <2> ah right =P <2> if i use var foo = window.open(); why should i note use foo.document.close(); ? <3> Because you're not opening a document? <0> those are unrelated functions. window.open() opens a new window. document.close() closes a document that's been previously opened by document.open() in order to use document.write() <2> gotcha <2> i guess i'll do this server-side. thanks for your help guys, i really appreciate it <6> litage: you need to forget what you see about document.open .write and .close <0> server side is definitely the best way to do it <7> anyone who could tell me if I somehow can use the tab button as normal in html textboxes ?? <6> you need to handle the onkeyup for the tab key yourself, insert a tab character at the caret postion and cancel the event after <8> intercept key #9 in onkeypress .... insert the character or spaces manually and return false <7> alright, thank you! =) <2> is it possible to make a submit button open a new window and post data to the new window's url? <8> set target="_blank" in the form tag <5> can you turn off headers and footers with CSS when printing <9> Can javascript do dictionary arrays? Im ***uming no? <9> Oh it can :D <7> [Torgo] still cant get the tab function to work in text boxes; http://erxz.com/pb/1632 <10> hi <3> NeoFuture: @media print <2> [Torgo]: thanks for that! <11> is there a way to delete a record when user left the page and going to another one? <9> Isnt there a window.onunload? <11> yeah but i want to conmbine with that php script that will delete record from db <9> Yeah so ajax <9> XMLHTTPRequest <6> define "leaving" , and it is not a job for javascript anyway <6> ***ume you know the user is going to another page of yours, you shoudl handle it on the serverside before serving the user the new page <9> I was going to say something to that effect but ***umed it was too obvious... Im guessing the user is leaving for real <11> i got "who is on this page right now" and i want that if user leaves it will delete him from the db <9> There are better ways <11> how <9> E.g. Make 'right now' mean 'within the last 5 minutes' <9> And then when you show the list, delete all records which havent had activity in 5 minutes or more <11> and if user wants to chat with this user 1 on 1 <6> and need to send a heartbeat to the server once a while <11> and user is not online right now <6> then "attempting to connect .... failed" <9> ^^ <11> but how he knows ? <11> i cant ping thier ips <6> well it really depends on how you do your chat <11> i want to make chat 1 on 1 <11> like " there are 390 users in this page.. chat with one of them <6> make it first, and you will have your answer along the way <11> i did it <11> but i got problem when user trying to chat with user that left the website 30 secounds ago <11> got me? <6> how you start your chat session? <11> with php <6> .... <11> using mysql db to p*** the messages <6> so the page keep on refreshing? <9> :o <11> yeah <6> so if one of the user pages are not refreshing, then you consider the user is offline <6> and tell the other user he is gone <11> brb <12> alert(treeID); <12> alert(this.treeID); <12> both lines are inside a method <13> Hello AM1A`, sk8ing <13> Hello ht311 <12> treeID is defined as a private property <13> ht311 you use ASP.NET ? <12> only the first function works
Return to
#javascript or Go to some related
logs:
#networking #ubuntu iz zobb oxx descarta a los calificadores kif tkun taf kemm tizen indadream eybudy #php virtualhost deny ip KsCD keeps
|
|