summaryrefslogtreecommitdiff
path: root/functions.js
diff options
context:
space:
mode:
authorCraig Meyer <[email protected]>2011-08-11 18:51:00 -0400
committerAndrew Dolgov <[email protected]>2011-08-23 12:49:18 +0400
commit147f5632281b0da6f4232b5d8f4e6998ebf1e40b (patch)
tree27abbbe036c7ad5e324482f615fcf0b6f472c1c3 /functions.js
parent8efb5f62e86fd0c11147aec979733a33ade53756 (diff)
Extended Actions to include Select by tag (add local modifications, fix
display for tags starting with a number)
Diffstat (limited to 'functions.js')
-rw-r--r--functions.js50
1 files changed, 50 insertions, 0 deletions
diff --git a/functions.js b/functions.js
index e8bd6af33..1a06a9bf3 100644
--- a/functions.js
+++ b/functions.js
@@ -1619,4 +1619,54 @@ function showFeedsWithErrors() {
}
+/* new support functions for SelectByTag */
+function get_all_tags(selObj){
+ try {
+ if( !selObj ) return "";
+
+ var result = "";
+ var len = selObj.options.length;
+
+ for (var i=0; i < len; i++){
+ if (selObj.options[i].selected) {
+ result += selObj[i].value + "%2C"; // is really a comma
+ }
+ }
+
+ if (result.length > 0){
+ result = result.substr(0, result.length-3); // remove trailing %2C
+ }
+
+ return(result);
+
+ } catch (e) {
+ exception_error("get_all_tags", e);
+ }
+}
+
+function get_radio_checked(radioObj) {
+ try {
+ if (!radioObj) return "";
+
+ var len = radioObj.length;
+
+ if (len == undefined){
+ if(radioObj.checked){
+ return(radioObj.value);
+ } else {
+ return("");
+ }
+ }
+
+ for( var i=0; i < len; i++ ){
+ if( radioObj[i].checked ){
+ return( radioObj[i].value);
+ }
+ }
+
+ } catch (e) {
+ exception_error("get_radio_checked", e);
+ }
+ return("");
+}