From 47d5bce2dacce3f9f3392acbdebb1eda343650ad Mon Sep 17 00:00:00 2001 From: Jocki Hendry Date: Sun, 23 Dec 2012 13:01:13 +0700 Subject: [PATCH] Add jQuery-1.8.3.sdocml --- README.txt | 256 ++ jquery-1.8.3.sdocml | 6350 +++++++++++++++++++++++++++++++++++++++++++ license.html | 751 +++++ 3 files changed, 7357 insertions(+) create mode 100644 README.txt create mode 100644 jquery-1.8.3.sdocml create mode 100644 license.html diff --git a/README.txt b/README.txt new file mode 100644 index 0000000..3a9fdbf --- /dev/null +++ b/README.txt @@ -0,0 +1,256 @@ +License +------- + +This program Copyright (c) 2005-2011 by Appcelerator, Inc. This program is distributed under the GNU General Public license. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, Version 3, as published by the Free Software Foundation. + +Any modifications must keep this entire license intact. + +----------------------------------------------------------------------- + +GNU General Public License +Version 3, 29 June 2007 + +Copyright (C) 2007 Free Software Foundation, Inc. http://fsf.org/ + +Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. +Preamble + +The GNU General Public License is a free, copyleft license for software and other kinds of works. + +The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too. + +When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. + +To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others. + +For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. + +Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. + +For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. + +Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users. + +Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free. + +The precise terms and conditions for copying, distribution and modification follow. + +TERMS AND CONDITIONS + +0. Definitions. + +"This License" refers to version 3 of the GNU General Public License. + +"Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. + +"The Program" refers to any copyrightable work licensed under this License. Each licensee is addressed as "you". "Licensees" and "recipients" may be individuals or organizations. + +To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work. + +A "covered work" means either the unmodified Program or a work based on the Program. + +To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. + +To "convey" a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. + +An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. +1. Source Code. + +The "source code" for a work means the preferred form of the work for making modifications to it. "Object code" means any non-source form of a work. + +A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. + +The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. + +The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. + +The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. + +The Corresponding Source for a work in source code form is that same work. + +2. Basic Permissions. + +All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. + +You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. + +Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. + +3. Protecting Users' Legal Rights From Anti-Circumvention Law. + +No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. + +When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. + +4. Conveying Verbatim Copies. + +You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. + +You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. + +5. Conveying Modified Source Versions. + +You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: + + * a) The work must carry prominent notices stating that you modified it, and giving a relevant date. + * b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to "keep intact all notices". + * c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. + * d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. + +A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. +6. Conveying Non-Source Forms. + +You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: + + * a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. + * b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. + * c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. + * d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. + * e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. + +A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. + +A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. + +"Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. + +If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). + +The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. + +Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. + +7. Additional Terms. + +"Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. + +When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. + +Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: + + * a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or + * b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or + * c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or + * d) Limiting the use for publicity purposes of names of licensors or authors of the material; or + * e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or + * f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. + +All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. + +If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. + +Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. + +8. Termination. + +You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). + +However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. + +Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. + +Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. + +9. Acceptance Not Required for Having Copies. + +You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. + +10. Automatic Licensing of Downstream Recipients. + +Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. + +An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. + +You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. + +11. Patents. + +A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's "contributor version". + +A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. + +Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. + +In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. + +If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. + +If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. + +A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. + +Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. + +12. No Surrender of Others' Freedom. + +If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. + +13. Use with the GNU Affero General Public License. + +Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. + +14. Revised Versions of this License. + +The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation. + +If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. + +Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. + +15. Disclaimer of Warranty. + +THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + +16. Limitation of Liability. + +IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +17. Interpretation of Sections 15 and 16. + +If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. + +END OF TERMS AND CONDITIONS + +----------------------------------------------------------------------- + +Appcelerator GPL Exception +Section 7 Exception + +As a special exception to the terms and conditions of the GNU General Public License Version 3 (the "GPL"): You are free to convey a modified version that is formed entirely from this file (for purposes of this exception, the "Program" under the GPL) and the works identified at http://www.aptana.com/legal/gpl (each an "Excepted Work"), which are conveyed to you by Appcelerator, Inc. and licensed under one or more of the licenses identified in the Excepted License List below (each an "Excepted License"), as long as: + + 1. you obey the GPL in all respects for the Program and the modified version, except for Excepted Works which are identifiable sections of the modified version, which are not derived from the Program, and which can reasonably be considered independent and separate works in themselves, + 2. all Excepted Works which are identifiable sections of the modified version, which are not derived from the Program, and which can reasonably be considered independent and separate works in themselves, + 1. are distributed subject to the Excepted License under which they were originally licensed, and + 2. are not themselves modified from the form in which they are conveyed to you by Aptana, and + 3. the object code or executable form of those sections are accompanied by the complete corresponding machine-readable source code for those sections, on the same medium as the corresponding object code or executable forms of those sections, and are licensed under the applicable Excepted License as the corresponding object code or executable forms of those sections, and + 3. any works which are aggregated with the Program, or with a modified version on a volume of a storage or distribution medium in accordance with the GPL, are aggregates (as defined in Section 5 of the GPL) which can reasonably be considered independent and separate works in themselves and which are not modified versions of either the Program, a modified version, or an Excepted Work. + +If the above conditions are not met, then the Program may only be copied, modified, distributed or used under the terms and conditions of the GPL or another valid licensing option from Appcelerator, Inc. Terms used but not defined in the foregoing paragraph have the meanings given in the GPL. + +----------------------------------------------------------------------- + +Excepted License List + + * Apache Software License: version 1.0, 1.1, 2.0 + * Eclipse Public License: version 1.0 + * GNU General Public License: version 2.0 + * GNU Lesser General Public License: version 2.0 + * License of Jaxer + * License of HTML jTidy + * Mozilla Public License: version 1.1 + * W3C License + * BSD License + * MIT License + * Aptana Commercial Licenses + +This list may be modified by Appcelerator from time to time. See Appcelerator's website for the latest version. + +----------------------------------------------------------------------- + +Attribution Requirement + +This license does not grant any license or rights to use the trademarks "Aptana," any "Aptana" logos, or any other trademarks of Appcelerator, Inc. You are not authorized to use the name Aptana or the names of any author or contributor for publicity purposes, without written authorization. + +However, in addition to the other notice obligations of this License, all copies of any covered work conveyed by you must include on each user interface screen and in the Appropriate Legal Notices the following text: "Powered by Aptana". On user interface screens, this text must be visibly and clearly displayed in the title bar, status bar, or otherwise directly in the view that is in focus. diff --git a/jquery-1.8.3.sdocml b/jquery-1.8.3.sdocml new file mode 100644 index 0000000..475ffea --- /dev/null +++ b/jquery-1.8.3.sdocml @@ -0,0 +1,6350 @@ + + + + + + + + + + + + Accepts a string containing a CSS selector which is then used to match a set of elements. + + + A string containing a selector expression + + + + + + + Find all div elements + $("div", xml.responseXML); + + + + + + Accepts a string containing a CSS selector which is then used to match a set of elements. + + + A string containing a selector expression + + + A DOM Element, Document, or jQuery to use as context + + + + + + + Find all div elements within an XML document from an Ajax reponse. + $("div", xml.responseXML); + + + + + At present, the only operations supported on plain JavaScript objects wrapped in jQuery are: +.data(), .prop(), .bind(), .unbind(), .trigger() and .triggerHandler(). + + + A plain object to wrap in a jQuery object. + + + + + + + Define a plain object, wrap it with jQuery, and test accesing property values. + var foo = {foo:'bar', hello:'world'}; + var $foo = $(foo); + var test1 = $foo.prop('foo'); + + + + + Accepts an array containing a set of DOM elements to wrap in a jQuery object. + + + An array containing a set of DOM elements to wrap in a jQuery object. + + + + + + + + + Calling the jQuery() method with no arguments returns an empty jQuery set (with a .length property of 0). + + + + + + + Creates DOM elements on the fly from the provided string of raw HTML. + + + A string of HTML to create on the fly. Note that this parse HTML, not XML. + + + A document in which the new elements will be created + + + + + + + Create a div element (and all of its contents) dynamically and append it to the body element. + $("<div><p>Hello</p></div>").appendTo("body"); + + + + + Creates DOM elements on the fly from the provided string of raw HTML. + + + A string defining a single, standalone, HTML element (e.g. <div/> or <div></div>). + + + An map of attributes, events, and methods to call on the newly-created element. + + + + + + + Create some DOM elements. + $("<div/>", { + "class": "test", + text: "Click me!", + click: function() { + $(this).toggleClass("test"); + } + }).appendTo("body"); + + + + + + + + + The DOM node context originally passed to jQuery(). + + Determine the exact context used. + $("ul").append("<li>" + $("ul").context + "</li>") + .append("<li>" + $("ul", document.body).context.nodeName + "</li>"); + + + + + Hook directly into jQuery to override how particular CSS properties are retrieved or set. + + + (function($) { + // first, check to see if cssHooks are supported + if (!$.cssHooks) { + throw("jQUery 1.4.3 or above is required"); + return; + } + $.cssHooks["someCSSProp"] = { + get: function(elem, computed, extra) { + // handle getting the CSS propety + }, + set: function(elem, value) { + // handle setting the CSS value + } + }; + })(jQuery); + + + + + fx is a global jQuery object. + + + + A string containing the jQuery version number. + + + + The number of elements in the jQuery object. + + + + A collection of properties that represent the presence of different browser features or bugs. +Primarily intended for jQuery's internal use; specific properties may be removed when they are no longer needed internally +to improve page startup performance. + + + + + + + + Add elements to the set of matched elements. + + + A string representing a selector expression to find additional elements or HTML fragment to add to the set of matched elements. + + + + + + + Add <div> into <p> and save it to a variable: + var pdiv = $("p").add("div"); + + + + + Add elements to the set of matched elements. + + + One or more elements to add to the set of matched elements. + + + + + + + + + Add elements to the set of matched elements. + + + An existing jQuery object to add to the set of matched elements. + + + + + + + + + Add elements to the set of matched elements. + + + A string representing a selector expression to find additional elements to add to the set of matched elements. + + + The point in the document at which the selector should begin matching; similiar to the context argument of the $(selector, context) method. + + + + + + + + + Adds the specified class(es) to each of the set of matched elements. + + + One or more class names to be added to the class attribute of each matched element. + + + + + + + More than one class may be added at a time, separated by a space, to the set of matched elements, like so: + $("p").addClass("myClass yourClass"); + + + + + Adds the specified class(es) to each of the set of matched elements based on a function return value. +The function receives the index position of the element in the set and the existing class name(s) as +arguments. Within the function, this refers to the current element in the set. + + + function(index, currentClass) is a function returning one or more space-separated class names<br> +to be added to the existing class name(s). Receives the index position of the element <br> +in the set and the existing class name(s) as arguments. Within the function, <br> +this refers to the current element in the set. + + + + + + + Given an unorderer list with five <li> elements, this example add the class "item-4" to the last <li>: + $("ul li:last").addClass(function(index) { + return "item-" + index; + }); + + + + + Insert content, specified by the parameter, after each element in the set of matched elements. + + + HTML string, DOM element, or jQuery object to insert after each element in the set of matched elements. + + + One or more additional DOM elements, arrays of elements, HTML strings, or jQuery objects to insert after each element in the set of matched elements. + + + + + + + Insert some HTML after all paragraphs. + $("p").after("<b>Hello</b>"); + + + + + Insert content, specified by a function, after each element in the set of matched elements. The parameter function +receives the index position of the element in the set as an argument. Within the function, this refers to the current element in the set. + + + function(index) is a function that returns an HTML string, DOM element(s), or jQuery object <br> +to insert after each matched element. Receives the index position of the element in the set as an argument.<br> +Within the function, this refers to the current element in the set. + + + + + + + Given an unorderer list with five <li> elements, this example add the class "item-4" to the last <li>: + $("ul li:last").addClass(function(index) { + return "item-" + index; + }); + + + + + Perform an asynchronous HTTP (Ajax) request. + + + A string containing the URL to which the request is sent. + + + A set of key/value pairs that configure the Ajax request. + + + + + + + Save some data to the server and notify the user once it's complete. + $.ajax({ + type: "POST", + url: "some.php", + data: {name: "John", location: "Boston"} + }).done(function(msg) { + alert("Data Saved: " + msg); + }); + + + + + Perform an asynchronous HTTP (Ajax) request. + + + A set of key/value pairs that configure the Ajax request. All settings are optional. + + + + + + + Specifying a DOM element as the context will make that the context for the complete callback of a request, like so: + $.ajax({ + url: "test.html", + context: document.body + }).done(function(){ + $(this).addClass("done"); + }); + + + + + Register a handler to be called when Ajax requests complete. This is an Ajax Event. + + + handler(event, XMLHttpRequest, ajaxOptions) is the function to be invoked. + + + + + + + Show a message when an Ajax request completes. + $("#msg").ajaxComplete(function(event, request, settings) { + $(this).append("<li>Request Complete.</li>"); + }); + + + + + Register a handler to be called when Ajax requests complete with an error. This is an Ajax Event. + + + handler(event, jqXHR, ajaxSettings, thrownError) The function to be invoked. + + + + + + + Show a message when an Ajax request fails. + $("#msg").ajaxError(function(event, request, settings) { + $(this).append("<li>Error requesting page " + settings.url + "</li>"); + }); + + + + + Handle custom Ajax options or modify existing options before each request is sent and before they are processed by $.ajax(). + + + An optional String containing one or more space-separated dataTypes. + + + handler(options, originalOptions, jqXHR) A handler to set default values for future Ajax requests. + + + + Proxies cross-domain request through http://mydomain.net/proxy/: + $.ajaxPrefilter(function(options) { + if (options.crossDomain) { + options.url = "http://mydomain.net/proxy/" + encodeURIComponent(options.url); + options.crossDomain = false; + } + }); + + + + + Attach a function to be executed before an Ajax request is sent. This is an Ajax Event. + + + handler(event, jqXHR, ajaxOptions) The function to be invoked. + + + + + + + Show a message before an Ajax request is sent. + $("#msg").ajaxSend(function(evt, request, settings) { + $(this).append("<li>Starting request at " + settings.url + "</li>"); + }); + + + + + Set default values for future Ajax requests. + + + A set of key/value pairs that configure the default Ajax request. All options are optional. + + + + Set the defaults for Ajax requests to the url "/xmlhttp/", +disables global handlers and uses POST instead of GET. +The following Ajax requests then sends some data without having to set anything else. + $.ajaxSetup({ + url: "/xmlhttp", + global: false, + type: "POST" + }); + $.ajax({data: myData}); + + + + + Register a handler to be called when the first Ajax request begins. This is an Ajax event. + + + handler() is the function to be invoked. + + + + + + + Show a loading message whenever an Ajax request starts (and none is already active). + $("#loading").ajaxStart(function() { + $(this).show(); + }); + + + + + Register a handler to be called when all Ajax requests have completed. This is an Ajax event. + + + handler() is the function to be invoked. + + + + + + + Hide a loading message after all the Ajax requests have stopped. + $("#loading").ajaxStop(function() { + $(this).hide(); + }); + + + + + Attach a function to be executed whenever an Ajax request completes successfully. This is an Ajax Event. + + + handler(event, XMLHttpRequest, ajaxOptions) The function to be invoked. + + + + + + + Show a message when an Ajax request completes successfully. + $("#msg").ajaxSuccess(function(evt, request, settings) { + $(this).append("<li>Successful Request!</li>"); + }); + + + + + Add the previous set of elements on the stack to the current set. + + + + + Find all divs, and all the paragraphs inside of them, and give them bot class names. + $("div").find("p").andSelf().addClass("border"); +Notice the div doesn't have the yellow backgroud color since it didn't use .andSelf(): + $("div").find("p").addClass("background"); + + + + + Perform a custom animation of a set of CSS properties + + + + + + A map of CSS properties that the animation will move toward. + + + A string or number determininmg how long the animation will run. + + + A string indicating which easing function to use for the transition. + + + A function to call once the animation is complete. The callback is not sent any <br> +arguments, but this is set to the DOM element being animated. + + + + + $("#go").click(function() { + $("#block").animate({ + width: "70%", + marginLeft: "0.6in", + }, 1500); + }); + + $("#right").click(function() { + $(".block").animate({"left": "+=50px"}, "slow"); + }); + + + + + Perform a custom animation of a set of CSS properties. + + + + + + A map of CSS properties that the animation will move toward. + + + A map of additional options to pass to the method. + + + + + $("#clickme").click(function() { + $("#book").animate({ + width: 'toggle', + height: 'toggle' + }, { + duration: 6000, + specialEasing: { + width: 'linear', + height: 'easeOutBounce' + }, + complete: function() { + $(this).after('<div>Animation complete.</div>'); + } + }); + }); + + + + + + Insert content, specified by the parameter, to the end of each element in the set of matched elements. + + + + + + DOM element, HTML string, or jQuery object to insert at the end of matched elements. + + + One or more additional DOM element, array of elements, HTML strings, or jQuery objects to insert at the end of matched elements. + + + + Appends some HTML to all paragraphs. + $("p").append("<strong>Hello</strong>"); + + + + + Insert content, specified by the parameter, to the end of each element in the set of matched elements. + + + + + + function(index, html) is a function that returns an HTML string, DOM element(s), or jQuery object<br> +to insert at the end of each matched elements. + + + + + + Insert every element in the set of matched elements to the end of the target. + + + + + + A selector, element, HTML string, or jQuery object; matched set of elements will be inserted at the end of this parameter. + + + + Appends all spans to the element with the ID "foo" + $("span").appendTo("#foo"); + + + + + Get the value of an attribute for the first element in the set of matched elements. + + + + + + The name of the attribute to get. + + + + Find the title attribute of the first <em> in the page. + var title = $("em").attr("title"); + + + + + Set one or more attributes for the set of matched elements. + + + + + + The name of the attribute to set. + + + A value to set for the attribute. + + + + To change the alt attribute. + $('#greatphoto').attr('alt', 'Beijing Brush Seller'); + + + + + Set one or more attributes for the set of matched elements. + + + + + + A map of attribute-value pairs to set. + + + + + $('#greatphoto').attr({ + alt: 'Beijing Brush Seller', + title: 'photo by Kelly Clark' + }); + + + + + Set one or more attributes for the set of matched elements. + + + + + + The name of the attribute to set. + + + function(index, attr) is a function returning the value to set.<br> +this is the current element. Receives the index position of the element<br> +in the set and the old attribute value as arguments. + + + + + $('#greatphoto').attr('title', function(i, val) { + return val + ' - photo by Kelly Clark' + }); + + + + + Insert content, specified by the parameter, before each element in the set of matched elements. + + + + + + HTML string, DOM element, or jQuery object to insert before each matched elements. + + + One or more additional DOM elements, arrays of elements, HTML strings, or jQuery objects to insert before each matched elements. + + + + Insert some HTML before all paragraphs. + $("p").before("<b>Hello</b>"); + + + + + Insert content, specified by the parameter, before each element in the set of matched elements. + + + + + + A function that returns an HTML string, DOM element(s), or jQuery object to insert before <br> +each matched elements. Receives the index position of the element in the set as an argument.<br> +Within the function, this refers to the current element in the set. + + + + + + Attach a handler to an event for the elements. + + + + + + A string containing one or more DOM event types, such as "click" or "submit". + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. Within the handler,<br> +this refers to the DOM element to which the handler is bound. + + + + Handle click and double-click for the paragraph. + $("p").bind("click", function(event) { + var str = "(" + event.pageX + ", " + event.pageY + " )"; + $("span").text("Click happened! " + str); + }); + $("p").bind("dblclick", function() { + $("span").text("Double-click happened in " + this.nodeName); + }); + + + + + Attach a handler to an event for the elements. + + + + + + A string containing one or more DOM event types, such as "click" or "submit". + + + A map of data that will be passed to the event handler. + + + Setting the third arguments to false will attach a function that prevents the default action from occuring and stops the event from bubbling. + + + + + + Attach a handler to an event for the elements. + + + + + + A map of one or more DOM event types and functions to execute for them. + + + + Bind multipe event handlers simultaneously. + $('#foo').bind({ + click: function() { // do something on click }, + mouseenter: function() { // do something on mouseenter } + }); + + + + + Bind an event handler to the "blur" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + $('#target').blur(function() { + alert('Handler for .blur() called.'); + }); + + + + + Bind an event handler to the "blur" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "blur" JavaScript event on an element. + + + + + To trigger the blur event on all paragraphs. + $("p").blur(); + + + + + A multi-purpose callback list object that provides a powerful way to manage callback lists. + + + An optional list of space-separated flags that change how the callback list behaves. + + + + + + + + function fn1(value) { + console.log(value); + return false; + } + function fn2(value) { + console.log(value); + return false; + } + var callbacks = $.Callbacks("stopOnFalse"); + callbacks.add(fn1); + callbacks.fire("foo"); // output: foo + callbacks.add(fn2); + callbacks.fire("bar"); // output: bar (fn1 will not fired again) + + + + + Bind an event handler to the "change" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + Attaches a change event to the select that gets the text for each +selected option and writes them in the div. + $("select").change(function() { + var str = ""; + $("select option:selected").each(function() { + str += $(this).text() + " "; + }); + $("div").text(str); + }); + + + + + Bind an event handler to the "change" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "change" JavaScript event on an element. + + + + + + + Get the children of each element in the set of matched elements. + + + + + + A string containing a selector expression to match elements against. + + + + Find all children of the clicked element. + $("#container").click(function(e) { + var $kids = $(e.target).children(); + }); + + + + + Remove from the queue all items that have not yet been run. + + + + + + A string containing the name of the queue. Defaults to fx. + + + + Empty the queue. + var myDiv = $("div"); + myDiv.clearQueue(); + myDiv.stop(); + + + + + Bind an event handler to the "click" JavaScript event. + + + + + + A function to execute each time the event is triggered. + + + + Hide paragraphs on a page when they are clicked. + $("p").click(function() { + $(this).slideUp(); + }); + + + + + Bind an event handler to the "click" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + A function to execute each time the event is triggered. + + + + + + Trigger "click" JavaScript event on an element. + + + + + + + Create a deep copy of the set of matched elements. + + + + + + A Boolean indicating whether event handlers should be copied along with the elements. + + + + + $("b").clone().prependTo("p"); + + + + + Create a deep copy of the set of matched elements. + + + + + + A Boolean indicating whether event handlers should be copied along with the elements. + + + A Boolean indicating whether event handlers and data for all children of the cloned element should be copied. + + + + + $("b").clone().prependTo("p"); + + + + + For each element in the set, get the first element that matches the selector. + + + + + + A string containing a selector expression to match elements against. + + + + The closest list element toggles a yellow background +when it or its descendent is clicked. + $(document).bind("click", function(e) { + $(e.target).closest("li").toggleClass("hilight"); + }); + + + + + For each element in the set, get the first element that matches the selector. + + + + + + A string containing a selector expression to match elements against. + + + A DOM element within which a matching element may be found. + + + + + + For each element in the set, get the first element that matches the selector. + + + + + + A jQuery object to match elements agains. + + + + + + For each element in the set, get the first element that matches the selector. + + + + + + An element to match elements against. + + + + + + Check to see if a DOM element is within another DOM element. + + + + + + The DOM element that may contains the other element. + + + The DOM element that may be contained by the other element. + + + + Check if an element is inside another. + jQuery.contains(document.documentElement, document.body); // true + jQUery.contains(document.body, document.documentElement); //false + + + + + Get the children of each element in the set of matched elements. + + + + + Find all the text nodes inside a paragraph +and wrap them with a bold tag. + $("p").contents().filter(function() { + return this.nodeType!=1; + }).wrap("<b/>"); + + + + + Get the value of a style property for the first element in matched elements. + + + + + + A CSS property. + + + + Access the background color of a clicked div. + var color = $(this).css("background-color"); + + + + + Set one or more CSS properties for the set of matched elements. + + + + + + A CSS property name. + + + A value to set for the property. + + + + To change the color of any paragraph to red on mouseover event. + $("p").mouseover(function() { + $(this).css("color", "red"); + }); + + + + + Set one or more CSS properties for the set of matched elements. + + + + + + A CSS property name. + + + function(index, value) is a function returning the value to set. this is the current element.<br> +Receives the index position of the element in the set and the old value as arguments. + + + + + $('div.example').css('width', function(index) { + return index * 50; + }); + + + + + Set one or more CSS properties for the set of matched elements. + + + + + + A map of property-value pairs to set. + + + + To set the color of all paragraphs to red and background to blue: + var cssObj = { + 'background-color': '#ddd', + 'font-weight': '', + 'color': 'rgb(0,40,244)' + }; + $(this).css(cssObj); + + + + + Store arbitrary data associated with the matched elements. + + + + + + A string naming the piece of data to set. + + + The new data value; it can be any Javascript type including Array or Object. + + + + + $("div").data("test", {first: 16, last: "pizza!"}); + + + + + Store arbitrary data associated with the matched elements. + + + + + + An object of key-value pairs of data to update. + + + + + + Returns value at named data store for the first element in the jQuery collection, as set by data(name,value). + + + + + + Name of the data stored. + + + + + alert($('body').data('foo')); + + + + + Returns value at named data store for the first element in the jQuery collection, as set by data(name,value). + + + + + + alert($('body').data()); + + + + + Store arbitrary data associated with the specified element. + + + + + + The DOM element to associate with the data. + + + A string naming the piece of data to set. + + + The new data value. + + + + Store then retrieve a value from the div element. + jQuery.data(div, "test", {first:16, last:"pizza!"}); + $("span:first").text(jQuery.data(div, "test").first); + + + + + Returns value at named data store for the element. + + + + + + The DOM element to query for the data. + + + Name of the data stored. + + + + + alert(jQuery.data(document.body, 'foo')); + + + + + Returns value at named data store for the element. + + + + + + The DOM element to query for the data. + + + + + alert(jQuery.data(document.body)); + + + + + Bind an event handler to the "dblclick" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + $("p").dblclick(function(){ alert("Hello World!");}); + + + + + Bind an event handler to the "dblclick" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "dblclick" JavaScript event on an element. + + + + + + + Create Deferred object. + + + + + + + Set a timer to delay execution of subsequent items in the queue. + + + + + + An integer indicating the number of milliseconds to delay execution of the next item in the queue. + + + A string containing the name of the queue. + + + + Animate the hiding and showing of two divs, delaying the first before showing it. + $("button").click(function() { + $("div.first").slideUp(300).delay(800).fadeIn(400); + $("div.second").slideUp(300).fadeIn(400); + }); + + + + + Attach a handler to one or more events for all elements that match the selector, now or in the future. + + + + + + A selector to filter the elements that trigger the event. + + + A string containing one or more space-separated JvaScript event types, such as "click" or "keydown". + + + hanlder(eventObject) is a function to execute at the time the event is triggered. + + + + .delegate(0 attaches a click event handler to all paragraphs - even new ones. + $("body").delegate("p", "click", function() { + $(this).after("<p>Another paragraph!</p>"); + }); + + + + + Attach a handler to one or more events for all elements that match the selector, now or in the future. + + + + + + A selector to filter the elements that trigger the event. + + + A string containing one or more space-separated JvaScript event types, such as "click" or "keydown". + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute at the time the event is triggered. + + + + + + Attach a handler to one or more events for all elements that match the selector, now or in the future. + + + + + + A selector to filter the elements that trigger the event. + + + A map of one or more event types and functions to execute for them. + + + + + + Execute the next function on the queue for the matched elements. + + + + + + A string containing the name of the queue. + + + + Use dequeue to end a custome queue function. + $("div").queue(function() { + $(this).toggleClass("red"); + $(this).dequeue(); + }); + + + + + Execute the next function on the queue for the matched element. + + + A DOM element from which to remove and execute a queued function. + + + A string containing the name of the queue. + + + + Use jQuery.dequeue() to end a custom queue function +which allows the queue to keep going. + $("div").queue(function() { + $(this).toggleClass("red"); + $.dequeue(this); + }); + + + + + Remove the set of matched elements from the DOM. + + + + + + A selector expression that filters matched elements to be removed. + + + + Detach all paragraphs from the DOM. + var p = $("p").detach(); + + + + + A generic interator function, which can be used to seamlessly iterate over both objects and arrays. +Arrays and array-like objects with a length property (such as a function's arguments object) are iterated by numeric index, +from 0 to length-1. Other object are iterated via their named properties. + + + + + + The object or array to iterate over. + + + callback(indexInArray, valueOfElement) is the function that will be executed on every object. + + + + Iterates through the array displaying each number as both a word and numeral. + var arr = ["one", "two", "three", "four", "five" ]; + var obj = {one:1, two:2, three:3, four:4, five:5 }; + jQuery.each(arr, function() { + $("#" + this).text("Mine is " + this + "."); + return (this!="three"); //will stop running after "Three" + }); + jQuery.each(obj, function(i, val) { + $("#" + i).append(document.createTextNode(" - " + val)); + }); + + + + + Iterate over a jQuery object, executing a function for each matched element. + + + + + + function(index, element) is a function to execute for each matched element. + + + + Iterates over three divs and sets their color property. + $("div").each(function(i) { + if (this.style.color!="blue") { + this.style.color="blue"; + } else { + this.style.color=""; + } + }); + + + + + Remove all the child nodes of the set of matched elements from the DOM. + + + + + Remove all child nodes (including text nodes) from all paragraphs. + $("p").empty(); + + + + + End the most recent filtering operation in the current chain and return the set of matched elements to its previous state. + + + + + Select all paragraphs, find span elements inside these, and reverts the selection back to the paragraph. + $("p").showTags(0).find("span").showTags(1).css("background", "yellow") + .end().showTags(2).css("font-style", "italic"); + + + + + Reduce the set of matched elements to the one at the specified index. + + + + + + An integer indicating 0-based position of the element. If integer is minus, <br> +indicating the position of element, counting backwards from the last element in the set. + + + + Turn the div with index 2 blue by adding an appropriate class. + $("body").find("div").eq(2).addClass("blue"); + + + + + Bind an event handler to the "error" JavaScript event. + + + + + + handler(eventObject) is a function to execute when the event is triggered. + + + + To hide the "broken image" icons for IE users. + $("img").error(function() { + $(this).hide(); + }).attr("src", "missing.png"); + + + + + Bind an event handler to the "error" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute when the event is triggered. + + + + + + Takes a string and throws an exception containing it. + + + The message to send out. + + + + Override jQuery.error for display in Firebug. + jQuery.error = console.error; + + + + + Create a new jQuery.Event object. + + + A string represents event name. + + + Object that specifies event properties. + + + + + + + Create a new jQuery.Event object with specified event properties. + var e = jQuery.Event("keydown", {keyCode:64}); + + + + + Merge the contents of two or more objects together into the first object. + + + + + + An object that will receive the new properties if additional objects are passed in <br> +or that will extends the jQuery namespace if it is the sole argument. + + + An object containing additional properties to merge in. + + + Additional objects containing properties to merge in. + + + + Merge two objects, modifying the first. + var object1 = { apple: 0, banana: {weight: 52, price: 100}, cherry: 97 }, + var object2 = { banana: {price: 200}, durian: 100}; + $.extend(object1, object2); + // result object1={"apple":0, "banana":{"price":200}, "cherry":97, "durian":100} + + + + + Merge the contents of two or more objects together into the first object. + + + + + + If true, the merge becomes recursive (aka. deep copy). + + + An object that will receive the new properties if additional objects are passed in <br> +or that will extends the jQuery namespace if it is the sole argument. + + + An object containing additional properties to merge in. + + + Additional objects containing properties to merge in. + + + + Merge two objects recursively, modifying the first. + var object1 = { apple: 0, banana: {weight: 52, price: 100}, cherry: 97 }, + var object2 = { banana: {price: 200}, durian: 100}; + $.extend(true, object1, object2); + // result object1={"apple":0, "banana":{"weight":52,"price":200},"cherry":97,"durian":100} + + + + + Display the matched elements by fading them to opaque. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + Animates hidden divs to fade in one by one, completing each animation withing 600 ms. + $(document.body).click(function() { + $("div:hidden:first").fadeIn("slow"); + }); + + + + + Display the matched elements by fading them to opaque. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Hide the matched elements by fading them to transparent. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + Animates all paragraphs by fade out, comleting the animation within 600 ms. + $("p").fadeOut("slow"); + + + + + Hide the matched elements by fading them to transparent. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Adjust the opacity of the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A number between 0 and 1 denoting the target opacity. + + + A function to call once the animation is complete. + + + + Animates first paragraph to fade to an opacity 0.33 (33%, about +one third visible), completing the animation within 600 milliseconds. + $("p:first").click(function() { + $(this).fadeTo("slow", 0.33); + }); + + + + + Adjust the opacity of the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A number between 0 and 1 denoting the target opacity. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + Animates first paragraph to fade to an opacity 0.33 (33%, about +one third visible), completing the animation within 600 milliseconds. + $("p:first").click(function() { + $(this).fadeTo("slow", 0.33); + }); + + + + + Display or hide the matched elements by animating their opacity. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + Fades first paragraph in or out, completing their animation within 600 ms and using +a linear easing. Fades last paragraph in or out for 200 ms, inserting a "finished" message upon completion. + $("p:first").fadeToggle("slow", "linear"); + $("p:last").fadeToggle("fast", function() { + $("#log").append("<div>finished</div>"); + }); + + + + + Reduce the set of matched elements to those that match the selector or pass the function's test. + + + + + + A string containing a selector expression to match the current set of elements against. + + + + + $('li').filter(':even').css('background-color', 'red'); + + + + + Reduce the set of matched elements to those that match the selector or pass the function's test. + + + + + + function(index) is a function used as a test for each element in the set. <br> +this is the current DOM element. + + + + + $('li').filter(function(index) { + return $('strong', this).length==1; + }).css('background-color', 'red'); + + + + + Reduce the set of matched elements to those that match the selector or pass the function's test. + + + + + + An element to match the current set of elements against. + + + + Select all divs and filter the selection with a DOM element, keeping only +the one with an id of "unique". + $("div").filter(document.getElementById("unique")); + + + + + Reduce the set of matched elements to those that match the selector or pass the function's test. + + + + + + An existing jQuery object to match the current set of elements against. + + + + + + Get the descendants of each element in the curernt set of matched elements, filtered by a selector, jQuery object, or element. + + + + + + A string containing a selector expression to match elements against. + + + + Start with all paragraphs and searches for descendant span elements, +same as $("p span"). + $("p").find("span").css("color", "red"); + + + + + Get the descendants of each element in the curernt set of matched elements, filtered by a selector, jQuery object, or element. + + + + + + A jQuery object to match elements against. + + + + A selection using a jQuery collection of all span tags. Only span within p tags +are changed to red while others are left blue. + var $spans = $('span'); + $("p").find($spans).css('color', 'red'); + + + + + Get the descendants of each element in the curernt set of matched elements, filtered by a selector, jQuery object, or element. + + + + + + An element to match elements against. + + + + + + Reduce the set of matched elements to the first in the set. + + + + + Highlight the first span in the paragraph. + $("p span").first().addClass('highlight'); + + + + + Bind an event handler to the "focus" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + $("input").focus(function() { + $(this).next("span").css('display', 'inline').fadeOut(1000); + }); + + + + + Bind an event handler to the "focus" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "focus" JavaScript event on an element. + + + + + + + Bind an event handler to the "focusin" event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + $("p").focusin(function() { + $(this).find("span").css('display', 'inline').fadeOut(1000); + }); + + + + + Bind an event handler to the "focusin" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "focusout" event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + Watch for a loss of focus to occur inside paragraphs and note the difference +between the focusout count and the blur count. + $("p").focusout(function() { + foo++; $("#fo").text("focusout fired: " + fo + "x"); + }).blur(function() { + b++; $("#b").text("blur fired: " + b + "x"); + }); + + + + + Bind an event handler to the "focusout" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Load data from the server using a HTTP GET request. + + + + + + A string containing the URL to which the request is sent. + + + A map or string that is sent to the server with the request. + + + success(data, textStatus, jqXHR) is a callback function that is executed if the request succeeds. + + + The type of data expected from the server. Default: Intelligent Guess (xml, json, script, or html). + + + + Alert out the result from requesting test.cgi with an additional payload of data +(HTML or XML, depending on what was returned). + $.get("test.cgi", {name: "John", time: "2pm"}, + function(data) { + alert("Data Loaded: " + data); + }); + + + + + Retrieve the DOM elements matched by the jQuery object. + + + + + + A zero-based integer indicating which element to retrieve. + + + + Select all divs in the document and returns the DOM Elements as an Array, then +uses the build-in reverse-method to reverse that array. + display($("div").get().reverse()); + + + + + Load JSON-encoded data from the server using a GET HTTP request. + + + + + + A string containing the URL to which the request is sent. + + + A map or string that is sent to the server with the request. + + + success(data, textStatus, jqXHR) is a callback function that is executed if the request succeeds. + + + + Loads the four most recent cat picture from the Flickr JSON API. + $.getJSON("http://api.flickr.com/services/feeds/photos_public.gne?jsoncallback=?", + { tags: "mount rainier", tagmode: "any", format: "json"}, + function(data) { + ... // called if succeed + } + }); + + + + + Load a JavaScript file from the server using a GET HTTP request, then execute it. + + + + + + A string containing the URL to which the request is sent. + + + success(script, textstatus, jqXHR) is a callback function that is executed if the request succeeds. + + + + + $.getScript("/scripts/jquery.color.js", function() { + $("#go").click(function() { + ... + } + }); + + + + + Execute some JavaScript code globally. + + + The JavaScript code to execute. + + + + Execute a script in the global context. + function test() { + jQuery.globalEval("var newVar = true;"); + } + test(); // newVar === true + + + + + + Finds the elements of an array which satisfy a filter function. The original array is not affected. + + + + + + The array to search through. + + + function(elementOfArray, indexInArray) is a function to process each item against.<br> +The first argument to the function is the item, and the second argument is the index.<br> +The function should return a Boolean value. this will be the global window object. + + + If "invert" is false, or not provided, then the function returns an array consisting <br> +of all elements for which "callback" returns true. If "invert" is true, then the function <br> +returns an array consisting of all elements for which "callback" return false. + + + + Filters the original array of numbers leaving that are not 5 and having an index greater than 4. + var arr = [1,9,3,8,6,1,5,9,4,7,3,8,6,9,1]; + $("div").text(arr.join(", ")); + arr = jQuery.grep(arr, function(n, i) { + return (n!=5 && i>4); + }); + + + + + Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. + + + + + + A string containing a selector expression to match elements against. + + + + + $("ul").has("li").addClass("full"); + + + + + Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element. + + + + + + A DOM element to match elements against. + + + + + + Determine whether any of the matched elements are assigned the given class. + + + + + + The class name to search for. + + + + Looks for the paragraph that contains 'selected' as a class. + $("div#result1").append($("p:first").hasClass("selected").toString()); + + + + + Determine whether an element has any jQuery data associated with it. + + + + + + A DOM element to be checked for data. + + + + Set data on an element and see the results of hasData. + $.data(p, "testing", 123); + $p.append(jQuery.hasData(p)+" "); /* true */ + + + + + Get the current computed height for the first element in the set of matched elements. + + + + + + $("p").height(); + + + + + Set the CSS height of every matched element. + + + + + + An integer representing the number of pixels, or an integer with an optional unit of measure appended (as a String). + + + + To set the height of each div to 30px plus a color change. + $("div").height(30).css({cursor:"auto", backgroundColor:"green"}); + + + + + Set the CSS height of every matched element. + + + + + + function(index, height) is a function returning the height to set. Receives the index <br> +position of the element in the set and the old height as arguments. Within the function, <br> +this refers to the current element in the set. + + + + + + Hide the matched elements. + + + + + + + Hide the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + + + Hide the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Holds or release the execution of jQuery's ready event. + + + Indicates whether the ready hold is being requested or released. + + + + Delay the ready event until a custom plugin has loaded. + $.holdReady(true); + $.getScript("myplugin.js", function() { + $.holdReady(false); + }); + + + + + Bind two handlers to the matched elements, to be executed when the mouse pointer enters and leaves the elements. + + + + + + handlerIn(eventObject) is a function to execute when the mouse pointer enters the element. + + + handlerOut(eventObject) is a function to execute when the mouse pointer leaves the element. + + + + To add a special style to list items that are being hovered over. + $("li.fade").hover(function() { + $(this).fadeOut(100); $(this).fadeIn(500); + }); + + + + + Bind a single handler to the matched elements, to be executed when the mouse pointer enters or leaves the elements. + + + + + + handlerInOut(eventObject) is a function to execute when the mouse pointer enters or leaves the element. + + + + Slide the next sibling LI up or down on hover, and toggle a class. + $("li").filter(":odd").hide().end() + .filter(":even").hover(function() { + $(this).toggleClass("active").next().stop(true,true).slideToggle(); + }); + + + + + Get the HTML contents of the first element in the set of matched elements. + + + + + + var htmlStr = $(this).html(); + + + + + Set the HTML contents of each element in the set of matched elements. + + + + + + A string of HTML to set as the content of each matched element. + + + + Add some html to each div. + $("div").html("<span class='red'>Hello <b>Again</b></span>"); + + + + + Set the HTML contents of each element in the set of matched elements. + + + + + + function(index,oldhtml) is a function returning the HTML content to set. Receives the index position <br> +of the element in the set nad the old HTML value as arguments. jQuery empties the element before calling <br> +the function; use the oldhtml argument to reference the previous content. Within the function, this refers to the <br> +current element in the set. + + + + Add some html to each div. + $("div").html("<span class='red'>Hello <b>Again</b></span>"); + + + + + Seach for a specified value within an array and return its index (or -1 if not found). + + + + + + The value to search for. + + + An array through which to search. + + + The index of the array at which to begin the search. Default is 0. + + + + Report the index of some elements in the array. + $spans.eq(0).text(jQuery.inArray("John", arr)); + + + + + Search for a given element from among the matched elements. The return value is an integer indication +the position of the first element within the jQuery object relative to its sibling elements. + + + + + + var index = $("div").index(this); + + + + + Search for a given element from among the matched elements. + + + + + + A selector representing a jQuery collection in which to look for an element. + + + + + + Search for a given element from among the matched elements. + + + + + + The DOM element or first element within the jQuery object to look for. + + + + + + Get the current computed height for the first element in the set of matched elements, including padding but not border. + + + + + + $("p:last").text("innerHeight:" + p.innerHeight()); + + + + + Get the current computed width for the first element in the set of matched elements, including padding but not border. + + + + + + $("p:last").text("innerWidth:" + p.innerWidth()); + + + + + Insert every element in the set of matched elements after the target. + + + + + + A selector, element, HTML string, or jQuery object; the matched set of elements<br> +will be inserted after the element(s) specified by this parameter. + + + + Inserts all paragraphs after an element with id of "foo". + $("p").insertAfter("#foo"); + + + + + + Insert every element in the set of matched elements before the target. + + + + + + A selector, element, HTML string, or jQuery object; the matched set of elements<br> +will be inserted after the element(s) specified by this parameter. + + + + Inserts all paragraphs before an element with id of "foo". + $("p").insertBefore("#foo"); + + + + + Check the current matched set of elements against a selector, element, or jQuery object and return true if at least one of these elements matches the given arguments. + + + + + + A string containing a selector expression to match elements against. + + + + + + Check the current matched set of elements against a selector, element, or jQuery object and return true if at least one of these elements matches the given arguments. + + + + + + function(index) is a function used as a test for the set of elements. It accepts one argument, <br> +index, which is the element's index in the jQuery collection. Within the function, this refers to the current DOM element. + + + + + + Check the current matched set of elements against a selector, element, or jQuery object and return true if at least one of these elements matches the given arguments. + + + + + + An existing jQuery object to match the current set of elements against. + + + + + + Check the current matched set of elements against a selector, element, or jQuery object and return true if at least one of these elements matches the given arguments. + + + + + + An element to match the current set of elements against. + + + + + + Determine whether the argument is an array. + + + + + + Object to test whether or not it is an array. + + + + + + Check to see if an object is empty (contains no properties). + + + + + + Object that will be checked to see if it's empty. + + + + + + Determine if the argument passed is a Javascript function object. + + + + + + Object to test whether or not it is a function. + + + + + + Determine whether its argument is a number. + + + + + + The value to be tested. + + + + + + Check to see if an object is a plain object (created using "{}" or "new Object"). + + + + + + Object that will be checked to see if it's a plain object. + + + + + + Determine whether the argument is a window. + + + + + + Object to test whether or not it is a window. + + + + + + Check to see if a DOM node is within an XML document (or is an XML document). + + + + + + The DOM node that will be checked to see if it's in an XML document. + + + + + + Bind an event handler to the "keydown" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "keydown" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "keydown" Javascript event on an element. + + + + + + + Bind an event handler to the "keypress" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "keypress" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "keypress" Javascript event on an element. + + + + + + + Bind an event handler to the "keyup" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "keyup" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "keyup" Javascript event on an element. + + + + + + + Reduce the set of matched elements to the final one in the set. + + + + + Highlight the last span in a paragraph. + $("p span").last().addClass('highlight'); + + + + + Load data from the server and place the returned HTML into matched element. + + + + + + A string containing the URL to which the request is sent. + + + A map or string that is sent to the server with the request. + + + complete(responseText, textStatus, XMLHttpRequest) is a callback function that is <br> +executed when the request completes. + + + + Load the main page's footer navigation into an orderer list. + $("#new-nav").load("/ #jq-footerNavigation li"); + + + + + Convert an array-like object into a true JavaScript array. + + + + + + Any object to turn into a native Array. + + + + + + Pass each element in the current matched set through a function, producing a new jQuery object containing the return values. + + + + + + callback(index, domElement) is a function object that will be invoked for each element in the current set. + + + + Build a list of all the values within a form. + $("p").append($("input").map(function() { + return $(this).val(); + }).get().join(", ")); + + + + + Translate all items in an array or objct to new array or items. + + + + + + The array to translate. + + + callback(elementOfArray, indexInArray) is the function to process each item against.<br> +The first argument is the array item, the second argument is the index in array.<br> +The function can return any value. Within the function, this refers to global (window) object. + + + + + arr = jQuery.map(arr, function(n,i) { + return (n.toUpperCase()+i); + }); + + + + + Translate all items in an array or objct to new array or items. + + + + + + The array or object to translate. + + + callback(value, indexOrKey) is the function to process each item against.<br> +The first argument is the value; the second argument is the index or key of the array or object property.<br> +The function can return any value. A returned array will be flattened into the resulting array.<br> +Within the function, this refers to global (window) object. + + + + Map the original object to a new array and double each value. + var dimensions = { width: 10, height: 15, length: 20}; + dimensions = $.map(dimensions, function(value,index) { + return value*2; + }); + + + + + Merge the contents of two arrays together into the first array. + + + + + + The first array to merge, the elements of second added. + + + The second array to merge into the first, unaltered. + + + + Merge two arrays, altering the first argument. + $.merge( [0,1,2], [2,3,4] ); // result: [0,1,2,3,4] + + + + + Bind an event handler to the "mousedown" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "mousedown" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "mousedown" JavaScript event on an element. + + + + + + + Bind an event handler to the "mouseenter" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "mouseenter" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "mouseenter" JavaScript event on an element. + + + + + + + Bind an event handler to the "mouseleave" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "mouseleave" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "mouseleave" JavaScript event on an element. + + + + + + + Bind an event handler to the "mousemove" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "mousemove" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "mousemove" JavaScript event on an element. + + + + + + + Bind an event handler to the "mouseout" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "mouseout" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "mouseout" JavaScript event on an element. + + + + + + + Bind an event handler to the "mouseover" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "mouseover" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "mouseover" JavaScript event on an element. + + + + + + + Bind an event handler to the "mouseup" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "mouseup" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "mouseup" JavaScript event on an element. + + + + + + + Get the immediately following sibling of each element in thext set of matched elements. +If a selector is provided, it retrieves the next sibling only if it matches that selector. + + + + + + A string containing a selector expression to match elements against. + + + + Find the very next sibling of each paragraph. Keep only the ones with a class "selected". + $("p").next(".selected").css("background", "yellow"); + + + + + Get all following siblings of each element in the set of matched elements, optionally filtered by a selector. + + + + + + A string containing a selector expression to match elements against. + + + + Locate all the divs after the first and give them a class. + $("div:first").nextAll().addClass("after"); + + + + + Get all following siblings of each element up to but not including the element matched by +the selector, DOM node, or jQuery object passed. + + + + + + A string containing a selector expression to indicate where to stop matching following sibling elements. + + + A string containing a selector expression to match elements against. + + + + Find the siblings that folow <dt id="term-2"> up to the next <dt> and give them a red backgroud color. + $("#term-2").nextUntil("dt").css("background-color", "red"); + + + + + Relinquish jQuery's control of $ variable. + + + + + + A Boolean indicating whether to remove all jQuery variables from the global scope (including jQuery itself). + + + + + jQuery.noConflict() {function() { + // code using jQuery + }); + // other code using $ as an alias to the other library + + + + + + An empty function + + + + Remove elements from the set of matched elements. + + + + + + A string containing a selector expresion to match elements against. + + + + Adds a border to divs that are not green or blue. + $("div").not(".green, #blueone").css("border-color", "red"); + + + + + Remove elements from the set of matched elements. + + + + + + One or more DOM elements to remove from the matched set. + + + + + + Remove elements from the set of matched elements. + + + + + + function(index) is a function used as a test for each element in the set.<br> +this is the current DOM element. + + + + + + Remove elements from the set of matched elements. + + + + + + An existing jQuery object to match the current set of elements against. + + + + + + Return a number representing the current time. This is a shorthand for (new Date()).getTime(). + + + + + + + Remove an event handler. + + + + + + One or more space-separated event types and optional namespaces, or just namespaces, <br> +such as "click", "keydown.myPlugin", or ".myPlugin". + + + A selector which should match the one originally passed to .on() when attaching event handlers. + + + A handler function previously attached for the event(s), or false. + + + + Add and remove event handlers on the colored button. + function aClick() { $("div").show().fadeOut("slow"); } + $("body").on("click", "#theone", aClick); + $("body").off("click", "#theone", aClick); + + + + + Remove an event handler. + + + + + + A map where the string keys represent one or more space-separated event types and optional namespace, <br> +and the values represent handler functions previously attached for the event(s). + + + A selector which should match the one originally passed to .on() when attaching event handlers. + + + + + + Get the current coordinates of the first element in the set of matched elements, relative to the document. + + + + + Access the offset of the second paragraph. + var p = $("p:last"); + var offset = p.offset(); + + + + + Set the current coordinates of every element in the set of matched elements, relative to the document. + + + + + + An object containing the properties top and left, which are integers indicating <br> +the new top and left coordinates for the elements. + + + + Set the offset of the second paragraph. + $("p:last").offset({top:10, left:30}); + + + + + Set the current coordinates of every element in the set of matched elements, relative to the document. + + + + + + function(index, coords) is a function to return the coordinates to set. Receives the index <br> +of the element in the collection as the first argument and the current coordinates as the <br> +second argument. The function should return an object with the new top and left properties. + + + + + + Get the closest ancestor element that is positioned. + + + + + Find the offsetParent of item "A". + $('li.item-a').offsetParent().css('background-color', 'red'); + + + + + Attach an event handler function for one or more events to the selected elements. + + + + + + One or more space-separated event types and optional namespaces, such as "click" or "keydown.myPlugin". + + + A selector string to filter the descendants of the selected elements that trigger the event. <br> +If the selector is null or omitted, the event is always triggered when it reaches the selected element. + + + Data to be passed to the handler in event.data when an event is triggered. + + + handler(eventObject) is a function to execute when event is triggered. <br> +The value false is also allowed as a shorthand for a function that simpy does return false. + + + + Cancel a form submit action and prevent the event from bubbling up. + $("form").on("submit", false); + + + + + Attach an event handler function for one or more events to the selected elements. + + + + + + A map in which the string keys represent one or more space-separated event types and <br> +optional namespaces, and the values represent a handler function to be called for the event(s). + + + A selector string to filter the descendants of the selected elements that trigger the event. <br> +If the selector is null or omitted, the event is always triggered when it reaches the selected element. + + + Data to be passed to the handler in event.data when an event is triggered. + + + + + $("div.test").on({ + click: function() { $(this).toggleClass("active"); }, + mouseenter: function() { $(this).toggleClass("inside"); }, + mouseleave: function() { $(this).toggleClass("inside"); } + }); + + + + + Attach a handler to an event for the elements. The handler is executed at most once per element. + + + + + + A string containing one or more JavaScript event types, such as "click" or "submit", or custom event names. + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute at the time the event is triggered. + + + + + + Attach a handler to an event for the elements. The handler is executed at most once per element. + + + + + + A string containing one or more JavaScript event types, such as "click" or "submit", or custom event names. + + + A selector string to filter the descendants of the selected elements that trigger the event. <br> +If the selector is null or omitted, the event is always triggered when it reaches the selected element. + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute at the time the event is triggered. + + + + Tie a one-time click to each div. + $("div").one("click", function() { + ... + }); + + + + + Attach a handler to an event for the elements. The handler is executed at most once per element. + + + + + + A map in which the string keys represent one or more space-separated event types and optional namespaces,<br> +and the values represent a handler function to be called for the event(s). + + + A selector string to filter the descendants of the selected elements that trigger the event. <br> +If the selector is null or omitted, the event is always triggered when it reaches the selected element. + + + A map of data that will be passed to the event handler. + + + + + + Get the current computed height for the first element in the set of matched elements, including +padding, border, and optionally margin. Return an integer (without "px") representation of the value or null if called on an empty set of elements. + + + + + + A Boolean indicating whether to include the element's margin in the calculation. + + + + Get the outerHeight of a paragraph. + var p = $("p:first"); + $("p:last").text("outerHeight:" + p.outerHeight()); + + + + + Get the current computed width for the first element in the set of matched elements, including +padding, border, and optionally margin. Return an integer (without "px") representation of the value or null if called on an empty set of elements. + + + + + + A Boolean indicating whether to include the element's margin in the calculation. + + + + Get the outerHeight of a paragraph. + var p = $("p:first"); + $("p:last").text("outerHeight:" + p.outerWidth()); + + + + + Create a serialized representation of an array or object, suitable for use in a URL query string or Ajax request. + + + + + + An array or object to serialize + + + + Serialize complex object. + $.param({a:{b:1,c:2},d:[3,4,{e:5}]}) + // "a[b]=1&a[c]=2&d[]=3&d[]=4&d[2][e]=5" + + + + + Create a serialized representation of an array or object, suitable for use in a URL query string or Ajax request. + + + + + + An array or object to serialize + + + A Boolean indicating whether to perform a traditional "shallow" serialization. + + + + + + Get the parent of each element in the current set of matched elements, optionally filtered by a selector. + + + + + + A string containing a selector expression to match elements against. + + + + + var parentTag = $(this).parent().get(0).tagName; + + + + + Get the ancestors of each element in the current set of matched elements, optionally filtered by a selector. + + + + + + A string containing a selector expression to match elements against. + + + + Find all parent elements of each b. + var parentEls = $("b").parents().map(function() { + return this.tagName; + }).get().join(", "); + + + + + Get the ancestors of each element in the current set of matched elements, up to but not including the element +matched by the selector, DOM node, or jQuery object. + + + + + + A string containing a selector expression to indicate where to stop matching ancestor elements. + + + A string containing a selector expression to match elements against. + + + + + $("li.item-2").parentsUntil(".level-1").css("background-color", "red"); + + + + + Get the ancestors of each element in the current set of matched elements, up to but not including the element +matched by the selector, DOM node, or jQuery object. + + + + + + A DOM node or jQuery object indicating where to stop matching ancestor elements. + + + A string containing a selector expression to match elements against. + + + + + $("li.item-2").parentsUntil($("ul.level-1"), ".yes").css("border", "3px solid green"); + + + + + Takes a well-formed JSON string and returns the resulting JavaScript object. + + + + + + The JSON string to parse. + + + + + + Parses a string into an XML document. + + + + + + A well-formed XML string to be parsed. + + + + + + Get the current coordinates of the first element in the set of matched elements, relative to the offset parent. + + + + + Access the position of the second paragraph: + var position = p.position(); + + + + + Load data from the server using a HTTP POST request. + + + + + + A string containing the URL to which the request is sent. + + + A map or string that is sent to the server with the request. + + + A callback function that is executed if the request succeeds. + + + The type of data expected from the server. Default: Intelligent Guess (xml, json, script, text, html). + + + + Send form data using ajax request. + $.post("test.php", $("#testform").serialize()); + + + + + Insert content, specified by the parameter, to the beginning of each element in the set of matched elements. + + + + + + DOM element, array of elements, HTML string, or jQuery object to insert at the <br> +beginning of each element in the set of matched elements. + + + One or more additional DOM elements, arrays of elements, HTML strings, or jQuery objects <br> +to insert at the beginning of each element in the set of matched elements. + + + + Prepends some HTML to all paragraphs. + $("p").prepend("<b>Hello</b>"); + + + + + Insert content, specified by the parameter, to the beginning of each element in the set of matched elements. + + + + + + function(index, html) is a function that returns an HTML string, DOM elements(s) or jQuery object <br> +to insert at the beginning of each element in the set of matched elements. Receives the index position <br> +of the element in the set and the old HTML value of the elements as arguments. Within the function, this refers <br> +to current element in the set. + + + + + + Insert every element in the set of matched elements to the beginning of the target. + + + + + + A selector, element, HTML string, or jQuery object; the matched set of elements <br> +will be inserted at the beginning of the element(s) specified by this parameter. + + + + Prepends all spans to the element with the id "foo". + $("span").prependTo("#foo"); + + + + + Get the immediately preceding siblings of each element in the set of matched elements, optionally filtered by a selector. + + + + + + A string containing a selector expression to match elements against. + + + + Find very previous sibling of div. + var $curr = $("#start"); + $curr = $curr.prev(); + + + + + Get all preceding siblings of each element in the set of matched elements, optionally filtered by a selector. + + + + + + A string containing a selector expression to match elements against. + + + + Locate all the divs preceeding the last div and giv them a class. + $("div:last").prevAll().addClass("before"); + + + + + Get all preceding siblings of each element up to but not including the element matched by selector, DOM node, or jQuery object. + + + + + + A string containing a selector expression to indicate where to stop matching preceding sibling elements. + + + A string containing a selector expression to match elements against. + + + + + $("#term-3").prevUntil("dt").css("background-color", "red"); + + + + + Get all preceding siblings of each element up to but not including the element matched by selector, DOM node, or jQuery object. + + + + + + A string containing a selector expression to indicate where to stop matching preceding sibling elements. + + + A string containing a selector expression to match element against. + + + + + $("#term-3").prevUntil(term1, "dd").css("color", "green"); + + + + + Return a Promise object to observe when all actions of a certain type bound to the collection, queued or not, have finished. + + + + + + The type of queue that needs to be observed. By default, type is "fx". + + + Object onto which the promise methods have to be attached. + + + + Resolve the returned Promise when all animations have ended. + $("div").each(function(i) { + $(this).fadeIn().fadeOut(1000*(i+1)); + }); + $("div").promise().done(function() { + $("p").append(" Finished! "); + }); + + + + + Get a value of a property for the first element in the set of matched elements. + + + + + + The name of the propety to get. + + + + + $input.attr('checked'); // return 'checked' or '' + $input.prop('checked'); // return true or false + + + + + Set one or more properties for the set of matched elements. + + + + + + The name of the property to set. + + + A value to set for the property. + + + + + + Set one or more properties for the set of matched elements. + + + + + + A map of property-value pairs to set. + + + + Disable all checkboxes on the page. + $("input[type='checkbox']").prop({ + disabled: true + }); + + + + + Set one or more properties for the set of matched elements. + + + + + + The name of the property to set. + + + function(index, oldPropertyValue) is a function returning the value to set. Receives the index <br> +position of the element in the set and the old property value as arguments. Within the function, <br> +the keyword this refers to the current element. + + + + + + Takes a function and returns a new one that will always have a particular context. + + + + + + The function whose context will be changed. + + + The object to which the context (this) of the function should be set. + + + + + // execute you.test() in the context of the 'you' object + // no matter where it is called + // i.e. the 'this' keyword wil refer to 'you' + var youClick = $.proxy(you.test, you); + + + + + Takes a function and returns a new one that will always have a particular context. + + + + + + The object to which the context (this) of the function should be set. + + + The name of the function whose context will be changed (should be a property of the context object). + + + + Ensure the context of the function using the "context, function name" signature. + $("#test").click(jQuery.proxy(obj, "test")); + + + + + Add a collection of DOM elements onto the jQuery stack. + + + + + + An array of elements to push onto the stack and make into a new jQuery object. + + + + Add some elements onto the jQuery stack, then pop back off again. + jQuery([]).pushStack(document.getElementsByTagName("div")) + .remove().end(); + + + + + Add a collection of DOM elements onto the jQuery stack. + + + + + + An array of elements to push onto the stack and make into a new jQuery object. + + + The name of a jQuery method that generated the array of elements. + + + The arguments that were passed in to the jQuery method (for serialization). + + + + + + Show the queue of functions to be executed on the matched elements. + + + + + + A string containing the name of the queue. Defaults to fx, the standard effect queue. + + + + + + Manipulate the queue of functions to be executed on the matched elements. + + + + + + A string containing the name of the queue. Defaults to fx, the standard effects queue. + + + An array of functions to replace the current queue contents. + + + + + + Manipulate the queue of functions to be executed on the matched elements. + + + + + + A string containing the name of the queue. Defaults to fx, the standard effects queue. + + + callback(next) is new function to add to the queue, with a function to call that will dequeue the next item. + + + + Queue a custom function. + $("div").queue(function() { + $(this).addClass('newcolor'); $(this).dequeue(); + }); + + + + + Show the queue of functions to be executed on the matched element. + + + + + + A DOM element to inspect for an attached queue. + + + A string containing the name of the queue. Defaults to fx, the standard effects queue. + + + + Show the length of the queue. + var n = jQuery.queue($("div")[0], "fx"); + $("span").text("Queue length is: " + n.length); + + + + + Manipulate the queue of functions to be executed on the matched element. + + + + + + A DOM element where the array of queued functions is attached. + + + A string containing the name of the queue. Defaults to fx, the standard effects queue. + + + An array of function to replace the current queue contents. + + + + Set a queue array to delete the queue. + jQuery.queue($("div")[0], "fx", []); + + + + + Manipulate the queue of functions to be executed on the matched element. + + + + + + A DOM element where the array of queued functions is attached. + + + A string containing the name of the queue. Defaults to fx, the standard effects queue. + + + The new function to add to the queue. + + + + Queue a custom function. + jQuery.queue($("div")[0], "fx", function() { + $(this).addClass("newcolor"); + jQuery.dequeue(this); + }); + + + + + Specify a function to execute when the DOM is fully loaded. + + + + + + A function to execute after the DOM is ready. + + + + + + Remove the set of matched elements from the DOM. + + + + + + A selector expression that filters the set of matched elements to be removed. + + + + Remove all paragraphs from the DOM. + $("p").remove(); + + + + + Remove an attribute from each element in the set of matched elements. + + + + + + An attribute to remove; as of version 1.7, it can be a space-separated list of attributes. + + + + + var input = $(this).next(); + input.removeAttr("title"); + + + + + Remove a single class, multiple classes, or all classes from each element in the set of matched elements. + + + + + + One or more space-separated classes to be removed from the class attribute of each matched element. + + + + Remove the class 'blue' from the matched elements. + $("p:even").removeClass("blue"); + + + + + Remove a single class, multiple classes, or all classes from each element in the set of matched elements. + + + + + + function(index, class) is a function returning one or more space-separated class names to be removed.<br> + Receives the index position of the element in the set and the old class value as arguments. + + + + + + Remove a previously-stored piece of data. + + + + + + A string naming the piece of data to delete. + + + + Set a data store then remove it. + $("div").data("test1", "VALUE-1"); + $("div").removeData("test1"); + + + + + Remove a previously-stored piece of data. + + + + + + An array or space-separated string naming the pieces of data to delete. + + + + + + Remove a previously-stored piece of data. + + + + + + A DOM element from which to remove data. + + + A string naming the piece of data to remove. + + + + + var div = $("div")[0]; + jQuery.removeData(div, "test1"); + + + + + Remove a property for the set of matched elements. + + + + + + The name of the property to set. + + + + + var $para = $("p"); + $para.prop("luggageCode", 1234); + $para.removeProp("luggageCode"); + + + + + Replace each target element with the set of matched elements. + + + + + + A selector expression indicating which element(s) to replace. + + + + Replace all paragraphs with bold words. + $("<b>paragraph</b>").replaceAll("p"); + + + + + Replace each element in the set of matched elements with the provided new content. + + + + + + The content to insert. May be an HTML string, DOM element, or jQuery object. + + + + Replace the button with a div containing the same word. + $("button").replaceWith("<div>" + $("button").text() + "</div>"); + + + + + Replace each element in the set of matched elements with the provided new content. + + + + + + function is a function that returns content with which to replace the set of matched elements. + + + + + + Bind an event handler to the "resize" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "resize" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "resize" JavaScript event on an element. + + + + + + + Bind an event handler to the "scroll" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "scroll" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "scroll" JavaScript event on an element. + + + + + + + Get the current horizontal position of the scroll bar for the first element in the set of matched elements. + + + + + + + Set the current horizontal position of the scroll bar for each of the set of matched elements. + + + + + + An integer indicating the new position to set the scroll bar to. + + + + + + Get the current vertical position of the scroll bar for the first element in the set of matched elements. + + + + + + + Set the current vertical position of the scroll bar for each of the set of matched elements. + + + + + + An integer indicating the new position to set the scroll bar to. + + + + + + Bind an event handler to the "select" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "select" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "select" JavaScript event on an element. + + + + + + + Encode a set of form elements as a string for submission. + + + + + + var str = $("form").serialize(); + $(#results).text(str); + + + + + Encode a set of form elements as an array of names and values. + + + + + + var fields = $(":input").serializeArray(); + $("#results").empty(); + jQuery.each(fields, function(i, field) { + $("#results").append(field.value + " "); + }); + + + + + Display the matched elements. + + + + + + + Display the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + + + Display the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Get the siblings of each element in the set of matched elements, optionally filtered by a selector. + + + + + + A string containing a selector expression to match elements against. + + + + Find all siblings with a class 'selected' of each div. + $("p").siblings(".selected").css("background", "yellow"); + + + + + Return the number of elements in the jQuery object. + + + + + + + Reduce the set of matched elements to a subset specified by a range of indices. + + + + + + An integer indicating the 0-based position at which the elements begin to be selected. <br> +If negative, it indicates an offset from the end of the set. + + + An integer indicating the 0-based position at which the elements stop being selected. <br> +If negative, it indicates an offset from the end of the set. If omitted, the range continues until the end of the set. + + + + Select all paragraphs, then slices the selection to include only the second element. + $("p").slice(1, 2).wrapInner("<b></b>"); + + + + + Display the matched elements with a sliding motion. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + + + Display the matched elements with a sliding motion. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Display or hide the matched elements with a sliding motion. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + + + Display or hide the matched elements with a sliding motion. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Hide the matched elements with a sliding motion. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + + + Hide the matched elements with a sliding motion. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Stop the currently-running animation on the matched elements. + + + + + + A boolean indicating whether to remove queued animation as well. Defaults to false. + + + A boolean indicating whether to complete the current animation immediately. Defaults to false. + + + + + + Stop the currently-running animation on the matched elements. + + + + + + The name of the queue in which to stop animations. + + + A boolean indicating whether to remove queued animation as well. Defaults to false. + + + A boolean indicating whether to complete the current animation immediately. Defaults to false. + + + + + + Bind an event handler to the "submit" JavaScript event. + + + + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Bind an event handler to the "submit" JavaScript event. + + + + + + A map of data that will be passed to the event handler. + + + handler(eventObject) is a function to execute each time the event is triggered. + + + + + + Trigger "submit" JavaScript event on an element. + + + + + + + Get the combined text contents of each element in the set of matched elements, including their descendants. + + + + + + + Set the content of each element in the set of matched elements to the specified text. + + + + + + A string of text to set as content of each matched element. + + + + + + Set the content of each element in the set of matched elements to the specified text. + + + + + + function(index,text) is a function returning the text content to set. Receives the index <br> +position of the element in the set and the old text value as arguments. + + + + + + Retrieve all the DOM elements contained in the jQuery set, as an array. + + + + + + + Display or hide the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A function to call once the animation is complete. + + + + + + Display or hide the matched elements. + + + + + + A string or number determining how long the animation will run.<br> +The strings 'fast' and 'slow' can be supplied to indicate durations of 200 and 600 ms, respectively. + + + A string indicating which easing function to use for the transition.<br> +The only easing implementations in the jQuery library are the default, calling 'swing', and one that <br> +progresses at a constant pace, called 'linear'. + + + A function to call once the animation is complete. + + + + + + Display or hide the matched elements. + + + + + + A Boolean indicating whether to show or hide the elements. + + + + + + Add or remove one or more classes from each element in the set of matched elements, +depending on either the class's presence or the value of the switch argument. + + + + + + One or more class names (separated by spaces) to be toggled for each element in the matched set. + + + + + + Add or remove one or more classes from each element in the set of matched elements, +depending on either the class's presence or the value of the switch argument. + + + + + + One or more class names (separated by spaces) to be toggled for each element in the matched set. + + + A Boolean value to determine whether the class should be added or removed. + + + + + + Add or remove one or more classes from each element in the set of matched elements, +depending on either the class's presence or the value of the switch argument. + + + + + + A Boolean value to determine whether the class should be added or removed. + + + + + + Add or remove one or more classes from each element in the set of matched elements, +depending on either the class's presence or the value of the switch argument. + + + + + + function(index, class, switch) is a function that returns class names to be toggled in the class attribute <br> +of each element in the matched set. Receives the index position of the element in the set, <br> +the old class value, and the switch as arguments. + + + A Boolean value to determine whether the class should be added or removed. + + + + + + Execute all handler and behaviors attached to the matched elements for the given event type. + + + + + + A string containing a JavaScript event type, such as click or submit. + + + Additional parameters to pass along to the event handler. + + + + + + Execute all handler and behaviors attached to the matched elements for the given event type. + + + + + + A jQuery.Event object. + + + + + + Execute all handlers attached to an element for an event. This method does not cause the default +behaviour of an event to occur (such as a form submission). This method only affects the first matched element. Event +created with this method do not bubble up the DOM hierarchy. + + + + + + A string containing JavaScript event type, such as click or submit. + + + An array of additional parameters to pass along to the event handler. + + + + + + Remove the whitespace from the beginning and end of a string. + + + + + + The string to trim. + + + + + + Determine the internal JavaScript [[Class]] of an object. + + + + + + Object to get the internal JavaScript [[Class]] of. + + + + + + Remove a previously-attached event handler from the elements. + + + + + + A string containing a JavaScript event type, such as click or submit. + + + handler(eventObject) is the function that is to be no longer executed. + + + + + + Remove a previously-attached event handler from the elements. + + + + + + A string containing a JavaScript event type, such as click or submit. + + + Unbinds the corresponding 'return false' function that was bound using .bind(eventType, false). + + + + + + Remove a previously-attached event handler from the elements. + + + + + + A JavaScript event object as passed to an event handler. + + + + + + Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. + + + + + + + Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. + + + + + + A selector which will be used to filter the event results. + + + A string containing a JavaScript event type, such as "click" or "keydown". + + + + + + Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. + + + + + + A selector which will be used to filter the event results. + + + A string containing a JavaScript event type, such as "click" or "keydown". + + + handler(eventObject) is a function to execute at the time the event is triggered. + + + + + + Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. + + + + + + A selector which will be used to filter the event results. + + + A map of one or more event types and previously bound functions to unbind from them. + + + + + + Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. + + + + + + A String containing a namespace to unbind all events from. + + + + + + Sorts an array of DOM elements, in place, with the duplicates removed. Note that this only works on arrays of +DOM elements, not strings or numbers. + + + + + + The array of DOM elements. + + + + + + Remove the parents of the set of matched elements from the DOM, leaving the matched elements in their place. + + + + + + + Get the current value of the first element in the set of matched elements. + + + + + + + Set the value of each element in the set of matched elements. + + + + + + A string of text or an array of strings corresponding to the value of each matched element to set as selected/checked. + + + + + + Set the value of each element in the set of matched elements. + + + + + + function(index, value) is a function returning the value to set. this is the current element. <br> +Receives the index position of the element in the set and the old value as arguments. + + + + + + Provides a way to execute callback functions based on one or more objects, usually Deferred objects that represent asynchronous events. + + + + + + One or more Deferred objects, or plain JavaScript objects. + + + + Executing the function myFunc when both ajax requests are successful, +or myFailure if either one has an error. + $.when($.ajax("/page1.php"), $.ajax("/page2.php") + .then(myFunc, myFailure); + + + + + + Get the current computed width for the first element in the set of matched elements. + + + + + + + Set the CSS width of each element in the set of matched elements. + + + + + + An integer representing the number of pixels, or an integer along with an optional unit of measure appended. + + + + + + Set the CSS width of each element in the set of matched elements. + + + + + + function(index, width) is a function returning the width to set. Receives the index position of the element <br> +in the set and the old width as arguments. Within the function, this refers to the current element in the set. + + + + + + Wrap an HTML structure around each element in the set of matched elements. + + + + + + An HTML snippet, selector expression, jQuery object, or DOM element <br> +specifying the structure to wrap around the matched elements. + + + + + + Wrap an HTML structure around each element in the set of matched elements. + + + + + + function(index) is a callback function returning the HTML content or jQuery object to wrap around the matched elements.<br> +Receives the index position of the element in the set as an argument. Within the function,<br> +this refers to the current element in the set. + + + + + + Wrap an HTML structure around all elements in the set of matched elements. + + + + + + An HTML snippet, selector expression, jQuery object, or DOM element<br> +specifying the structure to wrap around the matched elements. + + + + + + Wrap an HTML structure around the content of each element in the set of matched elements. + + + + + + An HTML snippet, selector expression, jQuery object, or DOM element<br> +specifying the structure to wrap around the matched elements. + + + + + + Wrap an HTML structure around the content of each element in the set of matched elements. + + + + + + function(index) is a callback function which generates a structure to wrap around the content of the matched elements.<br> +Receives the index position of the element in the set as an argument.<br> +Within the function, this refers to the current element in the set. + + + + + + + + + + + + Add a callback or a collection of callbacks to a callback list. + + + A function, or array of functions, that are to be added to the callback list. + + + + + + + Add new callbacks to a callback list. + var foo = function(value) { + console.log('foo:' + value); + } + var callbacks = $.Callbacks(); + callbacks.add(foo); + + + + + Disable a callback list from doing anything more. + + + + + Disable further calls being made to a callback list. + var callbacks = $.Callbacks(); + callbacks.add(foo); + callbacks.fire('foo'); + callbacks.disable(); + + + + + Remove all of the callbacks from a list. + + + + + Empty a list of callbacks. + var callbacks = $.Callbacks(); + callbacks.add(foo); + callbacks.add(bar); + callbacks.empty(); + + + + + Call all of the callbacks with the given arguments + + + + + + The argument or list of arguments to pass back to the callback list. + + + + + var callbacks = $.Callbacks(); + callbacks.add(foo); + callbacks.fire('hello'); + callbacks.fire('world'); + + + + + Determine if the callbacks have already been called at least once. + + + + + + var callbacks = $.Callbacks(); + callbacks.add(foo); + callbacks.fire('hello'); + console.log(callbacks.fired()); + + + + + Call all callbacks in a list with the given context and arguments. + + + A reference to the context in which the callbacks in the list should be fired. + + + An argument, or array of arguments, to pass to the callbacks in the list. + + + + Fire a list of callbacks with a specific context and an array of arguments. + var callbacks = $.Callbacks; + callbacks.add(log); + callbacks.fireWith(window, ['foo', 'bar']); + + + + + Determine whether a supplied callback is in a list + + + + + + The callback to search for. + + + + + var callbacks = $.Callbacks(); + callbacks.add(foo); + console.log(callbacks.has(foo)); + console.log(callbacks.has(bar)); + + + + + Lock a callback list in its current state. + + + + + var callbacks = $.Callbacks(); + callbacks.lock(); + + + + Determine if the callbacks list has been locked. + + + + + var callbacks = $.Callbacks(); + callbacks.lock(); + console.log(callbacks.locked()); + + + + + Remove a callback or a collection of callbacks from a callback list. + + + + + + A function, or array of functions, that are to be removed from the callback list. + + + + + var callbacks = $.Callbacks(); + callbacks.add(foo); + callbacks.fire('hello'); + callbacks.remove(foo); + + + + + + + + + + Add handlers to be called when the Deferred object is either resolved or rejected. + + + + + + A function, or array of functions, that is called when the Deferred is resolved or rejected. + + + Optional additional functions, or arrays of functions. + + + + Attach a callback for both success and error. + $.get("test.php").always(function() { + alert("$.get completed with success or error callback arguments"); + }); + + + + + Add handlers to be called when the Deferred object is resolved. + + + + + + A function, or array of functions, that is called when the Deferred is resolved. + + + Optional additional functions, or arrays of functions. + + + + Resolve a Deferred object when the user clicks a button, +triggering a number of callback functions: + var dfd = $.Deferred(); + dfd.done([fn1, fn2], fn3, [fn2, fn1]); + $("button").bind("click", function() { + dfd.resolve("and"); + }); + + + + + Add handlers to be called when the Deferred object is rejected. + + + + + + A function, or array of functions, that is called when the Deferred is rejected. + + + Optional additional functions, or arrays of functions. + + + + + $.get("test.php") + .done(function(){alert("$.get succeeded");}) + .fail(function(){alert("$.get failed!");}); + + + + + Call the progressCallbacks on a Deferred object with the given args. + + + + + + Optional arguments that are passed to the progressCallbacks. + + + + + + Call the progressCallbacks on a Deferred object with the given context and args. + + + + + + Context passed to the progressCallbacks as the this object. + + + Optional arguments that are passed to the progressCallbacks. + + + + + + Utility method to filter and/or chain Deferreds. + + + + + + An optional function that is called when the Deferred is resolved. + + + An optional function that is called when the Deferred is rejected. + + + + Filter resolve value. + var defer = $.Deferred(), + filtered = defer.pipe(function(value) { + return value * 2; + }); + + + + + Utility method to filter and/or chain Deferreds. + + + + + + An optional function that is called when the Deferred is resolved. + + + An optional function that is called when the Deferred is rejected. + + + An optional function that is called when progress notifications are sent to the Deferred. + + + + + + Add handlers to be called when the Deferred object generates progress notifications. + + + + + + A function, or array of functions, that is called when the Deferred generates progress notifications. + + + + + + Return a Deferred's Promise object. + + + + + + Object onto which the promise methods have to be attached. + + + + Use the target argument to promote an existing object to a Promise: + defer = $.Deferred(); + defer.promise(obj); + defer.resolve("John"); + obj.done(function(name) { + obj.hello(name); // will alert "Hello John" + }).hello("Karl"); // will alert "Hello Karl" + + + + + Reject a Deferred object and call any failCallbacks with the given args. + + + + + + Optional arguments that are passed to the failCallbacks. + + + + + + Reject a Deferred object and call any failCallbacks with the given context and args. + + + + + + Context passed to the failCallbacks as the this object. + + + Optional arguments that are passed to the failCallbacks. + + + + + + Resolve a Deferred object and call any doneCallbacks with the given args. + + + + + + Optional arguments that are passed to the doneCallbacks. + + + + + + Resolve a Deferred object and call any doneCallbacks with the given context and args. + + + + + + Context passed to the doneCallbacks as the this object. + + + Optional arguments that are passed to the doneCallbacks. + + + + + + Determine the current state of a Deferred object. Return "pending", "resolved" or "rejected". + + + + + + + Add handlers to be called when the Deferred object is resolved or rejected. + + + + + + A function, or array of functions, called when the Deferred is resolved. + + + A function, or array of functions, called when the Deferred is rejected. + + + + + $.get("test.php").then( + function() { alert("$.get succeeded"); }, + function() { alert("$.get failed!"); } + ); + + + + + Add handlers to be called when the Deferred object is resolved or rejected. + + + + + + A function, or array of functions, called when the Deferred is resolved. + + + A function, or array of functions, called when the Deferred is rejected. + + + A function, or array of function, called when the Deferred notifies progress. + + + + + + Utility method to filter and/or chain Deferreds. + + + + + + An optional function that is called when the Deferred is resolved. + + + An optional function that is called when the Deferred is rejected. + + + + Filter resolve value. + var defer = $.Deferred(), + filtered = defer.pipe(function(value) { + return value * 2; + }); + + + + + Utility method to filter and/or chain Deferreds. + + + + + + An optional function that is called when the Deferred is resolved. + + + An optional function that is called when the Deferred is rejected. + + + An optional function that is called when progress notifications are sent to the Deferred. + + + + + + + + + + + + + + + Add handlers to be called when the Deferred object is resolved or rejected. + + + + + + A function, or array of functions, called when the Deferred is resolved. + + + A function, or array of functions, called when the Deferred is rejected. + + + A function, or array of function, called when the Deferred notifies progress. + + + + + + Add handlers to be called when the Deferred object is either resolved or rejected. + + + + + + A function, or array of functions, that is called when the Deferred is resolved or rejected. + + + Optional additional functions, or arrays of functions. + + + + Attach a callback for both success and error. + $.get("test.php").always(function() { + alert("$.get completed with success or error callback arguments"); + }); + + + + + Add handlers to be called when the Deferred object is resolved. + + + + + + A function, or array of functions, that is called when the Deferred is resolved. + + + Optional additional functions, or arrays of functions. + + + + Resolve a Deferred object when the user clicks a button, +triggering a number of callback functions: + var dfd = $.Deferred(); + dfd.done([fn1, fn2], fn3, [fn2, fn1]); + $("button").bind("click", function() { + dfd.resolve("and"); + }); + + + + + Add handlers to be called when the Deferred object is rejected. + + + + + + A function, or array of functions, that is called when the Deferred is rejected. + + + Optional additional functions, or arrays of functions. + + + + + $.get("test.php") + .done(function(){alert("$.get succeeded");}) + .fail(function(){alert("$.get failed!");}); + + + + + Determine the current state of a Deferred object. Return "pending", "resolved" or "rejected". + + + + + + + + + + + + + Return HTTP status code or 0 if error flag is set. + + + Return HTTP status text or empty string if error flag is set. + + + Return the text response entity body. + + + Return the document response entity body. + + + Returns the current state. + + + + + + Return the header field value from the response of which the filed name matches header, unless the field name is Set-Cookie or Set-Cookie2. + + + Matches header filed name with this value. + + + + + + + + Return all headers from the response, with the exception of those whose field name is Set-Cookie or Set-Cookie2. + + + + + + Appends an header tot he list of author request headers, or if header is already in the list of author request headers, combines its value with value. + + + Header name that will be appended. + + + Header value that will be appended. + + + + + Set the Content-Type header for the response to mime. + + + The new Content-Type. + + + + + Cancels any network activity. + + + Add handlers to be called when the Deferred object is either resolved or rejected. + + + + + + A function, or array of functions, that is called when the Deferred is resolved or rejected. + + + Optional additional functions, or arrays of functions. + + + + Attach a callback for both success and error. + $.get("test.php").always(function() { + alert("$.get completed with success or error callback arguments"); + }); + + + + + Add handlers to be called when the Deferred object is resolved. + + + + + + A function, or array of functions, that is called when the Deferred is resolved. + + + Optional additional functions, or arrays of functions. + + + + Resolve a Deferred object when the user clicks a button, +triggering a number of callback functions: + var dfd = $.Deferred(); + dfd.done([fn1, fn2], fn3, [fn2, fn1]); + $("button").bind("click", function() { + dfd.resolve("and"); + }); + + + + + Add handlers to be called when the Deferred object is rejected. + + + + + + A function, or array of functions, that is called when the Deferred is rejected. + + + Optional additional functions, or arrays of functions. + + + + + $.get("test.php") + .done(function(){alert("$.get succeeded");}) + .fail(function(){alert("$.get failed!");}); + + + + + Call the progressCallbacks on a Deferred object with the given args. + + + + + + Optional arguments that are passed to the progressCallbacks. + + + + + + Call the progressCallbacks on a Deferred object with the given context and args. + + + + + + Context passed to the progressCallbacks as the this object. + + + Optional arguments that are passed to the progressCallbacks. + + + + + + Add handlers to be called when the Deferred object generates progress notifications. + + + + + + A function, or array of functions, that is called when the Deferred generates progress notifications. + + + + + + Return a Deferred's Promise object. + + + + + + Object onto which the promise methods have to be attached. + + + + Use the target argument to promote an existing object to a Promise: + defer = $.Deferred(); + defer.promise(obj); + defer.resolve("John"); + obj.done(function(name) { + obj.hello(name); // will alert "Hello John" + }).hello("Karl"); // will alert "Hello Karl" + + + + + Reject a Deferred object and call any failCallbacks with the given args. + + + + + + Optional arguments that are passed to the failCallbacks. + + + + + + Reject a Deferred object and call any failCallbacks with the given context and args. + + + + + + Context passed to the failCallbacks as the this object. + + + Optional arguments that are passed to the failCallbacks. + + + + + + Resolve a Deferred object and call any doneCallbacks with the given args. + + + + + + Optional arguments that are passed to the doneCallbacks. + + + + + + Resolve a Deferred object and call any doneCallbacks with the given context and args. + + + + + + Context passed to the doneCallbacks as the this object. + + + Optional arguments that are passed to the doneCallbacks. + + + + + + Determine the current state of a Deferred object. Return "pending", "resolved" or "rejected". + + + + + + + Add handlers to be called when the Deferred object is resolved or rejected. + + + + + + A function, or array of functions, called when the Deferred is resolved. + + + A function, or array of functions, called when the Deferred is rejected. + + + + + $.get("test.php").then( + function() { alert("$.get succeeded"); }, + function() { alert("$.get failed!"); } + ); + + + + + Add handlers to be called when the Deferred object is resolved or rejected. + + + + + + A function, or array of functions, called when the Deferred is resolved. + + + A function, or array of functions, called when the Deferred is rejected. + + + A function, or array of function, called when the Deferred notifies progress. + + + + + + Utility method to filter and/or chain Deferreds. + + + + + + An optional function that is called when the Deferred is resolved. + + + An optional function that is called when the Deferred is rejected. + + + + Filter resolve value. + var defer = $.Deferred(), + filtered = defer.pipe(function(value) { + return value * 2; + }); + + + + + Utility method to filter and/or chain Deferreds. + + + + + + An optional function that is called when the Deferred is resolved. + + + An optional function that is called when the Deferred is rejected. + + + An optional function that is<br>called when progress notifications are sent to the Deferred. + + + + + + + + + + + + The current DOM element within the event bubbling phase. + + + An optional data map passed to an event method when the current executing handler is bound. + + + The element where the currently-called jQuery event handler was attached. + + + The namespace specified when the event was triggered. + + + The mouse position relative to the left edge of the document. + + + The mouse position relative to the top edge of the document. + + + The other DOM element involved in the event, if any. + + + The last value returned by an event handler that was triggered by this event, unless the value was undefined. + + + The DOM element that initiated the event. + + + The difference in milliseconds between the time the browser created the event and January 1, 1970. + + + Describes the nature of the event. + + + For key or mouse events, this property indicates the specific key or button that was pressed. + + + true if the Alt (or Option, on Mac) key was active when the key event was generated. Read only. + + + A boolean indicating whether the event bubles up through the DOM or not. + + + The button number that was pressed when the mouse event was fired: Left button=0, +middle button=1 (if present), right button=2. For mice configured for left handed use in which the button actions are +reversed the values are instead read right from left. Read only. + + + A boolean indicating whether the event is cancelable. + + + The character value of the key. Read only. + + + The X coordinate of the mouse pointer in local (DOM content) coordinates. Read only. + + + The Y coordinate of the mouse pointer in local (DOM content) coordinates. Read only. + + + true if the Control key was active when the key event was generated. Read only. + + + Indicates which phase of the event flow is currently being evaluated. Returns an integer value +represented by 3 constants: Event.CAPTURING_PHASE (1), Event.AT_TARGET (2), or Event.BUBBLING_PHASE (3). + + + true if the Meta (or Command, on Mac) key was active when the key event was generated. Read only. + + + The X coordinate of the mouse pointer in global (screen) coordinates. Read only. + + + The Y coordinate of the mouse pointer in global (screen) coordinates. Read only. + + + true if the Shift key was active when the key event was generated. Read only. + + + + + + Return wether event.preventDefault() was ever called on this object. + + + + + + Return wether event.stopImmediatePropogatin() was ever called on this event object. + + + + + + Return whether event.stopPropagation() was ever called on this event object. + + + + + + If this method is called, the default action of the event will not be triggered. + + + Keeps the rest of the handlers from being executed and prevents the event from bubbling up the DOM tree. + + + Prevents the event from bubbling up the DOM tree, preventing any parent handlers from being notified of the event. + + + + + + + + The rate (in milliseconds) at which animations fire. + + + Globally disable all animations. + + + + + diff --git a/license.html b/license.html new file mode 100644 index 0000000..727c1f1 --- /dev/null +++ b/license.html @@ -0,0 +1,751 @@ + + + + +Appcelerator License + + + + +

