:global myvar
:log info "--- myscript run"
:log info $myvar
:log info "--- myscript end"
It doesn’t work. I also tryed to declare myvar “local” without success.
The sms “var=value” feature it is declared on wiki but is it officially supported by Mikrotik?
I would like to use it, to make RB answer to the right sms number.
I also have a similar issue to settle. Am trying to do a sms to my tik to create a hotspot user. The user name password and comments are to be specified on the sms.
mypass is my secret, Hotuser is the name of my script, username1,pass1,comment1 are my variables to capture username password and comment respectively.
Here is the script(script name:Hotuser)
:global username1
:global pass1
:global comment1
/ip hotspot user add name=$username1 password=$pass1 limit-uptime=24h profile=450k server=All comment=$comment1
The output should add a user by name: john password: john12 ans comment:252 789 to the hotspot.
I also have a similar issue to settle. Am trying to do a sms to my tik to create a hotspot user. The user name password and comments are to be specified on the sms.
mypass is my secret, Hotuser is the name of my script, username1,pass1,comment1 are my variables to capture username password and comment respectively.
Here is the script(script name:Hotuser)
:global username1
:global pass1
:global comment1
/ip hotspot user add name=$username1 password=$pass1 limit-uptime=24h profile=450k server=All comment=$comment1
The output should add a user by name: john password: john12 ans comment:252 789 to the hotspot.