[pmwiki-users] initialize input textarea

Petko Yotov 5ko at free.fr
Thu Apr 5 12:16:58 CDT 2007


On Thursday 05 April 2007 16:54, Hans wrote:
> Thursday, April 5, 2007, 3:36:19 PM, SteP wrote:
> > I use a PTV to initialize the
> > textarea within a fox form. Posting the fox form saves the new text into
> > the same PTV.
>
> How does this work? Can you post multi-line text from a textarea into
> a PTV? I thought you can only use single lines for PTVs.
>

The form (:pagetextvar:some value:) can be multiline as of lately. It is 
slightly more compicated to change than for the other types of PTV:

    $page['text'] = str_replace("(:$myPTV:$oldPTVvalue:)",
       "(:$myPTV:$newPTVvalue:)", $page['text']);

Make sure $newPTVvalue contains no ":)".

Petko





More information about the pmwiki-users mailing list