0

Am trying to send some a value i.e. fileShareName to Servlet through this code but am unable to send it .Please guide me ..
Here is am having the code :

function shareFileName(){
    var fileShareName = $('#newpathlocation').find(":selected").text();
    row = "";
    $
            .ajax({
                url : '../directory',
                type : 'POST',
                data : {'fileName' : fileShareName},
                datatype : String,
                beforeSend: function( fileShareName ){},
                success : function(fileShareName) {
                        alert("Success");
                    },
                error : function(fileShareName) {
                    alert("Error");
                }
            });

}
Thilo
  • 257,207
  • 101
  • 511
  • 656
Theodore
  • 57
  • 1
  • 7

0 Answers0