]> 91.132.146.200 Git - insipid.git/commitdiff
FF_EXT: Cleaned up some old and redundant js lines - Fixed a bug in tags suggestion...
authordannym <dannymiles2@gmail.com>
Sun, 4 Apr 2010 22:12:48 +0000 (00:12 +0200)
committerdannym <dannymiles2@gmail.com>
Sun, 4 Apr 2010 22:12:48 +0000 (00:12 +0200)
ff_ext/inspd@danny/chrome/inspd/content/v2/altpost/altpost_trigger.js

index db716e9851b52ebe938ff40acc28417f0e5120e1..8f69d2e3d5692aef9f63edf3e7882077e895e899 100644 (file)
@@ -141,31 +141,22 @@ var $altp = {
        scrap_tagPop : function(){\r
                try{\r
                var txtTagsObj = 'tagPop = [';\r
-               //var tagsfromtbl = document.evaluate("//div[@class='alphacloud']",document,null,XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,null).snapshotItem(0);\r
-                var tagsfromtbl = document.evaluate("//span[@class='m']",document,null,XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,null);\r
                // hidden_span_Inspd_delintegrate_commontags_found_1\r
                var tagsfromtbl = document.evaluate("//span[@id='hidden_span_Inspd_delintegrate_commontags_found_1']",document,null,XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,null);\r
                \r
                \r
                //alert(tagsfromtbl.snapshotLength);\r
-               \r
-               // var j = tagsfromtbl.getElementsByTagName('a').length ;\r
-               //var j = tagsfromtbl.snapshotLength ; \r
+               //alert(tagsfromtbl.snapshotItem(0).innerHTML);\r
                \r
                var tagsfromtbl_all_anchors = tagsfromtbl.snapshotItem(0).getElementsByTagName('span') ; \r
                var j = tagsfromtbl_all_anchors.length ;\r
-               //alert(j);\r
-               \r
                \r
                if (j == 0 ){\r
                        var txtTagsObj = 'Inspd_delintegrate_commontags_found = 2';\r
                        return txtTagsObj; \r
                }\r
                for(var i = 0;i<j;i++){\r
-                               //tagsfromtbl.getElementsByTagName('a')[i].setAttribute('onclick','swap(this.innerHTML);return false;');\r
-                               //txtTagsObj +='"'+(tagsfromtbl.getElementsByTagName('a')[i].innerHTML).toLowerCase()+'"';\r
-                               ////////////////txtTagsObj +='"'+((tagsfromtbl.snapshotItem(i).innerHTML).replace(/<em>(.*)<\/em>/,'')).toLowerCase()+'"';\r
-                               txtTagsObj +='"'+((tagsfromtbl_all_anchors[i].innerHTML).replace(/<em>(.*)<\/em>/,'')).toLowerCase()+'"';\r
+                               txtTagsObj +='"'+$utils.trim(tagsfromtbl_all_anchors[i].title.replace(/\((.*)\)/,'')).toLowerCase()+'"';\r
                                if (i < j-1 ){txtTagsObj += ',';}\r
                }\r
                txtTagsObj += ']';\r