...

View Full Version : How do I remove a character from a string



Gerryw
06-16-2004, 02:21 PM
Hi all,
I am quite new to programming in javaScript and I am trying to find the code to remove a character/s from a string/s. As an example, if I initialise a variable called 'aString' and utilise 'window.prompt' to input 'Summer' or 'Have a nice day', what would be the code between 'window.prompt' and the last line 'document.write' to get the result result 'Smmr' or 'ae a ie a'?

Antoniohawk
06-16-2004, 02:41 PM
To accomplish this, you will need to use regular expressions. I'm sure that you can get some help as soon as this thread is moved to the javascript section and not the post a javascript section... I'll give you the benefit of the doubt and guess that you were reading in this forum and forgot which you were in when posting. In the future, make sure that you're in the right forum for your topic. :)

glenngv
06-17-2004, 05:08 AM
http://www.codingforums.com/showthread.php?t=40052



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum