In-Portal Issue Tracker - In-Portal CMS
Viewing Issue Advanced Details
1442 [In-Portal CMS] Optimization task always 2012-11-12 00:10 2012-12-03 09:24
Dmitry  
alex  
normal  
resolved 5.0.0  
fixed  
 
none 5.3.0-B1  
https://groups.google.com/d/topic/in-portal-bugs/4a-oJAJ264w/discussion
Removed "Compress Compiled PHP Templates" functionality
1
0001442: Remove "Compress Compiled PHP Templates" functionality
In recent years we have added a new feature (enabled via Admin setting) that allows Admin user to "Compress Compiled PHP Templates" thinking to secure the compiled PHP code and greatly benefit from it.

However as time went by we have notice that this feature actually created multiple issues that we have recently came across. Below is a list of discussion where we talked about this issues cased by this particular feature:

Getting out of memory error, when "Compress Compiled PHP Templates" setting enabled - details in additional info field

Fatal Error when using Tags with <? in Templates - details in additional info field

Discussion "Getting out of memory error, when "Compress Compiled PHP Templates" setting enabled:

At some point of In-Portal life (can't really find when) we've added functionality that allows to compress PHP files in /system/cache folder.
Doesn't really give any performance benefit and it's only used to prevent attackers on a shared hosting to easily edit these PHP files (since they are located in publicly writable folder) and make it's data to be shown instead actual website.

Functionality described above is enabled by "Compress Compiled PHP Templates" configuration variable (in database "UseTemplateCompression"), which is disabled by default by the way.


Fatal Error when using Tags with <? in Templates:

Looks like we have quite an interesting bug when we get Fatal Error from Parse when trying to using put custom tags that start <?.

Here is an example:

<?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?>

Error, that I get is:

Parse error: syntax error, unexpected T_STRING in [path to template.php] on line 12
patch remove_compiled_template_compression.patch (17,605) 2012-12-03 09:21
http://tracker.in-portal.org/file_download.php?file_id=1871&type=bug
Issue History
2012-12-03 09:24 alex Note Added: 0005302
2012-12-03 09:24 alex Status reviewed and tested => resolved
2012-12-03 09:24 alex Fixed in Version => 5.3.0-B1
2012-12-03 09:24 alex Resolution open => fixed
2012-12-03 09:24 alex Assigned To !COMMUNITY => alex
2012-12-03 09:24 alex Changeset attached 5.3.x r15640
2012-12-03 09:23 alex Note Added: 0005301
2012-12-03 09:23 alex Status needs testing => reviewed and tested
2012-12-03 09:23 alex Assigned To => !COMMUNITY
2012-12-03 09:23 alex Developer => alex
2012-12-03 09:23 alex Status active => needs testing
2012-12-03 09:21 alex File Added: remove_compiled_template_compression.patch
2012-12-03 09:13 alex Relationship added child of 0000182
2012-11-12 00:11 Dmitry Reference [/url] => [url]https://groups.google.com/d/topic/in-portal-bugs/4a-oJAJ264w/discussion
2012-11-12 00:10 Dmitry New Issue
2012-11-12 00:10 Dmitry Reference => [url][/url]
2012-11-12 00:10 Dmitry Change Log Message => Removed "Compress Compiled PHP Templates" functionality
2012-11-12 00:10 Dmitry Estimate Points => 1

Notes
(0005301)
alex   
2012-12-03 09:23   
Will test all together later.
(0005302)
alex   
2012-12-03 09:24   
Fix committed to 5.3.x branch. Commit Message:

Fixes 0001442: Remove "Compress Compiled PHP Templates" functionality