Blame view

static/js/application.js 468 Bytes
ffd3b3723   Killian   idem
1
2
3
4
5
6
7
8
9
  // Some general UI pack related JS
  $(document).ready(function() {
  	tagging();
  });
  
  
  
  function tagging(){
  $('#go').click(function(){
7ff5cc7f9   Killian   edit raw text + c...
10
  	data={"string" :$('#data').val()};
ffd3b3723   Killian   idem
11
12
13
14
15
16
  	console.log(data);
  	$.ajax({
  		type: "POST",
  		url: "tagger",
  		data: data,
  		success: function(data){
ffd3b3723   Killian   idem
17
  			result=$('#result');
b3cdd2e74   Killian   Ajout de Orkis pr...
18
  			result.html(_.escape(data));
ffd3b3723   Killian   idem
19
20
21
22
23
24
  			console.log(_.escape(data));
  			console.log("resultat");
  		},
  		error: function(){
  			alert("error");
  		},
7ff5cc7f9   Killian   edit raw text + c...
25
  		dataType: "text"
ffd3b3723   Killian   idem
26
27
28
  	});
  });
  }