• qwertyjjj

    (@qwertyjjj)


    I am using the exec-php plugin to run PHP code on my “Pages”.
    I have uploaded a charting program called pCHart that uses code to include classes but it cannot find them.
    I tried the full relative path but even that isn;t weorking.
    What is the home path of the WordPress pages folder?

    Warning: Invalid argument supplied for foreach() in /mounted-storage/home6c/sub002/sc11883-LGVN/mysite.net/Charts/pChart/pChart.class on line 3289

    // Standard inclusions
    include(“pChart/pData.class”);
    include(“pChart/pChart.class”);

Viewing 3 replies - 1 through 3 (of 3 total)
  • GRAQ

    (@graq)

    Try something like:
    include( ABSPATH . 'Charts/pChart/pData.class" );

    Thread Starter qwertyjjj

    (@qwertyjjj)

    That seems like it’s including the file but then a load of errors are thrown presumably because the class is programmed to look in a certain folder:

    Warning: Invalid argument supplied for foreach() in /mounted-storage/home6c/sub002/sc11883-LGVN/mysite.net/Charts-pChart/pChart/pChart.class on line 3289

    These clasees work when access from mysite.net/Charts/example.php

    So, how can I get a wordpress page to run from that location? mysite.net/Charts/

    Thread Starter qwertyjjj

    (@qwertyjjj)

    When I do this:
    <?php

    // Standard inclusions
    include( ABSPATH . “Charts-pChart/pChart/example1.php”);
    include( ABSPATH . “Charts-pChart/pChart/example1.png”);
    ?>

    I get the error:
    Warning: Invalid argument supplied for foreach() in /mounted-storage/home6c/sub002/sc11883-LGVN/mysite.net/Charts-pChart/pChart/pChart.class on line 3289

    Warning: max() [function.max]: Array must contain at least one element in /mounted-storage/home6c/sub002/sc11883-LGVN/mysite.net/Charts-pChart/pChart/pChart.class on line 3300

    Warning: Invalid argument supplied for foreach() in /mounted-storage/home6c/sub002/sc11883-LGVN/mysite.net/Charts-pChart/pChart/pChart.class on line 405

    Warning: Division by zero in /mounted-storage/home6c/sub002/sc11883-LGVN/mysite.net/Charts-pChart/pChart/pChart.class on line 466

    These clasees work when accessed directly from mysite.net/Charts/example.php

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘what is the current directory path?’ is closed to new replies.