[pmwiki-users] problem with automatic generated includes

John Rankin john.rankin at affinity.co.nz
Tue Jun 7 00:58:58 CDT 2005


On Monday, 6 June 2005 9:15 PM, Jan Jacobs <Jacobsjan at spector.be> wrote:
>problem with automatic generated includes
>Hi list,
[snip]
>Jan Jacobs
>PS: as a late remark: when I don't put in the DIV's around the
>include, markup seems ok, but with the DIV's, it screws up.
>------------------------------------------------------------------------------------------------------------------------------------------------
>Markup('calendarlist','<include',"/\(:calendarlist:\)/e","CalendarList(\$pagename)");
>function CalendarList($pagename) {
>      $r = "";
>      $date = strtotime("now");
>      $r .= "<div>(:include " . date("Ymd", $date) . ":)</div>";
>        return $r;
>}
>

Try

$r .= "<div>\n(:include " . date("Ymd", $date) . ":)\n</div>";

The 2 newlines should force correct markup processing, with luck...
-- 
JR
--
John Rankin






More information about the pmwiki-users mailing list