Commit 4f15cb6647c96424622033c677cf742dc463480b

  • avatar
  • Ajay <ajay @serv…ots.com>
  • Thu Jan 12 18:53:36 IST 2012
Jquery implemented & both audio/text can upload for same div
  
17991799 source: function(req, add){
18001800
18011801 //pass request to server
1802 $.getJSON("http://localhost/getData?", req, function(data) {
1802 $.getJSON("http://dev.a11y.in/getData?", req, function(data) {
18031803
18041804 //create array for response objects
18051805 var suggestions = [];
18231823 source: function(req, add){
18241824
18251825 //pass request to server
1826 $.getJSON("http://localhost/getLang?", req, function(data) {
1826 $.getJSON("http://dev.a11y.in/getLang?", req, function(data) {
18271827
18281828 //create array for response objects
18291829 var suggestions = [];
21782178 }
21792179 }
21802180 }
2181 xmlhttp.open("POST","http://localhost/narration",true);
2181 xmlhttp.open("POST","http://dev.a11y.in/narration",true);
21822182 xmlhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded");
21832183 xmlhttp.send(data);
21842184
31563156 break;
31573157
31583158 case 'AUDIO_CREATE':
3159 brk = document.createElement("br");
31593160 audioElement = document.createElement('audio');
3161 audioElement.setAttribute("id", "audiotag");
31603162 audioElement.setAttribute('src',command.data);
31613163 audioElement.setAttribute('controls','controls');
3162 selectedElement.appendChild(audioElement);
3163 audioElement.play();
3164 $(brk).insertBefore("#alipiSelectedElement");
3165 $(audioElement).insertBefore($(brk));
31643166 pageEditor.showMessage('Audio added');
31653167 break;
31663168
32333233 if(document.getElementById('our-check').checked)
32343234 {
32353235 localStorage.myContent = buildDataString();
3236 window.location.href = "http://localhost/test.html";
3236 window.location.href = "http://dev.a11y.in/test.html";
32373237 window.reload();
32383238 }
32393239 else{
32403240
3241 AJAX.post('http://localhost/test', buildDataString(), function(result) {
3241 AJAX.post('http://dev.a11y.in/test', buildDataString(), function(result) {
32423242 ajaxResultProcessor.processPublishedResponse(result);
32433243 });
32443244 }