每步DDNS.5.X版本测试成功!
本帖最后由 hainanmm 于 2011-5-8 11:49 编辑每步DDNS.5.X版本测试成功!
自己改改。没想到,能用了。哈哈!!
水平小菜,搞了一个通宵!
收点小板,不要见怪!
:local ednsuser "user"
:local ednspass "password"
:local ednshost "user.meibu.com"
:local ednsinterface "adsl1"
:local members "http://main.meibu.com/ip/login.asp?"
:local status
:local status running]
:if ($status!=false) do={
:local ednslastip [:resolve $ednshost]
:if ([ :typeof $ednslastip ] = nil ) do={ :local ednslastip "0" }
:local ednsiph [ /ip address get address ]
:local ednsip [:pick $ednsiph 0 [:find $ednsiph "/"]]
:local ednsstr "name=$ednshost&pwd=$ednspass&userip=$ednsip"
:if ($ednslastip != $ednsip) do={/tool fetch url=($members . $ednsstr) mode=httpdst-path=$ednshost
:delay 2
:local result
:log info ($ednshost . " " .$result)
/file remove $ednshost ;
}
}
注意修改蓝色部分!
页:
[1]