This forum is no longer open and is for reading/searching only.

Please use our new MachForm Community Forum instead.

MachForm Community Forums » MachForm 2

advanced code error


  1. susanfw
    Member

    I'd like to use the advanced code, but I receiving the following error when I place the code in a php page:
    Fatal error: main() [function.require]: Failed opening required '/machform.php' (include_path='.;c:\php4\pear') in D:\inetpub\pinecrestschools\pinecrest09\employment2.php on line 2

    I'm on a Windows server. I'm not sure if that's related.
    Thank you
    Susan

    Posted 15 years ago #
  2. redityo

    Hi,

    Do you embed the form in same domain with machform ? and make sure your base path value already set properly, the format should be like this :

    $mf_param['base_path'] = 'http://yourdomain.com/machform_folder/';

    or

    $mf_param['base_path'] = 'your_document_root';

    MachForm Support

    Posted 15 years ago #
  3. susanfw
    Member

    Yes, the form is in the same domain as machform. And it looks like the path is correct:
    <?php
    require("/machform.php");
    $mf_param['form_id'] = 2;
    $mf_param['base_path'] = 'http://www.pinecrestschools.com/machform/';
    display_machform($mf_param);
    ?>

    Posted 15 years ago #
  4. redityo

    it seems this line have invalid path :

    require("/machform.php");

    try to add your document root path in there, for example :

    require("D:/inetpub/pinecrestschools/machform/machform.php");

    MachForm Support

    Posted 15 years ago #
  5. susanfw
    Member

    Thank you so much. That was it.
    Susan

    Posted 15 years ago #

RSS feed for this topic

Reply