@# Quotes DB     useful, funny, interesting





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



Comments:

<0> http://www.nomorepasting.com/paste.php?pasteID=57680
<0> untested
<1> cool
<0> this ***umes that the getElementById is pointing to an image object
<1> lemmie try it
<1> you mean a img?
<1> tag
<0> ya
<1> hmmm
<1> how would i know
<0> well for starters it would have an id "Content"
<0> (e.g. line 4) .
<1> k
<1> not working
<1> i uploaded it
<0> paste the source to your whole page



<0> and not in the channel ;-)
<1> k
<1> 1 sec
<1> http://pastebin.com/555395
<0> fool, you have Content as the id of a div, not an img
<1> i think i got something wrong
<0> what did i just tell you
<1> ok how would i change it
<0> move the id from the div to the img
<1> k
<0> when you've got some time i suggest visiting http://www.w3schools.com/js
<1> <img title="Alt: Barn in Virgina" cl***="mainpic" src="Feb/images/img1.jpg" alt="Barn in Virgina" id="Content" />
<1> like that right?
<0> yes
<1> yea i am slowly learning it
<1> k
<1> ok
<1> no go
<0> what's the error, what happens?
<1> it still goes to the next page
<1> instead of staying on the same page and loading the image
<1> no erros
<0> if it just goes to the other page then it's because you have a value in the href, so you'll have to keep href="#" and find another place (i suggest a two dimensional array) for holding your .src and .title
<1> hmmm
<1> ok
<1> .title i don't need
<1> so how would i code a variable for mysrc
<0> sorry, i've helped enough, i'm tired and it's late for me.
<1> ok
<1> thx
<0> i suggest haveing an array e.g. var images = [|]
<0> err
<0> i suggest haveing an array e.g. var images = ["/path1.jpg","/path2.jpg", "path...."]; and then p***ing index of the array from the onclick
<2> Foo.prototype.func = function() { this.bar = 123; this.test = function() { this.bar = 321; } this.test(); };
<2> why is this.bar in the test function not applying itself to the base function?
<2> is there a way to get around this scoping issue?
<3> if i've loaded some xml into a response object via AJAX, how do i access the nodes inside it?
<4> like any dom object
<4> ?
<4> sure you don,t use responseText
<3> well i dunno....
<3> why not?
<4> if it's text, well it's ok
<4> but if it's html or xml and you want too manipulate it .. you manipulate it that's it ..
<4> xmlHttprequest
<4> it's made to hande xml
<4> handle
<3> yes i loaded the xml into a variable/object called response
<4> response.getElementById('nodeId').value
<4> or what ever
<4> not sure if it's the right syntax tho
<3> yeah but that doesnt work
<3> i used responseText
<4> did u actually read what I write ?
<4> <4> sure you don,t use responseText
<3> yep i did :)
<4> responseText return a STRING
<3> oh ok, got it
<4> you have to retrieve a dom object :)
<3> after manipulating the dom object, i can return the string anytime?
<4> dunno, didn't play with that yet



<4> hm
<4> responseTxt = myAjax.responseText;
<4> response = myAjax.response;
<4> ?
<3> yes
<3> response = http.responseText;
<3> var nameNode = response.getElementsByTagName("name")[0];
<3> which of course was giving an error
<3> .respon***ML.
<3> thast the one i needed! :)
<2> is there anyway to set a 'global' variable that extends the current scope?
<5> i think declaring it outside the function?
<5> not sure
<6> I'm working on a scrollable table, with a fixed header. The header fields should align with the width of the fields in the scrollable body.
<6> What's wrong with this: for( i = 0; i < hdr.rows[0].cells.length; i++ )hdr.rows[0].cells[i].width = tbl.rows[0].cells[i].offsetWidth;
<6> (it nearly works - except each header cell is a few pixels too wide)
<2> for one things, its ugly
<6> how would you make it more elegant?
<2> i would use thead along with tbody
<2> dont just code it for IE, make it independant
<2> saves you time in the long run
<2> plus knowing proper coding practices are more benefical
<6> ...I've tried "for( i in hdr.rows[0].cells )" but when I added "alert(i)" it started printing "0, 1, ..., length, item, namedItem" - I don't understand why the last 3 strings came up...
<6> I'm actually doing most of my testing in Firefox.
<2> whats is the hdr.rows[] thing then?
<6> I'm also using thead and tbody.
<2> =)
<6> <thead><tr><th></th><th>City</th><th>Country</th><th>Home</th><!-- <th>Current</th>--></tr></thead>
<6> To make the table scrollable, I'm adapting somebody else's script.
<6> It attempts to split the <thead> and <tbody>.
<6> <table><tr><td>...thead...</td></tr> <tr><td><div style="overflow:auto;"> ...tbody...
<6> That much of it works (although I don't understand "hdr = tbl.cloneNode(false); hdr.appendChild(tbl.tHead.cloneNode(true));")
<6> ...why's the 1st part required?
<6> The bit that I'm adding is auto-resizing of column widths, without specifying them explicitly.
<6> xeer: To answer your question, I'm using "hdr.rows[0].cells" to alter the width of each cell in <thead>
<6> My problem with changing the widths, is that as far as I can tell, "cells[].width
<6> is "" because the HTML doesn't specify it, but cells[].offsetWidth doesn't seem to be the property I'm after.
<7> salutations matinales / morning greetings
<8> /amsg hey, can someone help me? why the script dosent disapier the other items? http://pastebin.com/555689
<9> "Programming today is a race between software engineers striving to build bigger and better idiot-proof programs,and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." -- Rich Cook
<3> heh
<10> hi i have a question about preloading
<11> really?
<10> yes
<11> wow
<10> hehehe
<10> i want to load all images before loading the entire page
<10> newimage1 = new Image();
<10> newimage1.src = "./images/bottom_bar.jpg";
<10> and 18 more like that
<10> but when I upload it, it displays the page already then downloads the images
<10> is there a way where it preloads all images and doesnt display the page until all pictures have been cahed??
<10> please help?
<10> how do i preload all images before displaying the entire page?
<10> question
<10> i have a question about preloading
<12> 'morning
<13> morning.
<13> ht311: can you load this url? https://bugzilla.mozilla.org/show_bug.cgi?id=327170
<12> You are not authorized to access bug #327170
<12> your bug?
<13> ya
<12> you can't access it even with your account? seem it go under the security review then
<12> since you put all the FF user in harm way, hahahhaaa
<13> I can access it, but I want to share :P
<13> did you see the *crash* code?
<12> it used to be ok yesterday. yup, saw that
<13> goodie :)
<13> anyhow, the bug is resolved.
<13> for 1.9a trunk
<12> only crazy people can write code that way to crash a browser :D
<13> targeted*
<12> oh that is fast
<13> indeed


Name:

Comments:

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






Return to #javascript
or
Go to some related logs:

#chatzone
sirsands
blackberry lsusb
Which is colder, minus 40 degrees centigrade or minus 40 degrees fahrenheit ?
#AllNiteCafe
#linux
#c
#AllNiteCafe
teens from checz republic
#linux



Home  |  disclaimer  |  contact  |  submit quotes