[JS]脚本自动查找未注册的域名

2016-11-15 写技术

这是我在万网注册域名时写的脚本,两位的已经试过了,完全没有可注册的,现在是在搜三位的。 var url_wang = "https://wanwang.aliyun.com/domain/searchresult/"; var cq=['a','b','c','d','e','f','g','h','i','j', 'k','l','m','n','o','p','q','r','s','t', 'u','v','w','x','y','z']; var a=2; var b=6; var c=-1; var result = ""; fu...

阅读全文>>

标签: JS

评论(1) 浏览(1842)

[JS]Object and String in ajax function

2016-11-2 写技术

The difference between json object and json string while post with ajax: var login = function(){ var user = $("input[name=username]").val(); var password = $("input[name=password]").val(); var data = { username:user, password:password }; data = JSON.stringify(data); co...

阅读全文>>

标签: JS

评论(0) 浏览(1229)

[linux]useradd与adduser的区别

2016-10-25 写技术

1. 在root权限下,useradd只是创建了一个用户名,如 (useradd  +用户名 ),它并没有在/home目录下创建同名文件夹,也没有创建密码,因此利用这个用户登录系统,是登录不了的,为了避免这样的情况出现,可以用 (useradd -m +用户名)的方式创建,它会在/home目录下创建同名文件夹,然后利用( passwd + 用户名)为指定的用户名设置密码。 2. 可以直接利用adduser创建新用户(adduser +用户名)这样在/home目录下会自动创建同名文件夹 3.  删除用户,只需使用一个简单的命令“userdel 用户名”即可。不过最好将它留...

阅读全文>>

标签: linux

评论(0) 浏览(1238)

[c]mosquitto编码实现websockets协议

2016-10-20 写技术

mosquitto虽然本身是支持websockets协议的,但却依懒libwebsockets库,而libwebsockets库是基于poll的,所以如果想把mosquitto改为epoll模式很容易,却不能兼容websockets了。 为了解决这个纠结的问题,这几天把websockets协议用C语言重新实现了一遍,然后将mosquitto中调用libwebsockets的部分用自己的代码取代,今天终于实现了websockets下的mqtt通讯功能。 首先一些websockets的结构放在websockets.h中: typedef struct _WebSo...

阅读全文>>

标签: C linux

评论(0) 浏览(1740)

[c]uthash

2016-10-14 写技术

An example about uthash #include "uthash.h" #include <stdlib.h> /* malloc */ #include <stdio.h> /* printf */ typedef struct _user_t { int id; char name[25]; UT_hash_handle hh; } USER_T,*PUSER_T; void main() { int i; PUSER_T user, users=NULL; ...

阅读全文>>

标签: C

评论(0) 浏览(1357)

[c]strtok_r,strtok_s, _strtok_s_l, wcstok_s, _wcstok_s_l, _mbstok_s, _mbstok_s_l

2016-10-11 写技术

On the first call to strtok_s the function skips leading delimiters and returns a pointer to the first token in strToken, terminating the token with a null character. More tokens can be broken out of the remainder of strToken by a series of calls to strtok_s. Each call to strtok_s modifies strToken ...

阅读全文>>

标签: C

评论(0) 浏览(1563)

[ubuntu]Debug a running process by gdb

2016-10-9 写技术

1.Find the pid; ps aux|grep xxxxx 2.Bind; gdb (gdb) attach 111111 3.Show stack (gdb) bt 4.Go next (gdb)next 5. (gdb) detach 6.Exit (gdb)q

阅读全文>>

标签: ubuntu

评论(0) 浏览(1455)

[ubuntu]Install and set subversion server

2016-10-8 写技术

1.Install sudo apt-get install subversion 2.Create root fold of svn mkdir /var/svn 3.Create project svnadmin create /var/svn/project 4.Edit config /var/svn/project/svnserve.conf [general]  anon-access = none auth-access = write password-db = /var/svn/conf/passwd authz-db = /...

阅读全文>>

标签: ubuntu

评论(0) 浏览(1385)

[JS]javascript solution for md5

2016-8-31 写技术

(function($){ var rotateLeft = function(lValue, iShiftBits) { return (lValue << iShiftBits) | (lValue >>> (32 - iShiftBits)); } var addUnsigned = function(lX, lY) { var lX4, lY4, lX8, lY8, lResult; lX8 = (lX & 0x80000000); lY8 = (lY & 0x80000000); lX4 = (l...

阅读全文>>

标签: JS

评论(1) 浏览(1369)

[ubuntu]Set static ip address for ubuntu

2016-8-15 写技术

1.Edit file /etc/network/interfaces auto lo iface lo inet loopback auto eth0 iface eth0 inet static address 192.168.1.52 netmask 255.255.255.0 gateway 192.168.1.1 dns-nameservers 222.246.129.80 114.114.114.114 2.Reboot the system.

阅读全文>>

标签: ubuntu

评论(0) 浏览(1219)

Powered by anycle 湘ICP备15001973号-1