Dokuwiki: plugin ifauth patch

The patch to remove the paragraph, provided at the ifauth plugin page1), didn't work well for me. As long as the plugin will be used in a floated text block, it creates a line break. So I slightly changed the code of syntax.php:

# diff --strip-trailing-cr syntax.orig syntax.php
143,144c142,143
<     if (stristr(substr($r,-7)," \n</p>\n")) {
<       $r = substr($r,0,-7);
---
>     if (stristr(substr($r,-7),"\n</p>\n")) {
>       $r = substr($r,0,strlen($r)-6);

As I am not a php specialist I did it by try and error, but it works ;-) - at least for me on Linux. Btw I converted line endings to Unix style.

Download: Patch    (md5sum)

Update:\ I recommend to use my successor, the plugin isauth instead!

1)
as of year 2013