A Conversation for Ask h2g2
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Started conversation Oct 7, 2001
Okay, I need a bit of Javascript (that I will be adding to a larger script) that will take the last four characters of the URL of the page it's on and put each one in a separate variable. I will give you credit for helping with it.
Need help from someone who knows javascript better than I do.
The Jester (P. S. of Village Idiots, Muse of Comedians, Keeper of Jokes, Chef and Seraph of Bad Jokes) LUG @ A458228 Posted Oct 7, 2001
<!-- // hides script from old browsers
var loc=window.location.href;
var loclen=loc.length;
var a=loc.charAt(loclen-4);
var b=loc.charAt(loclen-3);
var c=loc.charAt(loclen-2);
var d=loc.charAt(loclen-1);
// stop hiding script -->
38-J
JOTD: Laugh and the world ignores you. Crying doesn't help either.
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 7, 2001
Thanks!! Adding the finishing touches now.
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 7, 2001
It's done. You can click the link at the top of my space to try it. What I'd really like to do is make a "smiley toolbar" with a couple of frames, where you type in the smiley code and it loads the smiley in a tiny frame off to the side, and then have a bookmarklet to launch it. There's also smileyonly.html, which has the script to load the smiley and nothing else.
Need help from someone who knows javascript better than I do.
Dancer (put your advert here) Posted Oct 7, 2001
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 7, 2001
Can't do that easily, because I'm using actual images. Sorry. But the codes can be typed into forums (nnLJ).
Need help from someone who knows javascript better than I do.
Dancer (put your advert here) Posted Oct 7, 2001
Already using it in threads and spreading the word
Can you make it case insensitive though
Dancer (usually a case sensitive guy, just needs a rest) ()
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 7, 2001
I could, but it would involve re-uploading the files with different filenames, since I don't think I can make copies of files with my webspace provider.
Need help from someone who knows javascript better than I do.
Dancer (put your advert here) Posted Oct 7, 2001
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 7, 2001
No, it has a web upload interface. FTP sounds like a good idea, though, I'll see if I can do that.
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 7, 2001
Can't.
Need help from someone who knows javascript better than I do.
Venus Posted Oct 9, 2001
i tried u generator it's not working
Need help from someone who knows javascript better than I do.
some bloke who tried to think of a short, catchy, pithy name and spent five sleepless nights trying but couldn't think of one Posted Oct 9, 2001
Why don't you just use the .toLowerCase() or .toUpperCase() methods. eg:
...
var loc=window.location.href;
loc.toLowerCase();
...
Then you could just have the files with any characters defined by the script as lowercase (or uppercase if you wish)
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 10, 2001
Ooh, good idea.
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 10, 2001
Venus: Um, could you please be a bit more specific? "it's not working" isn't a very helpful bug report. What exactly is not working about it?
Need help from someone who knows javascript better than I do.
Venus Posted Oct 10, 2001
actually i'm entering the code and pressing generate then it'll give connecting 2 1 website and nothing i mean i can't see that smily or what
Need help from someone who knows javascript better than I do.
NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) Posted Oct 10, 2001
Does the second page actually load? Also, what browser are you using?
Need help from someone who knows javascript better than I do.
Venus Posted Oct 11, 2001
no , Launch Internet Explorer Browser
Need help from someone who knows javascript better than I do.
Venus Posted Oct 11, 2001
this is the version # 5.00.2614.3500
Key: Complain about this post
Need help from someone who knows javascript better than I do.
- 1: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 7, 2001)
- 2: The Jester (P. S. of Village Idiots, Muse of Comedians, Keeper of Jokes, Chef and Seraph of Bad Jokes) LUG @ A458228 (Oct 7, 2001)
- 3: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 7, 2001)
- 4: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 7, 2001)
- 5: Dancer (put your advert here) (Oct 7, 2001)
- 6: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 7, 2001)
- 7: Dancer (put your advert here) (Oct 7, 2001)
- 8: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 7, 2001)
- 9: Dancer (put your advert here) (Oct 7, 2001)
- 10: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 7, 2001)
- 11: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 7, 2001)
- 12: Venus (Oct 9, 2001)
- 13: some bloke who tried to think of a short, catchy, pithy name and spent five sleepless nights trying but couldn't think of one (Oct 9, 2001)
- 14: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 10, 2001)
- 15: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 10, 2001)
- 16: Venus (Oct 10, 2001)
- 17: Venus (Oct 10, 2001)
- 18: NMcCoy (attempting to standardize my username across the Internet. Formerly known as Twinkle.) (Oct 10, 2001)
- 19: Venus (Oct 11, 2001)
- 20: Venus (Oct 11, 2001)
More Conversations for Ask h2g2
- For those who have been shut out of h2g2 and managed to get back in again [28]
3 Weeks Ago - What can we blame 2legs for? [19024]
Nov 22, 2024 - Radio Paradise introduces a Rule 42 based channel [1]
Nov 21, 2024 - What did you learn today? (TIL) [274]
Nov 6, 2024 - What scams have you encountered lately? [10]
Sep 2, 2024
Write an Entry
"The Hitchhiker's Guide to the Galaxy is a wholly remarkable book. It has been compiled and recompiled many times and under many different editorships. It contains contributions from countless numbers of travellers and researchers."