mIRC Home    About    Download    Register    News    Help

Print Thread
replace space with + #252278 01/04/15 07:02 AM
Joined: Mar 2015
Posts: 19
B
Blood_Wolf89 Offline OP
Pikka bird
OP Offline
Pikka bird
B
Joined: Mar 2015
Posts: 19
I am making a script for when people are too lazy to look something up a mod can type !google and what ever the question is and the output would link them a funny google page.

Example: !google mirc replace space with plus

Output: http://lmgtfy.com/?q=mirc+replace+space+with+plus

Here is my code:
Code:
on *:TEXT:!google *:#: { msg # Let me google that for you... http://lmgtfy.com/?q= $+ $replace($2-,  , +)  }

Re: replace space with + [Re: Blood_Wolf89] #252279 01/04/15 07:12 AM
Joined: Dec 2013
Posts: 779
N
Nillen Offline
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
$chr(32) refers to space. You can check out these over at http://www.asciitable.com/


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net
Re: replace space with + [Re: Blood_Wolf89] #252361 05/04/15 11:13 PM
Joined: Apr 2015
Posts: 3
K
Keydosed Offline
Self-satisified door
Offline
Self-satisified door
K
Joined: Apr 2015
Posts: 3
Code:
on *:TEXT:!google *:#: { 
  msg # Let me google that for you... http://lmgtfy.com/?q= $+     $replace($2-, $chr(32), +)
}