[Pmwiki-users] own special markups are causing <pre > statementsin the html output

Steven Leite steven_leite
Thu Apr 29 21:15:39 CDT 2004


> So, if the [[x-include:]] markup returns something that begins with a
> whitespace character and isn't saved via the Keep() function, then PmWiki
> is going to treat the result as preformatted text.

Since the last version, all output is saved via the Keep() function.  I
think the problem might be as you suggested, the user might be putting
whitespace before the [[x-include:]] directive.  That's the only way I could
reproduce the phenomena on my system.

> Beyond these suggestions I'd have to look at the code for [[x-include:]]
> before I could say what is actually causing the results you're seeing.

Please feel free.  It's very simple code, won't take but a minute.  I'd be
happy to hear any suggestion for optimization as well.

I'm thinking about adding a "$AllowedDomains" variable so that some people
can use it on their site without worrying that somebody will [[x-include:]]
a bad/dangerous website.  Is there any demand for that?

--S


On Thu, Apr 29, 2004 at 09:39:35PM -0700, Steven Leite wrote:
>
>    Check  to  see  what  version you are using.  (See History in the .php
>    file  itself).   The latest version was updated April 6, 2004.  If you
>    are running a later version, then try the new version.  (It's attached
>    to this message for convenience).
>
>
>
>    I'm  running  the script on my system, and when I view source, there's
>    no <pre> tags.  Only a <div> tag.
>
>
>
>    If  you  need  further  assistance, send me a link that I can look at.
>    (You can send it to me privately if you want).
>
>
>
>    -S
>
>    ----- Original Message -----
>
>    From: [1]Peter Heuchert
>
>    To: [2]PmWiki-users
>
>    Sent: Thursday, April 29, 2004 7:12 AM
>
>    Subject:  Re:  [Pmwiki-users]  own  special markups are causing <pre >
>    statementsin the html output
>
>      Hi Marcus,
>      yes this is working. Thank you. But it does not solve my problem.
>      Sorry.   The  iframe  was no problem for me, because I do include a
>      page
>      which  is build with some server side includes running some scripts
>      on
>      the server. Guess nothing was can't be solved with PHP but I just
>      reworked the site to PmWiki and did not start to learn PHP yet.
>      I tried some variations of the x-include hack to define some html
>      statements as I noticed the <pre> behaviour.
>      I  guess  it  is  a  result  of  the  way  the  code is returned to
>      PmWiki.
>      [[x-include:....]]   is  using  a  function which returns a string.
>      Looks
>      like PmWiki
>      does take it as preformated text out of any reason.
>      Peter
>      Marcus Brauer schrieb:
>      > ....
>      > Please give it one more chance:
>      >
>      > $InlineReplacements["/\[#htmlinc:(.*?)#\]/e"] =
>      > "implode('',file(\"$1\"))";
>      >
>      > I tested the line above and it worked for me.
>      >
>      > --
>      > Marcus
>      >
>      >
>      --
>      Pmwiki-users mailing list
>      [3]Pmwiki-users at pmichaud.com
>      [4]http://pmichaud.com/mailman/listinfo/pmwiki-users_pmichaud.com
>
> References
>
>    1. mailto:lists at pjsc.de
>    2. mailto:Pmwiki-users at pmichaud.com
>    3. mailto:Pmwiki-users at pmichaud.com
>    4. http://pmichaud.com/mailman/listinfo/pmwiki-users_pmichaud.com


> -- 
> Pmwiki-users mailing list
> Pmwiki-users at pmichaud.com
> http://pmichaud.com/mailman/listinfo/pmwiki-users_pmichaud.com




More information about the pmwiki-users mailing list