Click here to Skip to main content
15,884,629 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Jquey fonction not working
C#
<script src="Scripts/jquery-1.4.1.js" type="text/javascript"></script>
<script type="text/javascript">
function myFunction(filename) {
            $.ajax({
                type: "GET",
                url: "Location\\"+filename+".xml",
                dataType: "xml",
                success: function (xml) {
		       alert("yes");
            }
</script>


it it doesn't work
Posted
Updated 30-Jul-14 21:06pm
v2
Comments
Thanks7872 31-Jul-14 3:08am    
What do you mean by not working? you have to update the question and elaborate the issue.
breab 31-Jul-14 4:29am    
my problem is the the code in the success part is not executing
Kumarbs 31-Jul-14 3:11am    
Please provide what is your expectation and what it returns. Elaborate the issue, so that it is easy to provide the solution
breab 31-Jul-14 4:29am    
my problem is the the code in the success part is not executing
Kumarbs 31-Jul-14 4:49am    
Did you find any exception in the browser console screen?

1 solution

I can see 4 open brackets But only three close brackets.
Can't see a close bracket for
$.ajax(
 
Share this answer
 
v2
Comments
Raje_ 31-Jul-14 7:04am    
Good catch, my +5 and also would like to add need to make sure "Location\\"+filename+".xml" file is available.
Gihan Liyanage 31-Jul-14 7:25am    
What do you meant by Location? is it a folder in your directory ? how , if you give it with" ~ " ???
Like "~\\Location\\"+filename+".xml"

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900