Firefox PHP

Module: Compress Javascript using Packer

Posted by Maurice Makaay 
All files from this thread

File Name File Size   Posted by Date  
compress_packer-1.0.0.tar.gz 9.1 KB open | download Maurice Makaay 03/14/2009 Read message
compress_packer-1.0.0.zip 16.9 KB open | download Maurice Makaay 03/14/2009 Read message
Module: Compress Javascript using Packer
March 14, 2009 02:20AM
This module compresses the Phorum Javascript code using Dean Edwards' JavaScript Packer algorithm. This reduces bandwidth usage and speeds up downloading of the JavaScript code.

For more information see:

Dean Edwards' website - http://dean.edwards.name/packer/
PHP implementation - http://dean.edwards.name/packer/

This module needs Phorum 5.2.11 or later to function. This is mainly because a few compabibility issues had to be fixed in the JavaScript code. If you want to try the module on an earlier version (but no earlier than 5.2.8 because of hook requirements), then apply the changes from changeset 3946 manullly to your Phorum install and delete the "require_version" line from mods/compress_packer/info.txt file.

Changelog:
----------

2008-07-23 v1.0.0

   - Initial release.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Attachments:
open | download - compress_packer-1.0.0.tar.gz (9.1 KB)
open | download - compress_packer-1.0.0.zip (16.9 KB)
Re: Module: Compress Javascript using Packer
May 20, 2010 01:01PM
Bugreport: (Phorum version 5.2.15a + packer 1.0.0)

in: include/posting/form_objects.js.php
line: 23

Language: Javascript
Phorum.textarea_range = null
should be
Language: Javascript
Phorum.textarea_range = null;



Edited 1 time(s). Last edit at 05/20/2010 01:02PM by webinn.
Re: Module: Compress Javascript using Packer
May 20, 2010 01:22PM
another not yet resolved bug report: when enabling this module, the toolbar above a message field disappears
Re: Module: Compress Javascript using Packer
May 20, 2010 02:45PM
There are probably a lot more issues when packing the javascript code. In 5.3-dev, we are writing a whole new javascript library for Phorum. In that one, we check the code using jslint, which will take care of removing all possible issues for packing. So for 5.3, javascript packing will be better. For 5.2 it will either work or not I'm afraid. It's too much lost time for me to go over all the javascript issues in that version.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: Compress Javascript using Packer
May 21, 2010 08:47PM
Both bug reports are due to the same bug, I think. At least fixing the malformed line in form_objects.php.js makes everything work for me. FWIW, since I was the contributor of form_objects.php.js, I posted a patch to it here: form_objects.php.js patch.
Re: Module: Compress Javascript using Packer
May 23, 2010 11:01PM
I added the code to the 5.2 tree.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: Compress Javascript using Packer
February 02, 2011 04:22PM
Do you know that the Editor Tools mod stops working when this JavaScript packer mod is enabled? I couldn't figure out why my toolbar wasn't showing up, then when I disabled this mod, the toolbar started working again.

I'm going to try the Yahoo version now, to see if that works better. Thanks!
Re: Module: Compress Javascript using Packer
February 02, 2011 04:30PM
Yeah, we know, since that was reported in this thread previously. Here's my comment to the bug report.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Module: Compress Javascript using Packer
February 02, 2011 04:31PM
Yep, the toolbar works when the yahoo compressor is enabled.

By the way, do you know that the toolbar isn't showing on your forum here that I'm typing in now? Maybe you are using the packer compressor, and it's disabling your toolbar?
Re: Module: Compress Javascript using Packer
February 02, 2011 05:14PM
No, that module is not enabled here. I do see the editor tools toolbar in my browser. What exact browser version are you using?


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Sorry, only registered users may post in this forum.

Click here to login