+This program Copyright (c) 2005-2011 by Appcelerator, Inc. This program is +distributed under the GNU General Public license. + +This program is free software; you can redistribute +it and/or modify it under the terms of the GNU General Public License, +Version 3, as published by the Free Software Foundation. +

+

Any modifications must keep this entire license intact.

+ +
+

GNU General Public License

+ + +

GNU GENERAL PUBLIC LICENSE

+

Version 3, 29 June 2007

+ +

Copyright (C) 2007 Free Software Foundation, Inc. http://fsf.org/

+ + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed.

+ +

Preamble

+ +

The GNU General Public License is a free, copyleft license for +software and other kinds of works.

+ +

The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too.

+ +

When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things.

+ +

To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others.

+ +

For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights.

+ +

Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it.

+ +

For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions.

+ +

Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users.

+ +

Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free.

+ +

The precise terms and conditions for copying, distribution and +modification follow.

+ +

TERMS AND CONDITIONS

+ +

0. Definitions.

+ +

"This License" refers to version 3 of the GNU General Public License.

+ +

"Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks.

+ + +

"The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations.

+ +

To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work.

+ +

A "covered work" means either the unmodified Program or a work based +on the Program.

+ +

To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well.

+ +

To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying.

+ +

An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion.

+ +

1. Source Code.

