FAcebook include php script instead of php output

I’m using WordPress 3.8, and i have a page with insert php plugin.
The page works correctly, when it’s called from the main site.
Inside the wordpress page there is written:

[insert_php]
require("{$_SERVER['DOCUMENT_ROOT']}/podcast_manager.php");
[/insert_php]

But when I post the link on facebook, it outputs this:

Read More

http://snag.gy/3MCb2.jpg

Outputting php code, instead of running it!

Really I do not know why !

Related posts

Leave a Reply

1 comment

  1. What is happening is that the php code is in the body of the WordPress post/page. That creates a description (static text) that FB then reads, sort of like Facebook Open Graph.

    To try to see if that is the problem, try creating a custom description by using a SEO plugin. Otherwise the PHP code is executing fine, it is just a description issue that FB reads from the header.

    EDIT

    View source of your post/page and see if the <meta
    name="description" content="">
    holds that php string in it.