Shoutbox
latest posts
member list
search
rules
contact
login
|
register
|
shoutbox
What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox
»
MsgHelp Archive
»
Messenger Plus! for Live Messenger
»
Scripting
» [Request]Letter change
[Request]Letter change
Author:
Message:
akyyy
Junior Member
Posts: 32
Joined: Apr 2005
O.P.
[Request]Letter change
I need very simple script.
So.
If I writte specially letter (e.g. á, é)
Script changer a and e!
07-16-2009 09:02 PM
MrT
Junior Member
Coding For Fun
Posts: 62
35 /
/
Joined: Jul 2006
RE: [Request]Letter change
function OnEvent_ChatWndSendMessage(ChatWnd, Message) {
msg = Message
msg = msg.replace("á","a");
msg = msg.replace("é","e");
return msg
}
i think it will work
This post was edited on 07-18-2009 at 11:18 AM by
MrT
.
07-18-2009 11:04 AM
Spunky
Former Super Mod
Posts: 3658
Reputation:
61
36 /
/
Joined: Aug 2006
RE: [Request]Letter change
code:
function OnEvent_ChatWndSendMessage(cw, m) {
return m.replace(/a/g,"á").replace(/e/g,"é");
}
Yours won't work if there is more than one instance of "a" or "e"...
A RegExp will do tthe trick and I've shortened the code quite a bit too
This post was edited on 07-18-2009 at 12:04 PM by
Spunky
.
<Eljay> "Problems encountered: shit blew up"
07-18-2009 12:04 PM
«
Next Oldest
Return to Top
Next Newest
»
Threaded Mode
|
Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe
|
Add to Favorites
Rate This Thread:
Select Rating...
5 ... Best
4
3 ... Average
2
1 ... Worst
Forum Jump:
Please select one:
--------------------
Latest Posts
Private Messages
User Control Panel
Who's Online
Search
Forum Home
Open Forum
Forum Rules:
You
cannot
post new threads
You
cannot
post replies
You
cannot
post attachments
You
can
edit your posts
HTML is
Off
myCode is
On
Smilies are
On
[img] Code is
On