There is the possibility to write a value into a text field by use of the documentgetElementByIdmessage_receivervalue
handleEvent]" nsresult: "0×80570030 (NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED)" location: "unknown" data: no]
spoof3r, div style="clear:right;float:right"table … and set the body to margin: 0px;
has anyone ever used jscalendar?
hey i've got my table with two fields labeled user name and password, and a checkbox labeled "Save Password"
im trying to make it so that if a visitor checks the "Save password" checkbox, it will save the user name and password as cookies. can someone please help me? i havent been able to figure this out for the past 2 hours =/
onclick="handleCookies(this)", k0rso ?
and then function handleCookies(elem){var isChecked=elem.checked; }
hmm ..
i know it's really offtpic
but i need someone to do me a gavor
k0rso, but you should really not save that kinda info in cookies
favor
sh3sek, okay..?
Here's exactly what im trying to get in the end. I want it to save the username and password if the Save Password checkbox is checked. then whenever a visitor types in a value in the user name field, see if there is a user name cookie, and if there is and it matches the user name typed in,
complete the password field for the visitor using the password cookie
make sence?
what kind of favor?
ive tried and tried and tried
k0rso, yes, but I am not going to help you with that
i need someone to connect to some irc server and tell someone to come here
i'm on a webchat on some hospital
under no circomstances should you save user password or username in a cookie
why not? im not aksing anyone to do it or anyything.
which is not in my city, and i don't have calls
EVER
*maybe* username, but *NEVER* save the password
what is wrong about saving encrypted password ?
and please, i have no place to sleep here -_-
im just trying to do these little script questions in my book im learning from
i don't know what to d…
do*
it is possible to decypt the password or the algorythm used to encrypt the password
what?
not really
what about md5 with salter?
you can't encrypt to, it it will be very hard to crack it
I wouldn't do it anyway
well, anyone? please?
it sure is possible, sh3sek , but what exactly are you wondering about?
what i wonder about? :X
hmm, i'm in an webchat from some hospital, which is not in my city, and i have no calls. i know someone in this city, but i can't contact him
what part don't know how to do?
i just need someone to tell him to come to this server - he's on irc, aanother network
sh3sek, sory, that was for k0rso
what irc network
k0rso, http://www.webtoolkit.info/javascript-cookies.html might help you with the cookies
RockerMONO, i'm not registerd
?
join #rmono please
i can't send pm..
dabear, irc.nix.co.il
his nick is spdr
n/m, RockerMONO is helping me
I have a function that loops through an index 'i' then it calls a function with a loop over index 'i' is that a problem/
nope
it seems to end my outer loop.
code?
melkor, in the loop, use var i=0; etc instead of just i=
or use j instead of i on the second loop
or you can use the let-statement
well I changed index letters and it work, but it could be something else.
dabear, thanks~
hey
anyone knows if I can use document.getElementByTag('body').innerHTML to change the page's body ?
document.getElementByTag('body').innerHTML = 'ERROR';
I'm doing that
well, that's what it do
oh
it's
and It doesnt show ERROR
getElementsByTagname
(no and )
and it returnts an array
so
dcument.getElementsByTagName('body')[0]…..
but you can just use document.body.innerHTML
oh ok
it returns a collection, not an array
`collection
(or nodeList) Think of it as an array that's immutable and live. It's immutable so there's no push/shift/etc.. It's live because if you add new elements to your document then the collection returned by getElementsByTagName() will change WITHOUT calling it again.
and does it work with IE, Firefox and so on?
hey, Woosta
yes, it does
well, i'm going to find some nice place to sleep ..
damn. i have to sleep in the street
at least i have some cigs
well, gn all
There any issues with onblur/onfocus in IE?
probably doesn't support it
:P
well, everything was working with inline event handlers
but now I made it a little unobtrusive and it isn't working the same
hmm.
I'm pretty sure there are no typos
It used to be onBlur and onFocus but now i have element.onfocus = function() { }
and onblur = function() { }
…hmm?
and I'm doing it after window load
your defining your own method?
Uhm?
yeah i guess
i'm just making it unobtrusive
not really changing anything
element.onfocus=function() as opposed to (element stuff) onfocus='function()'
well
can anyone help me out with a simple drag/drop script?
onBlur="if(this.value=='') this.value=' Enter search here…';" onFocus="if(this.value==' Enter search here…') this.value='';"
that's what it used to be
can someone help me out with this? http://rockermono.nonlogic.org/javascript/drag_drop/
OH! nevermind i think i got it
it onblur should work. Did you make a very small test page?
theGZA from what I've seen you would have to reference it as an attribute. ie element.attributes[i].nodeValue = function()
er with quotes and such, and i would have to correspond to the correct index
what?!?
reference it as an attribute? eh.. why
is there something like PHP's exit() or die() for JavaScript?
break; ?
theGZA … I'm disturbed by IE
what could I do to delete all the content inside the html tag and write what i want?
aquaman, document.getElementById('html').innerHTML = 'new text' ?
or getElementsByTagName
I tried that and It doesnt do anything
or document.getElementsByTagName('html')[0].innerHTML = 'new text'
[melkor] I did that too without success
just document.write(); will replace the whole currentdocument
where don't you have success?
can you have it print out the document.getElementsByTagName('html').length
oh oh melkor ahaha I fogot to write Name, I put document.getElementsByTag() lol, I'm sorry
I love java script
hi all
i don't understand this :
var d=document.login.d.value;
d=d.toLowerCase();
like, d = what now?
hope anyone can help..
foo = 'bar'; foo = null; if(foo)
the lowercase version of what it used to be
Jan-: Error: Error: syntax error at line 0: foo = 'bar'; foo = null; if(foo)
foo = 'bar'; foo = null; if(foo){return 'true'}
Jan-: Error: Error: invalid return at line 0: foo = 'bar'; foo = null; if(foo){return 'true'}
grrr
if I set something to null, then if() it, does it exist?
var d=document.login.d.value; — don't do it that way
`forms @ nour
forms: Accessing form elements via JavaScript: Don't use document.forms[index].elementName or document.formName.elementName. Use document.forms['formName'].elements['elementName'] or document.getElementById('formID').elements['elementName'] or document.getElementById('elementID')
foo = 'bar'; foo = null; if(foo){wibble= 'true'}; wibble
Jan-: Error: Error: ReferenceError: wibble is not defined at line 0: (null)
Aha.
foo = 'bar'; if(foo){wibble= 'true'}; wibble
Jan-: true
no problem with foo ..
oh wait
so, its the lowercase of d
but, what is d ?
foo = 'bar'; wibble=false; foo=null; if(foo){wibble= 'true'}; wibble
false
d=document.login.d.value; -
var d=document.login.d.value;
I assume 'login' is the name of a form and 'd' is the name of a form element
yes
Is a function called setup() supposed to be executed on page-load, or do I have to call it manually?
As I said, don't do it that way
you'd have to call it manually
i won't .. its there and i want to understand it ..
only window.onload is called automatically
What's the most unobtrusive way of calling it at load?
window.onload = setup;
attributeObject.x = y?
assumning, of course, that attributeObject is a DOM attribute object.
is "NaN" a valid typeof?
or would one just test typeof(n)!='number'
typeof( NaN )
number
typeof(typeof)
Error: Error: syntax error at line 0: typeof(typeof)
when using item.style.property syntax, background-image maps to backgroundImage and so on. does it not?
is there any way to write unknownVariable.knownProperty?
willrjmarshall I don't think there is a background-image crossover
just use item.style.background?
I don't think it has a javascript counterpart
nobody? anybody?
antibody?
somebody? everybody? peabody? blackbody?
backgroundImage seems to work fine in FX
make a temporary variable and make it = the unknownVariable
lol
I don't follow at all
will whats fx?
firefox?
like: var blah=unknownVariable; blah.innerHTML="this was pointless";
then wouldn't unknownVariable.innerHTML work?
but you need to know the unknown variable
well actually, how do you get the unknownVariable to begin with?
let me explain what it's doing
mk
the variable will be passed into a function as one of either "descendant", "ancestor", etc.
Then I need to access something like descendant.property
Hmm, I'm starting to think my implementation is stupid
idk about stupid
but it sure as hell is confusing =p
lol
Hmm
Yeah, very stupid
it would be smarter to just pass the object in the first place
lol
The Fx javascript debugger is throwing "document.getElementById("navigation") has no properties" at me - but navigation exists fine, and it was working a moment ago.Why would this be?
HI guys, I was wondering if there was a way to make javascript ignore the current value of a textbox.
hm
why wouldn't function getID(element){ alert(element.id); } work?
so that it is ~800px down where the user can see it?
buttons accept onclick event listeners?
that's actually a CSS things, position:fixed; and put it where you want it to show up
like div style="position:fixed;top:0px;left:0px;height:100%;width:100%;"this will show up as the whole page/div
know to appear way down the page.
right, that's what this does
RockerMONO, so that will work even if the vertical scrollbar is not at the top of the page?
the user won't have to scroll back up to see the div?
try this one a page with a scrollbar: div style="position:fixed;bottom:0px;left:0px;height:10px;width:100%;"this will show up as the whole page/div
and/or div style="position:fixed;top:0px;left:0px;height:10px;width:100%;"this will show up as the whole page/div
oh but add background-color:#1E51A5; or somethin so it contrasts the page
i actually use position:fixed; for the bottom bar of http://rockermono.nonlogic.org/webOS/desktop.php?guest=1 along w/ a code to hide the scrollbars, so it deff works =p
see y'all
http://pastie.caboo.se/83285 is not working, and I cannot for the life of me work out why. Can anyone see why not?
Oh. this.className, not class
heh
RockerMONO, actually, I think document.body.scrollTop was what I was look for…
ok
can someone help me here
http://rafb.net/p/HHr7XD11.html
omg. is mozilla using a java base javascript implementation?
no wonder is it so slow
anyone, please?
erm .. no .. it's spidermonkey which is written in C iirc
you forgot to ask a question
k. where can i get the source for that?
ask google
i have a little tool called jscompact which needs this spidermonkey stuff
where would you like me to paste code
is rafb.net ok?
I don't mind where you paste code
http://rafb.net/p/CtgvJZ58.html
uhm, thanks guys for the help
thanks Woosta
good night all ..
No probs .. can't remember what I helped with .. but it was a pleasure
im trying to make it so that if the visitor checks the "Save Password" box, it saves the user name and password as cookies
hi
i've tried this for hours now
and what happens?
hi
Can someone help me, I've been trying to find the solution all day and I've typed the problem in here 2-3 times today.
http://rafb.net/p/ZCL8pZ19.html
"handleEvent"' when calling method: [nsIDOMEventListener