I am writing a quick alias that is going to go through a large list of proxies and gline them all, however, proxy lists usually come in this format:
###.###.###.###:Port
I need to remove the : and replace it with a space so that i can just read it in, use $1 to get just the IP, and then ban the IP.
How do i do that?
I tried this but it didnt work:
Note: i am only at the replacing stage
alias banproxy {
set %testfor $read(proxy.txt, 1)
if (: isin %testfor) {
echo : is present, I am going to assume that that is the seperator for the port and remove anything after it.
set %lines $lines(proxy.txt)
set %count 1
set %line $read(proxy.txt, %count)
set %toban1 $replace(%line, :, )
echo %toban1
}
}
if i use $remove, it removes the : but doesnt leave a space =/
any ideas?
I also tried using " " to put a space but that didnt work either.
thanks for your help!