@genius_at_work
I rebuild your code a bit so it fits with the rest.
Now i was wondering if it really is needed to keep this format when adding data in hash tables?
/hadd <table> <data_name> <value>
I thought being smart and just replace echo with /hadd but got punished right after it because servers with spaces in there name are getting cut. Maybe someone knows a workaround for it?
Another thing i was wondering about what the best method was to see if site is active or not?
Is using sockets the best method for it or just try to login and if it time's out site is down?
Rush has a command to disable site and stores values itself so the script i'm trying to create doesn't need an extra value for active or not, maybe just for user to show but not really needed.
For now this is what i have. I don't think it can't be made any faster, just the space problem when adding data
alias serversadd {
var %r = /<site name="(.+?)" uid="([\da-f]+?)">/i
if (!$regex($1,%r)) return
echo -a $regml(1)
/hadd servers $regml(1)
}