home *** CD-ROM | disk | FTP | other *** search
/ PC World 2007 November / PCWorld_2007-11_cd.bin / temacd / bitcomet / BitComet_0.93_setup.exe / scripts / refer_skycn.lua < prev    next >
Text File  |  2007-05-17  |  324b  |  13 lines

  1. local function f(url)
  2.     local url_pattern = "%s*http://.-%.skycn%.com/"
  3.     local rand = math.random(1, 5000);
  4.     local cookie = nil
  5.     if nil == string.find(url, url_pattern) then 
  6.         return nil, cookie
  7.     else
  8.         return "http://www.skycn.com/soft/".. rand .. ".html", cookie
  9.     end
  10. end
  11.  
  12. referer_table["refer_skycn.lua"] = f
  13.