WordPress.org

Support

Support » How-To and Troubleshooting » QuickPHP and include statements

QuickPHP and include statements

  • Hi. I’m trying to get CG-QuickPHP to use a php ‘include’ statement into a post, to include a php file. I’m using the following statement, but it isn’t working (nothing is being included):

    <quickphp include(‘http://mydomain.com/dir/file.php’); />

    Is this the correct way of using quickPHP and/or the correct way of specifying the location of the normal.php file? Does QuickPHP support ‘include’? Or should I just specify a relative location, like:

    <quickphp include(‘dir/file.php’); />

    Any help would be appreciated.

    Thanks,
    Amir

Viewing 7 replies - 1 through 7 (of 7 total)
  • Well, did the second code not work? Make sure you activate the plugin.

    The first one is likely not to work because of the server security settings.

    Sorry, but from the instructions:

    it’s useful for anyone needed to call a quick function or template tag WITHIN the body of a Post or a Page.

    and from the author’s original thread…

    CG-QuickPHP does embedded PHP in a post/page, with a one-function-call restriction.

    Alphaoide: the plugin is activated, and neither version of works. any other ideas?

    Beel: I AM calling the function from within a page. what makes you I’m not?

    Moderator James Huff

    @macmanx

    Since the plugin appears to operate as a PHP interpreter, it may lack certain PHP functionalities, such as include.

    Try using a normal PHP include with this plugin activated: http://priyadi.net/archives/2005/03/02/wordpress-php-exec-plugin/

    Yes, macmanx is correct. I suggest you read the section in the instructions that came with the plugin entitled “What are its limits?”

    It is possible you can get your file.php to work but not as an include.

    Oops, hitting the spacebar when in screen saver mode evidentally adds an empty post.

    Thanks. I ended up getting phpexec and it works perfectly. thanks for the help!

    Amir

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘QuickPHP and include statements’ is closed to new replies.
Skip to toolbar