Strict Standards: Declaration of action_plugin_jquery::register() should be compatible with DokuWiki_Action_Plugin::register($controller) in /membri/only4mods/lib/plugins/jquery/action.php on line 14

Strict Standards: Declaration of action_plugin_captcha::register() should be compatible with DokuWiki_Action_Plugin::register($controller) in /membri/only4mods/lib/plugins/captcha/action.php on line 137

Strict Standards: Declaration of action_plugin_wikistatistics::register() should be compatible with DokuWiki_Action_Plugin::register($controller) in /membri/only4mods/lib/plugins/wikistatistics/action.php on line 51

Strict Standards: Declaration of action_plugin_codehighlight::register() should be compatible with DokuWiki_Action_Plugin::register($controller) in /membri/only4mods/lib/plugins/codehighlight/action.php on line 225

Strict Standards: Declaration of action_plugin_ipban::register() should be compatible with DokuWiki_Action_Plugin::register($controller) in /membri/only4mods/lib/plugins/ipban/action.php on line 60
counterize_ii_mod:en:javascript - Ema's plugins (WP, DW)

Unfortunately, some of the pages are now read-only, this because in the last few months some spammers decided to “contribute” to the wiki…
I'm trying to lock only the interested pages.


Strict Standards: Declaration of Doku_Renderer_metadata::table_open() should be compatible with Doku_Renderer::table_open($maxcols = NULL, $numrows = NULL, $pos = NULL) in /membri/only4mods/inc/parser/metadata.php on line 24

Strict Standards: Declaration of Doku_Renderer_metadata::table_close() should be compatible with Doku_Renderer::table_close($pos = NULL) in /membri/only4mods/inc/parser/metadata.php on line 24

Objective

Let counterize II works with static pages generated by plugins like WP Super Cache

How to

In order to allow CII record data also on static pages I decided to use a small trick: move the record phase from the server to the client (eheh, nothing is more false then the previous sentence :-P).

Ok here is the true trick: the hook now create only a couple of script and noscript tags, both call the same php file, and that file is the real “recorder”. In that way I can also record if javascript is active in user's browser or not.

If the tag called is script I'll echo nothing from php, if js are disabled on the client, I'll produce a small 1×1 px gif hidden with display:none in order to not touch the template. Anyway the result will be the same: an external file is called and the visitor registered. Of course that will impact on the server load…sorry, miracles are still outside my possibilities… 8-)

Coding

I'm working on it, I'll introduce changes on the next release of CII-Mod


Tools personali