How can I use the external JavaScript in Facebook application development?
Actually I want to use the Ajax tab feature in my application.
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.
Hai vipinsahu,
If you want to embed an external .js file, you’ll have to specify the absolute path. Not only: Facebook will keep a copy of your script, even if you modify it, so you’ll have to put a timestamp in the url to force a cache refresh.
For example, if you want to embed a script in your index.phtml:
n this way Facebook will load the script from the url: http://www.yourserver.com/fbapp/scripts/js.js?v=1231707071.
When you’ll edit the file, the number will change and FB will reload it.
for ref see this embed an external .js file in a facebook application