Forum
19:05
01/06/2009
Can you provide the minification script used to produce downloads for jqGrid 3.5? Right now the download page produces a zip of the minified files for jqGrid 3.5 Beta (build5), but I need some of the recent fixes that are only in GitHub. (We're just adding features that require tree grids.) I would like an easy way of producing minified files from GitHub so that I can easily track fixes. I would rather not have to swap between the loader and minified versions as fixes are released to GitHub and eventually the download page.
BTW - I tried YUI Compressor, but it fails on jquery.searchFilter.js with two illegal character and one syntax error. I'd rather not create a custom version of this file that is ammenable to minification.
Thanks, James
02:24
Moderators
30/10/2007
Hello,
Will see what I can do. The download manager is in php with a lot of modules that should be enabled.
Also I build jqGrid with YUI Compressor. In order to compress correct you should set a parameter --charset=utf-8 to the comand line of every module - i.e
java -jar yuicompressor-2.4.2.jar "grid.base.js" --charset=utf-8 -o "min\\grid.base.js"
Hope this will help
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
11:45
01/06/2009
Thanks for the quick reply, Tony. The UTF-8 flag fixed the errors. YUI Compressor should be sufficient to create minified builds for the project. No need to worry about the PHP version unless someone else needs it. For reference, here is the PowerShell command line that I'm using to compress and combine all of the JS files into a single jquery.jqGrid.min.js file:
ls .\\jqGrid\\js\\*.js | foreach { java -jar .\\yuicompressor-2.4.2.jar $_.FullName –charset utf-8 >> min\\jquery.jqGrid.min.js }
Thanks again.
16:26
10/08/2009
Hello,
in my opinion it would be gut to ask Tony to create more frequently minor jqGrid releases. For example one could create 4.4.2 now.
If you need to create jquery.jqGrid.min.js yourself you can do the following: If you would open jquery.jqGrid.min.js you will find the comment started with "* Modules:" directly at the beginning of the file. After the text "* Modules:" you will see
grid.base.js; jquery.fmatter.js; grid.custom.js; grid.common.js; grid.formedit.js; grid.filter.js; grid.inlinedit.js; grid.celledit.js; jqModal.js; jqDnR.js; grid.subgrid.js; grid.grouping.js; grid.treegrid.js; grid.import.js; JsonXml.js; grid.tbltogrid.js; grid.jqueryui.js;
It's the full list of modules of jqGrid included in the file jquery.jqGrid.min.js. You can concatinate the files from github in exactly the same order to create your version of jquery.jqGrid.src.js file.
Now you can use any minifier which you like to produce the resulting jquery.jqGrid.min.js. For example you can download Microsoft Ajax Minifier. To create jquery.jqGrid.min.js you can use
If you want you can produce minimize version of grid.locale-XX.js files in the same way. Because the files contains Unicode characters you need use additional option -enc:out utf-8 to have correctly encoded results.
You can use the same option to create jquery.jqGrid.min.js too.
If you use some plugins from plugins subdirectory you can create minified version of the files too.
Advantage of AjaxMin.exe is that it can be used not only for minification of JS files, but for minification of CSS files too. For example I use ui.jqgrid.min.css in release version of my projects created with
Best regards
Oleg
P.S. By the way the jquery.jqGrid.min.js created with respect of AjaxMin.exe is a little smaller as the original jquery.jqGrid.min.js.
Most Users Ever Online: 715
Currently Online:
31 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66