Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#13 2009-09-20 11:55:13

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

Because adding domain specific compression (stripping unnecessary spacing) works better than using only generic compression (gzip), although the compression rate of gzip + space-stripping is not really a lot higher than just using gzip, which is clearly visible in the test that’s included in the topic start. When not using gzip, stripping spaces gives 8% compression, but if you are already using gzip, stripping spaces only compresses 1% more. It’s an interesting experiment, but not worth it in reality.

Offline

#14 2009-09-20 15:33:21

makss
Plugin Author
From: Ukraine
Registered: 2008-10-21
Posts: 355
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

nik.martin wrote:

I think I found out what’s up: If Site Wide Comments are on (Admin > Preferences > Basic > Accept Comments), then an <h2 id=“comment”> is placed the bottom of EVERY article, regardless if comments are on for that article or whether “One By Default” is set to No, whic it is in my site. I think this is a bug in TXP, so I’m gonna check there. Otherwise, this totally breaks ANY use of aks_header for linking to normally external file in txp.

Set (Admin > Preferences > Basic > Automatically append comments to articles? – NO)

or

Temporary solution – edit Form “comments_display” and add some if tags.
For example <txp:if_comments_allowed><h2 id="comment">....</h2></txp:if_comments_allowed>

.

.

Possible it’s TxP bug or I understand TxP logic. :(

File /textpattern/publish.php, code from function doArticle

if ($use_comments and $comments_auto_append)
{
        $article .= parse_form('comments_display');
}

Possible this code need change to:

if ($use_comments and $comments_auto_append and $thisarticle['annotate'])
{
        $article .= parse_form('comments_display');
}

Last edited by makss (2009-09-20 15:36:57)


aks_cron : Cron inside Textpattern | aks_article : extended article_custom tag
aks_cache : cache for TxP | aks_dragdrop : Drag&Drop categories (article, link, image, file)

Offline

#15 2009-09-20 15:59:12

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

I’d rather see the entire auto_append stuff removed from preferences. It’s the cause of a lot of confusion.

Offline

#16 2009-09-20 16:23:19

TheEric
Plugin Author
From: Colorado & Montana.
Registered: 2004-09-17
Posts: 573
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

ruud wrote:

Because adding domain specific compression (stripping unnecessary spacing) works better than using only generic compression (gzip), although the compression rate of gzip + space-stripping is not really a lot higher than just using gzip, which is clearly visible in the test that’s included in the topic start. When not using gzip, stripping spaces gives 8% compression, but if you are already using gzip, stripping spaces only compresses 1% more. It’s an interesting experiment, but not worth it in reality.

Any idea how much of a server drain would this plugin method present over mod_gzip? I wouldn’t imagine it to be a lot, but every bit does make a difference.

Offline

#17 2009-09-20 17:49:27

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

ruud wrote:

I’d rather see the entire auto_append stuff removed from preferences. It’s the cause of a lot of confusion.

Agreed :)

Offline

#18 2009-09-20 17:55:16

makss
Plugin Author
From: Ukraine
Registered: 2008-10-21
Posts: 355
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

TheEric wrote:

Why is this any better than mod_gzip?

aks_header stripping unnecessary spacing, that gives a few the byte of economy and much aesthetic pleasure to view of html source. :)

aks_header use same gzip compression method as mod_gzip. If you do not need strip, then use mod_gzip, because mod_gzip module of Apache and works a bit quick.


aks_cron : Cron inside Textpattern | aks_article : extended article_custom tag
aks_cache : cache for TxP | aks_dragdrop : Drag&Drop categories (article, link, image, file)

Offline

#19 2009-09-23 09:18:54

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,540
Website GitHub Twitter

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

Hi makss,

There is a problem with your plugin, i used it at my blog : info.ix-dz.com, all seems to works well, until i tried to download some files from the site, the download gives me blank files, i have thinked that it was an htaccess issue, but even with messy url it’ not work, when i desactivated your plugin, all become right!

Hope that help.
Problem occured with 4.0.6, and after upgrad to 4.2.0 the problem still the same.

Offline

#20 2009-09-23 10:19:13

makss
Plugin Author
From: Ukraine
Registered: 2008-10-21
Posts: 355
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

Dragondz wrote:

Hi makss,
There is a problem with your plugin, i used it at my blog : info.ix-dz.com, all seems to works well, until i tried to download some files from the site, the download gives me blank files

Thanks for feedback, fixed in aks_header 0.3.3a

Last edited by makss (2016-01-16 18:37:02)


aks_cron : Cron inside Textpattern | aks_article : extended article_custom tag
aks_cache : cache for TxP | aks_dragdrop : Drag&Drop categories (article, link, image, file)

Offline

#21 2009-09-30 22:48:37

nabrown78
Member
From: Northampton, MA, USA
Registered: 2006-10-04
Posts: 294
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

Zoiks! Is this plugin compatible with 4.2.0 only? When I added it to my page template (4.0.8) I get something crazy, which looks like this

What could be the problem?

Offline

#22 2009-10-01 12:37:31

makss
Plugin Author
From: Ukraine
Registered: 2008-10-21
Posts: 355
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

Zoiks! Is this plugin compatible with 4.2.0 only? When I added it to my page template (4.0.8) I get something crazy, which looks like this
What could be the problem?

Plugin work with 4.2 and 4.0.x too.
How was uploaded this picture or how was post it?

Now I upload tiger picture to twitpic.com – all ok.


aks_cron : Cron inside Textpattern | aks_article : extended article_custom tag
aks_cache : cache for TxP | aks_dragdrop : Drag&Drop categories (article, link, image, file)

Offline

#23 2009-10-01 13:28:21

nabrown78
Member
From: Northampton, MA, USA
Registered: 2006-10-04
Posts: 294
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

That is a screen snap of what my site looked like after installing aks_header. I uploaded it to twit pic just to make life easy. My question is: what am I doing wrong with the plugin to have it output a bunch of random-looking symbols?

Offline

#24 2009-10-01 14:05:03

makss
Plugin Author
From: Ukraine
Registered: 2008-10-21
Posts: 355
Website

Re: aks_header : Compress your pages on the fly. Strip white spaces + gzip

nabrown78 wrote:

My question is: what am I doing wrong with the plugin to have it output a bunch of random-looking symbols?

Possible it conflict with other plugins. :(

Please, install last version aks_header (after install plugin order must be = 1)

Put to page template

<txp:aks_header strip="0" gzip="0" /><!DOCTYPE html  . . .

and insert this code to any article

<txp:php>print_r(ob_list_handlers());</txp:php>

give me output.

Last edited by makss (2016-01-16 18:38:31)


aks_cron : Cron inside Textpattern | aks_article : extended article_custom tag
aks_cache : cache for TxP | aks_dragdrop : Drag&Drop categories (article, link, image, file)

Offline

Board footer

Powered by FluxBB