Changeset 4348
- Timestamp:
- 09/17/07 09:27:00 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
sandbox/jachym/openlayers/lib/OpenLayers/Control/WPS.js
r4303 r4348 26 26 xmlhttp: null, 27 27 28 // DOM Elements29 28 30 29 /** … … 277 276 this.showControls(true); 278 277 279 if (this.inputform) {278 /*if (this.inputform) { 280 279 this.inputform.parentNode.removeChild(this.inputform); 281 280 this.inputform = null; … … 285 284 this.wpsform = null; 286 285 } 286 */ 287 287 288 288 if (e) { … … 701 701 document.createTextNode(inputs[i].getElementsByTagName("Title")[0].firstChild.nodeValue+ ": ")); 702 702 lbl.style.width = (parseInt(this.WPS.inputSize,10)/2)+"px"; 703 // TODO onmousein/onmouseout display abstr 704 705 706 // create description floating div 707 try { 708 abstr = document.createElement("div"); 709 abstr.style.background = "navy"; 710 abstr.style.boder = "solid 1px white"; 711 abstr.appendChild(document.createTextNode( 712 inputs[i].getElementsByTagName("Abstract")[0].firstChild.nodeValue)); 713 abstr.style.width = "150px"; 714 abstr.style.display = "none"; 715 abstr.id = "wps_abstr_"+inputs[i].getElementsByTagName("Identifier")[0].firstChild.nodeValue; 716 } 717 catch (e) {} 703 718 704 719 this.WPS.inputform.appendChild(lbl); … … 786 801 this.WPS.xmlhttp = this.WPS.makeXmlHttp(); 787 802 this.WPS.xmlhttp.onreadystatechange = this.WPS.execute; 788 this.WPS.xmlhttp.open("POST",this.WPS.server,true); 803 var uri = OpenLayers.ProxyHost ? OpenLayers.ProxyHost + escape(this.WPS.server) : this.WPS.server; 804 this.WPS.xmlhttp.open("POST",uri,true); 789 805 this.WPS.xmlhttp.send(this.WPS.executeRequest); 790 806 791 807 }, 792 808 809 /** 810 * Method: execute 811 * Called, when "Execute" button clicked 812 * 813 */ 793 814 execute: function() { 794 815 if (this.WPS.xmlhttp.readyState == 4) { … … 797 818 this.WPS.parseExecuteResponse(this.WPS.xmlhttp); 798 819 } 799 } 800 }, 801 802 820 else if (this.WPS.xmlhttp.status==404) { 821 } 822 } 823 else if (this.WPS.xmlhttp.readyState == 3) { 824 } 825 }, 826 827 828 /** 829 * Method: parseExecuteResponse 830 * Tryes to parse response of the Execute request 831 * 832 * Parameters: xmlhttp response 833 */ 803 834 parseExecuteResponse: function(response) { 804 835 … … 855 886 }, 856 887 888 /** 889 * Method: makeXmlHttp 890 * We need our own xmlhttp object, since we are using HTTP POST and 891 * other custom features 892 * 893 * Parameters: 894 */ 857 895 makeXmlHttp: function () { 858 896 var xmlHttp;