+ +

The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work.

+ +

A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language.

+ +

The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it.

+ +

The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work.

+ +

The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source.

+ +

The Corresponding Source for a work in source code form is that +same work.

+ +

2. Basic Permissions.

+ +

All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law.

+ +

You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you.

+ +

Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary.

+ +

3. Protecting Users' Legal Rights From Anti-Circumvention Law.

+ +

No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures.

+ +

When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures.

+ +

4. Conveying Verbatim Copies.

+ +

You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program.

+ +

You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee.

+ +

5. Conveying Modified Source Versions.

+ +

You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions:

+ + + +

A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate.

+ +

6. Conveying Non-Source Forms.

+ +

You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways:

+ + + +

A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work.

+ +

A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product.

+ +

"Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made.

+ +

If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM).

+ +

The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network.

+ +

Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying.

+ +

7. Additional Terms.

+ +

"Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions.

+ +

When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission.

+ +

Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms:

+ + + +

All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying.

+ +

If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms.

+ +

Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way.

+ +

8. Termination.

+ +

You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11).

+ +

However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation.

+ +

Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice.

+ +

Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10.

+ +

9. Acceptance Not Required for Having Copies.

+ +

You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so.

+ +

10. Automatic Licensing of Downstream Recipients.

+ +

Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License.

