We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 28033
    • 925 Posts
    While working on another snippet (MODxTML), I learned that I could replace specific text strings in isset values with special characters like ?, =, &, etc, like so (in the snippet template)...

    <?php
    $link = preg_replace(’/QU/’,’?’,$link);
    ?>

    Wouldn’t changing the link part to inputHandler (which is what had the no HTML can be parsed there issue), to something like this...

    <?php
    $inputHandler = preg_replace(’/IMGSTART/’,’<img src="’,$link);
    ?>

    That’s only a part of it, but you should get the idea I’m going to with this. In theory, this should allow WLPE to parse the HTML (no one in their right mind would use IMGSTART in the call), output it correctly on the user end, and it should store the HTML, not the IMGSTART text in the database. If MODx for some reason did store IMGSTART in the database, I guess that would require something to change the value when the page loads, but that shouldn’t be too hard.

    Anyways, I dunno if this idea will work or not (I’m planning on testing it later on tonight), but if Scotty or someone else with a better knowledge of the code (like pixelchutes (sp?)) knows 100% if this would work or not, feel free to reply.

    EDIT: Gah, I just remembered that in the current version, checkboxes only will save the value "on" to the database. Scotty, v1.4.0 is going to rectify this issue, right? I was able to save data like text and whatnot with PPP
      My Snippets
      -> PopUpChunk v1.0