pith-front / pith-pack-jquery
Pack jQuery for Pith
Installs: 22
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 1
Open Issues: 0
Language:JavaScript
Requires
- php: ^8.2
- ext-gd: *
- ext-json: *
- ext-pdo: *
- ext-readline: *
- pith/base: ^0.2.0
- pith/workflow-elements: ^0.3.0
This package is auto-updated.
Last update: 2025-03-20 07:16:02 UTC
README
Pack jQuery for Pith
About
This project packs jQuery so that it can be used with the Pith Framewok.
For info on jQuery, see the jQuery website at https://jquery.com/
For info on Pith, see the Pith website at https://pith-framework.org/
Install
Install to an existing Pith Framework project
Use Composer to install pack to the vendor
folder.
php composer.phar require pith-front/pith-pack-jquery
Add new route to you Route List:
public array $routes = [ // Other routes.... // ... // Add route to call jQuery from ['route', 'GET', '/resources/vendor/library/jquery/{filepath:.+}', '\\PithFront\\PithPackJquery\\JqueryResourceRoute'], ];
To add jQuery to the page from PHP, call addScript( )
in a View Requisition.
(For the last parameter use 'library-for-layout' if jQuery needs to be loaded with the theme scripts and styles, otherwise use 'library-for-page' to load with the current page-specific scripts and styles.)
$this->addScript('jQuery', '/resources/vendor/library/jquery/jquery-3.6.4/jquery-3.6.4.min.js', 'library-for-page');
To add jQuery in HTML, do:
<script src="/resources/vendor/library/jquery/jquery-3.6.4/jquery-3.6.4.min.js"></script> <!-- jQuery -->
Licensing Info
The legal info below was current at the time of writing. Future/Newer versions may be licensed or copyrighted differently
Sizzle.js
- Sizzle.js (included inside jQuery)
- MIT License, with exception for linked node modules being licensed separately.
- Copyright (c) JS Foundation and other contributors, See https://js.foundation/
- Repo: https://github.com/jquery/sizzle/wiki
jQuery 3.6.4
- jQuery 3.6.4 (included inside pith-pack-jquery)
- Released under the MIT license. (Also Includes Sizzle.js https://sizzlejs.com/)
- Copyright (c) OpenJS Foundation and other contributors.
- Site: https://jquery.com/
jQuery 3.7.1
- jQuery 3.7.1 (included inside pith-pack-jquery)
- Released under the MIT license. (Also Includes Sizzle.js https://sizzlejs.com/)
- Copyright (c) OpenJS Foundation and other contributors.
- Site: https://jquery.com/
Ian's jQuery Toolbox
- Ian's jQuery Toolbox
- MIT license
- Copyright (c) Ian Maurmann
- Link: https://github.com/ian-maurmann/ians-jquery-toolbox
jQuery 4.0.0-beta
- jQuery 4 Beta
- Copyright (c) OpenJS Foundation and other contributors.
- Site: https://jquery.com/
pith-pack-jquery
- pith-pack-jquery
- MIT license (Matching the included jQuery and Sizzle.js)
- Copyright (c) Ian Maurmann
- Link: https://github.com/pith-front/pith-pack-jquery