国产一级a片免费看高清,亚洲熟女中文字幕在线视频,黄三级高清在线播放,免费黄色视频在线看

打開APP
userphoto
未登錄

開通VIP,暢享免費電子書等14項超值服

開通VIP
自動發(fā)送新浪博客 視頻
從mysql中取數(shù)據(jù) 自動發(fā)布新浪博客 視頻記錄開發(fā)全過程。

http://dl.dbank.com/c0v4nfrj54【下載不了的 使用下面的鏈接  (我怎么能下呢?
)】


代碼如下

代碼 拿來是不能用的  你需要修改 數(shù)據(jù)庫鏈接字符串  還有表的名字 和字段

  1. import win.ui;
  2. import web.form;
  3. import math;
  4. import com;
  5. /*DSG{{*/
  6. var winform = win.form(parent=...; right=1148;text="AAuto Form";bottom=648 )
  7. winform.add(
  8. start_id={ bottom=47;right=566;left=537;top=18;font=LOGFONT( name="宋體";h=-12 );z=7;text="";edge=1;cls="edit" };
  9. static={ right=87;bottom=52;text="用戶名";left=19;top=23;font=LOGFONT( name="宋體";h=-12 );transparent=1;z=1;cls="static" };
  10. static2={ right=335;bottom=51;text="密碼";left=246;top=18;font=LOGFONT( name="宋體";h=-12 );transparent=1;z=2;cls="static" };
  11. password={ bottom=51;right=463;left=310;top=19;font=LOGFONT( name="宋體";h=-12 );z=6;text="password";edge=1;cls="edit" };
  12. end_id={ bottom=45;right=662;left=633;top=16;font=LOGFONT( name="宋體";h=-12 );z=8;text="";edge=1;cls="edit" };
  13. static4={ right=674;bottom=56;text="開始ID";left=577;top=18;font=LOGFONT( name="宋體";h=-12 );transparent=1;z=4;cls="static" };
  14. button={ bottom=47;right=742;left=692;top=13;font=LOGFONT( name="宋體";h=-12 );z=9;text="發(fā)送";cls="button" };
  15. sinaweb={ text="static5";bottom=510;right=1121;left=9;top=66;font=LOGFONT( name="宋體";h=-12 );transparent=1;z=10;cls="static" };
  16. username={ bottom=49;right=229;left=76;top=17;font=LOGFONT( name="宋體";h=-12 );z=5;text="testaau@sina.com";edge=1;cls="edit" };
  17. static3={ right=573;bottom=53;text="結(jié)束ID";left=488;top=20;font=LOGFONT( name="宋體";h=-12 );transparent=1;z=3;cls="static" }
  18. )
  19. /*}}*/

  20. var wb = web.form(winform.sinaweb)


  21. winform.button.oncommand = function(id,event){
  22.        
  23.         var username = winform.username.text;
  24.         var password = winform.password.text;
  25.         if (username == '' || password == '') {
  26.                 win.msgboxTest("請輸入用戶名和密碼","錯誤消息")
  27.                 return;
  28.         }

  29.        
  30.        
  31.         var s_id = winform.start_id.text
  32.         var e_id = winform.end_id.text
  33.        
  34.         if (s_id == '' || e_id == '') {
  35.        
  36.                 win.msgboxTest("請輸入開始 id 結(jié)束id ","標題")
  37.                 return;
  38.         }
  39.        
  40.        
  41.         wb.go("http://control.blog.sina.com.cn/admin/article/article_add.php")
  42.         wb.wait("")
  43.        
  44.         check_is_login()
  45.        
  46.        
  47.         s_id = tonumber(s_id)
  48.         e_id = tonumber(e_id)
  49.        
  50.         for(i=s_id; e_id ;1) {
  51.                 var blog_info = get_blog_from_db(i)
  52.                 send_blog(blog_info.title, blog_info.content, "it 計算機語言")
  53.                 wb.location = "http://control.blog.sina.com.cn/admin/article/article_add.php"
  54.         }
  55.          
  56.        
  57.        
  58. }

  59. delay_click = function (ele) {
  60.         var temp_time = math.random(200, 500)
  61.         win.delay(temp_time)
  62.         ele.click()
  63.         ele.fireEvent("onfocus")
  64. }



  65. check_is_login = function() {
  66.         var username = winform.username.text;
  67.         var password = winform.password.text;
  68.         if (string.find(wb.location, 'login.sina.com.cn')) {
  69.                 login_sina(username, password)
  70.         } else {
  71.                 logout_sina()
  72.                 login_sina(username, password)
  73.         }
  74. }


  75. login_sina = function(blog_username, blog_password) {
  76.          win.delay(3000)
  77.          wb.getEle("username").value =         blog_username;
  78.          wb.getEle("password").value =         blog_password;
  79.          var doc = wb.getDoc()
  80.          var ele = doc.all(56)
  81.          delay_click(ele)
  82. }


  83. logout_sina = function() {
  84.          win.delay(3000)
  85.          var doc = wb.getDoc()
  86.          var ele = doc.all(35)
  87.          ele.click()
  88. }

  89. send_blog = function(title, content, tag) {
  90.         win.delay(3000)
  91.         //title
  92.         wb.getEle("articleTitle").value = title
  93.         var doc = wb.getDoc(0)
  94.         doc.all(5).innerHTML = content
  95.         wb.getEle("articleTagInput").value = tag
  96.         wb.waitEle("sort_id_20_113").click()
  97.        
  98.         var send_button = wb.getEle("articlePostBtn")
  99.         delay_click(send_button)
  100.        
  101.         win.delay(65000)
  102. }

  103. get_blog_from_db = function(id) {
  104.         var blog_info = {title: ''; content : ''}

  105.         conn = com.CreateObject("ADODB.Connection")
  106.         conn.ConnectionString = "Driver={MySQL ODBC 5.1 Driver};Server=localhost;Database=wordpressdb;Uid=root;Pwd=password;Connect Timeout=1000;"
  107.         conn.Open()
  108.         rs = com.CreateObject("ADODB.RecordSet")
  109.         rs.open(" select * from wp_posts where id =  " + id, conn)
  110.        
  111.         while(! rs.eof){
  112.                 blog_info.title = rs ('post_title').value
  113.                 blog_info.content = rs ('post_content').value
  114.                 rs.movenext()
  115.         }
  116.         rs.close()
  117.         conn.close()
  118.         return blog_info
  119. }

  120. winform.show()
  121. win.loopMessage();
  122. return winform;
復(fù)制代碼
本站僅提供存儲服務(wù),所有內(nèi)容均由用戶發(fā)布,如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請點擊舉報。
打開APP,閱讀全文并永久保存 查看更多類似文章
猜你喜歡
類似文章
如何獲取程序內(nèi)鼠標的形狀特征碼?
圖形界面Aardio
新手教程:寫一個資源管理器
web.form 調(diào)用 Select2
aardio
[AAuto]給百寶箱增加娛樂功能
更多類似文章 >>
生活服務(wù)
分享 收藏 導(dǎo)長圖 關(guān)注 下載文章
綁定賬號成功
后續(xù)可登錄賬號暢享VIP特權(quán)!
如果VIP功能使用有故障,
可點擊這里聯(lián)系客服!

聯(lián)系客服