0

I am confused about js file of jQuery which one i have downloaded just now.

downloaded a zipped folder contains a lot of folder and files inside it. How can i know which one js file exactly is for particular plugin?

Lets say, i have to downloaded for Dialog and i download from this page by selecting Model under Widget section. It downloads a zip folder and has many folder and files inside it.

Reporter
  • 3,547
  • 5
  • 28
  • 45
  • 2
    http://www.sencha.com/forum/archive/index.php/t-4886.html – sgokhales Jun 01 '11 at 10:51
  • The main files in such big archives are often labled with name of the plugin it self. If you find files with contains 'min' or 'pack' in their names, these are just compressed to reduced the download volume. The rest of the file are mostly special files for a particular example. For the others you have to answer the question yourself if you need or not don't need the files. – Reporter Jun 01 '11 at 11:02

6 Answers6

0

You have to look at the demos to see how they work and then go from there. This is like the Matrix. No one can tell you how jQuery UI works, you have to see if for yourself.

Also this is jQuery UI and not straight jQuery which is a single js file which you will find in the download.

Basically find out which stylesheets, js files you need, how to implement that (demos on the website will help with this) and then test it out on your own site.

Daniel Casserly
  • 3,442
  • 2
  • 26
  • 59
  • Thanks Daniel. yes i do the same whatever you suggest but sometimes it's bit confusing to differentiate between two files and it takes a lot of effort only in testing the files. anyway thanks for the reply. –  Jun 01 '11 at 10:58
0

As an alternative to download and host jQuery yourself, you can use googles cdn.

They serve a lot of different javascript frameworks, including jQuery and jQuery UI.

If you for example want to enable your site with jQuery all you structly have to do is include this in your html code:

<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script>

You can find the different js frameworks that they host on this page: http://code.google.com/intl/no/apis/libraries/devguide.html

netbrain
  • 8,694
  • 6
  • 37
  • 66
0

The thing that you have downloaded is JQUERYUI. Its a UI customisation and enhancement library based on the Jquery library. But you have specified in the question as JQUERY library. This can be downloaded here: jquery.com

Sujit Agarwal
  • 11,650
  • 10
  • 44
  • 76
0

When you've configured your download you just need to use the 2 folders: js and css.

You need to reference

jquery.js
jquery-ui-1.8.13.custom.min.js

jquery-ui-1.8.13.custom.css

I import this folder development-bundle\ui\i18n as well when I need the localized datetime-picker.

LeftyX
  • 34,522
  • 20
  • 128
  • 188
0

this post does a pretty nice job: jquery from cdn

They include a failsafe incase the CDN doesn't load properly...here's the code excerpt from the post

<!-- Grab Google CDN's jQuery, with a protocol relative URL; fall back to local if necessary -->
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js"></script>
<script>window.jQuery || document.write('<script src="js/libs/jquery-1.5.1.min.js">\x3C/script>')</script>

this could be modified for various plugins too, like jqueryUI

(also referenced from http://html5boilerplate.com/ as noted in linked post)

Community
  • 1
  • 1
Brett
  • 3,941
  • 2
  • 23
  • 38
0

Basically you have to include three things in the following order,

  1. jquery API placed under js folder(something like jquery-1.5.1.min.js)
  2. jquery UI library placed under js folder (something like jquery-ui-1.8.13.custom.min.js)
  3. jquery ui css file placed under css\ui-lightness folder (something like jquery-ui-1.8.13.custom.css).

You can even refer the first two js files from any CDN.

VJAI
  • 29,899
  • 20
  • 93
  • 155