-4

I want to use jquery in my web application. Should I include it as a link in my external JavaScript file or inside my html file?

Thanks in advance

2 Answers2

1

No. The way to include a javascript file is using <script src="file.js"></script>

The contents of file.js should not be surrounded with <script> tags as that is html code.

Duncan Cowan
  • 495
  • 3
  • 12
0

Yea sorry i was mistaken, didn't think external javascript counts but apperantly it does.

<script src="myScript.js"> code in here </script>
Altay Mazlum
  • 442
  • 5
  • 15