+ +

An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts.

+ +

You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it.

+ +

11. Patents.

+ +

A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version".

+ +

A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License.

+ +

Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version.

+ +

In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party.

+ +

If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid.

+ + +

If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it.

+ +

A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007.

+ +

Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law.

+ +

12. No Surrender of Others' Freedom.

+ +

If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program.

+ +

13. Use with the GNU Affero General Public License.

+ +

Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such.

+ +

14. Revised Versions of this License.

+ +

The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns.

+ +

Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation.

+ +

If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program.

+ +

Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version.

+ +

15. Disclaimer of Warranty.

+ +

THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

+ +

16. Limitation of Liability.

+ +

IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES.

+ +

17. Interpretation of Sections 15 and 16.

+ +

If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee.

+ +

END OF TERMS AND CONDITIONS

+ + +

Appcelerator GPL Exception

+ +

Section 7 Exception

+

As a special exception to the terms and conditions of the GNU General Public License +Version 3 (the "GPL"): You are free to convey a modified version that is formed entirely +from this file (for purposes of this exception, the "Program" under the GPL) and the +works identified at http://www.aptana.com/legal/gpl +(each an "Excepted Work"), which are conveyed to you by Appcelerator, Inc. +and licensed under one or more of the licenses identified in the Excepted License List below +(each an "Excepted License"), as long as: + +

    +
  1. you obey the GPL in all respects for the Program and the modified version, + except for Excepted Works which are identifiable sections of the modified version, + which are not derived from the Program, and which can reasonably be considered + independent and separate works in themselves,
  2. +
  3. all Excepted Works which are identifiable sections of the modified version, which + are not derived from the Program, and which can reasonably be considered independent + and separate works in themselves, +
      +
    1. are distributed subject to the Excepted License under which they were originally licensed, and
    2. +
    3. are not themselves modified from the form in which they are conveyed to you by Aptana, and
    4. +
    5. the object code or executable form of those sections are accompanied by the complete + corresponding machine-readable source code for those sections, on the same medium + as the corresponding object code or executable forms of those sections, and are + licensed under the applicable Excepted License as the corresponding object code or + executable forms of those sections, and
    6. +
    +
  4. +
  5. any works which are aggregated with the Program, or with a modified version on a + volume of a storage or distribution medium in accordance with the GPL, are + aggregates (as defined in Section 5 of the GPL) which can reasonably be considered + independent and separate works in themselves and which are not modified versions + of either the Program, a modified version, or an Excepted Work.
  6. +
+ +

If the above conditions are not met, then the Program may only be copied, modified, + distributed or used under the terms and conditions of the GPL or another valid licensing + option from Appcelerator, Inc. Terms used but not defined in the foregoing paragraph + have the meanings given in the GPL.

+ +

+

Excepted License List

+ +

+ +

This list may be modified by Appcelerator from time to time. See Appcelerator's website for the latest version.

+ +

Attribution Requirement

+

This license does not grant any license or rights to use the trademarks "Aptana," any "Aptana" logos, +or any other trademarks of Appcelerator, Inc. You are not authorized to use the name Aptana or the names of +any author or contributor for publicity purposes, without written authorization.

+ +

However, in addition to the other notice obligations of this License, all copies of any covered work conveyed +by you must include on each user interface screen and in the Appropriate Legal Notices the following text: +"Powered by Aptana". On user interface screens, this text must be visibly and clearly displayed in the title bar, status bar, +or otherwise directly in the view that is in focus.

+ + + +