Skip to content

including php code? #1

@githubertus

Description

@githubertus

The component description says:
.... that would allow us to insert HTML or PHP on the sidebars

PHP doesn't work for me. Can't find no code to inject sidebar php to the server's interpreter neither.

[edited]
just found some interesting solutions on http://stackoverflow.com/questions/4389361/include-code-from-a-php-stream

and changed html_sidebar_output like:
$tmpout = html_entity_decode($text, ENT_COMPAT, 'utf-8');
include "data://text/plain;base64,".base64_encode($tmpout);

It's working! No issues with mixed html/php like:
underline


no underline

Main problem: Most servers have 'allow_url_include' turned off, and it needs to be turned on
Another one: we can expect a lot more "help, I'm getting a blank page" support cases. :))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions