Forums

[resolved] PHP not working in sidebar (3 posts)

  1. fishgun
    Member
    Posted 1 year ago #

    I've tried various php sidebar widget plugins (exec-php, Samsarin PHP etc) and none of them seem to want to execute the PHP code.

    I've had these plugins working, with the code I want to use, on a copy of my wordpress site on a different server.

    I've checked the php code on it's own in Safari and Firefox and it works fine.

    Any ideas?

  2. Mark / t31os
    Moderator
    Posted 1 year ago #

    Open the sidebar file and put the PHP directly in there, avoiding the need to use one of those plugins?

  3. fishgun
    Member
    Posted 1 year ago #

    Thanks for the response Mark.

    That would normally be my first workaround, but my current site is using the Thesis theme, which doesn't have a sidebar.php file, or a header.php even.

    I've subsequently solved the error, which was a result of the new server having PHP5 set to disable the include function for remote files - a very useful security measure but had me banging my head against the wall for several hours!

    This blog post gives an explanation and a couple of workarounds, if anyone else needs help with this issue.

Topic Closed

This topic has been closed to new replies.

About this Topic