Changeset 24136


Ignore:
Timestamp:
06/09/11 15:52:11 (10 years ago)
Author:
sjb48
Message:

Saving of the format statement to the collectionConfig is now possible. The bug with select boxes where the selected item was not saved has now been fixed.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/web/interfaces/oran/js/gui_div.js

    r23551 r24136  
    22console.log("Loading gui_div.js\n");
    33
    4 var initialised_iframe = "false";
     4// var initialised_iframe = "false";
    55
    66function onTextChange(item, text)
    77{
     8    console.log("I have set "+item+".value to "+text);
    89    item.setAttribute("value",text);
     10}
     11
     12function onSelectChange(item)
     13{
     14    console.log("I have set "+item.value+".selected to selected");
     15    for (var i=0; i<item.options.length; i++)
     16    {
     17        if(item.selectedIndex == i)
     18            item.options[i].setAttribute("selected", "selected");
     19        else
     20            item.options[i].removeAttribute("selected");
     21    }
     22    //item.options[item.selectedIndex].selected = "selected";
     23    //item.setAttribute("selected","selected");
    924}
    1025
     
    8297        classifier_name = getSubstring(myurl, "&cl", "&");
    8398
    84     var post_url = "http://localhost:8080/greenstone3/format?a=f&sa=update&c=" + collection_name +"&s=" + service_name;
     99    var post_url = "http://localhost:8989/greenstone3/format?a=f&sa=update&c=" + collection_name +"&s=" + service_name;
    85100
    86101    if(classifier_name != null)
     
    107122        classifier_name = getSubstring(myurl, "&cl", "&");
    108123
    109     var post_url = "http://localhost:8080/greenstone3/format?a=f&sa=save&c=" + collection_name +"&s=" + service_name;
     124    var post_url = "http://localhost:8989/greenstone3/format?a=f&sa=save&c=" + collection_name +"&s=" + service_name;
    110125
    111126    if(classifier_name != null)
     
    329344    var CURRENT_SELECT_VALUE = "";
    330345
     346    /*
    331347    var iframe = document.getElementById('iframe');
    332348    var iframe_document = iframe.document;
     
    385401        initialised_iframe = "true";
    386402    }
     403    */
    387404
    388405    /*   
Note: See TracChangeset for help on using the changeset viewer.