3Talks 港人自講討論區 » Xanga & MSN Space 部落格專區 » 【xanga】Xanga Entry Auto Privater(自動幫你 Private 所有 posts)


2006-9-12 02:28 PM [kae′]
【xanga】Xanga Entry Auto Privater(自動幫你 Private 所有 posts)

[code]
<script>
/***********************************************************************************\
*  A xanga widget to Change all posts(excluding protected posts) to private posts. *
*  It takes some time to finish if you got load of posts.                          *
*  Options:                                                                        *
*   1 --> Private all posts(exclude protected posts);                              *
*   2 --> Public all posts(exclude protected posts);                               *
*   3 --> DO NOT run the script                                                    *
*                                                              cychoi (07/04/2006) *
\***********************************************************************************/

Options = 1;

var cURL = document.URL.toLowerCase();
var key = (Options==1)?"Public":(Options==2)?"Private":false;
if(cURL.indexOf("/private/") > 0 && key != false) {
   var Ass = document.getElementsByTagName("A");
   for(var i=0; i<Ass.length; i++) {
      if(Ass[i].href.indexOf("entryprivacy.aspx") > 0 && Ass[i].innerHTML == key) {
         window.location.href = Ass[i].href;
         break;
      } else if(Ass[i].href.indexOf("&direction=n") > 0 && Ass[i].href.indexOf("nextdate=") > 0) {
         window.location.href = Ass[i].href;
         break;
      }
   }
}
</script>
[/code]

放係 Look & Feel 的 Web Stat。

Note 1: Remove this code from your Xanga after you've finished.You can now set "Options = 3" to disable the script.
Note 2: After installing this code, your "private home" page seems loading indefinitely, howerver, this's normal and please wait until it's reached the last page.

2007-8-4 11:44 PM dc2507
thx for ur sharing

頁: [1]


Powered by Discuz! Archiver 5.5.0  © 2001-2006 Comsenz Inc.