Once I do $("#obj").load(url) is there a way to get the loaded url from #obj ?
Once I do $(#obj).load(url) is there a way to get the loaded url from
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
That code will just load the contents of
#objin the DOM using the results of a call tourl. jQuery will not store the url anywhere. But you can manually store the data and attach it to the dom object usingdata(). Like this:You can then later retrieve the url like this:
See http://api.jquery.com/data/ for details.