Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Transmogrifier & PreviewPost Extension

edited November 2006 in Vanilla 1.0 Help
These are quotes from the Transmogrifier thread
My only suggestion for improvement, would be better compatibility with the "Preview Post" extension - the one that puts the "Preview Post" button under the comment field. For some reason, the text displayed in the Preview is not transmogrified.
That would require a modification of PreviewPost, though not a difficult one.
As bergamot seems to be not here anymore (unfixed listbug in BetterBBCode Extension, no answers to questions, ...) I hope someone around here knows how to modify one of these two extensions (mentioned in the title) so that smileys will also be transmogrified when a posting is previewed.

Any help is appreciated



  • Options
    Any chance I'll get some help on this? Who's the right person to speak to? As far as I understand it (following bergamots comment) this should be a small modification within the PreviewPost extension, shouldn't it?
    So "SirNot" should be the man to talk to?
  • Options
    NickENickE New
    edited November 2006
    Remove this condition in Transfmogrifier/default.php:if (in_array($Context->SelfUrl, array("comments.php","search.php"))) (and the braces, although not technically necessary).
  • Options
    edited November 2006
    You mean it that way?

    ... } if (in_array($Context->SelfUrl, array("comments.php","search.php"))) { // Instantiate the formatter and add it to the context object's string manipulator $Transmogrifier = $Context->ObjectFactory->NewObject($Context, "Transmogrifier"); $Context->StringManipulator->AddGlobalManipulator("Transmogrifier", $Transmogrifier); } ?>

    ... } // Instantiate the formatter and add it to the context object's string manipulator $Transmogrifier = $Context->ObjectFactory->NewObject($Context, "Transmogrifier"); $Context->StringManipulator->AddGlobalManipulator("Transmogrifier", $Transmogrifier); ?>
  • Options
    Yes, that should work.
  • Options
    This results in an error

    Warning: file(./extensions/Transmogrifier/config.txt) [function.file]: failed to open stream: No such file or directory in /********/extensions/Transmogrifier/default.php on line 29

    Warning: reset() [function.reset]: Passed variable is not an array or object in /********/extensions/Transmogrifier/default.php on line 32

    Warning: Invalid argument supplied for foreach() in
    /********/extensions/Transmogrifier/default.php on line 34

    Warning: preg_replace() [function.preg-replace]: Empty regular expression in /********/extensions/Transmogrifier/default.php on line 56
  • Options
    Ack, it uses a relative path.

    Replace the string literal"./extensions/Transmogrifier/config.txt" with $GLOBALS['Configuration']['EXTENSIONS_PATH'].'Transmogrifier/config.txt'
  • Options
    edited November 2006
    Works like a charm. :) Thx very, very much SirNot
This discussion has been closed.