I’m trying to use PFBC and am having some problems.
On one server the folder “PFBC” has been uploaded to /public_html/ and the form is rendering fine.
On the non-working server the folder “PFBC” has been uploaded to /www/htdocs/ and the form is not rendering at all and I’m getting Error 500 Internal Server Errors.
The code I am using is as follows
<?php
session_start();
include($_SERVER["DOCUMENT_ROOT"] . "/PFBC/Form.php");
$form = new PFBC\Form("TestForm", 300);
$form->addElement(new PFBC\Element\Button);
$form->render();
?>
echo $_SERVER["DOCUMENT_ROOT"] . "/PFBC/Form.php";
returns /usr/home/thin30/www/htdocs/PFBC/Form.php
and adding the following code to the Form.php file
$dir = dirname(__FILE__);
echo "<p>Full path to this dir: " . $dir . "</p>";
returns Full path to this dir: /usr/home/thin30/www/htdocs/PFBC
Can someone please tell me why the form isn’t rendering? Or point me in a direction that may be helpful?
Folder permissions on /PFBC/ are 755 (both working server & non-working server).
Yes it does. That code seems to be using name spaces which requires php 5.3 or greater.
ACtually upon looking at the google code page it looks like you can use the 2.x version without using the namespaces the example they give is: