Post Installation - Fatal error: Class 'Dataface_Error' ...

A place to discuss and receive support for the Library DB application.

Post Installation - Fatal error: Class 'Dataface_Error' ...

Postby pepo80 » Tue Jul 22, 2008 8:13 am

Hi,

after the mysql's version problem i move my site into another hosting (php 5 and mysql 5.xx)

and i obtain this error (after create the db and the tables follow the install.php instructions):

Code: Select all
Fatal error: Class 'Dataface_Error' not found in xxxxx/xxxx/xxxx/xxx/public_html/dataface/Dataface/Application.php on line 620


the path xxx/xxx/ it's hide for security reason

i obtain the same error if i try php4 and mysql 5...
pepo80
 
Posts: 5
Joined: Wed Jul 16, 2008 8:43 am

Postby shannah » Tue Jul 22, 2008 3:43 pm

Check the file permissions on the files you copied over. Also make sure that all of the files copied over ok.

This particular error is caused by either:
1. the file Dataface/Error.php is missing
or
2. the file Dataface/Error.php is unreadable by the web server (i.e. the permissions are something like 0700).

-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby pepo80 » Thu Jul 24, 2008 8:06 am

First of all: thank's for support

I have the file error.php in dataface\Dataface\error.php. The permission of files and folders in all web spaces are 644 (automatic assigned by hosting-server) i must change this in 755 ? for all files and folders ?

Many, many 10x...
pepo80
 
Posts: 5
Joined: Wed Jul 16, 2008 8:43 am

Postby shannah » Fri Jul 25, 2008 4:18 pm

I discovered that this is actually bug which pops up with certain server configurations. I have applied the fix in SVN.

Download this file
http://weblite.ca/svn/dataface/core/tru ... cation.php

And replace your current dataface/Dataface/Application.php with it, and it should get it working.

The problem is that Xataface can't find your server's temp directory (usually on unix it is /tmp, but other configurations may have different locations.

-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby pepo80 » Mon Jul 28, 2008 9:30 am

Hi Steve,

tenks for all the replay...

I have download the new version of application.php and upload them to the folder ... now i see an alternative errors:

Configuration Required

Dataface was unable to create the directory '/tmp/php/sess4//dataface' to store its session files.
Possible reasons for this:

* The script does not have permission to create the directory.
* The server is operating in safe mode.


i try library db on a free web server. I can't change safe-mode config, i have only ftp access and a little panel where i can change php version...

i have created the /tmp/php/sess4/dataface folder, and assign 777 permission (for any folder)... but the error persist...

There's a solution? Where can i test? (a web server with correct configuration?)
pepo80
 
Posts: 5
Joined: Wed Jul 16, 2008 8:43 am

Postby shannah » Mon Jul 28, 2008 4:03 pm

Hi
Looks like your server is still having trouble finding the temp dir properly. I have made some changes again to Application.php. Try downloading them here

http://weblite.ca/svn/dataface/core/tru ... cation.php

-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby aidan » Thu Oct 09, 2008 1:21 am

Hello Steve & All,

I found this thread because I experienced the same problem. I updated Application.php to the version posted here. It got me past the 1st problem (Fatal error: Class 'Dataface_Error' not found in...) but now I get:

Configuration Required

Dataface was unable to create the directory '/var/lib/php5/5c0d1584db6dca2105873f2314f544c0' to store its session files.
Possible reasons for this:

* The script does not have permission to create the directory.
* The server is operating in safe mode.

Possible Solutions for this:

* Make the /var/lib/php5 writable by the web server. E.g. chmod 0777 /var/lib/php5.
* Manually create the '/var/lib/php5/5c0d1584db6dca2105873f2314f544c0' directory and make it writable by the web server.
* Change the session save path to a directory to which you have write permissions by adding the following to the beginning of your application's index.php file:

session_save_path('/path/to/dir');

* If none of these solves the problem, visit the Dataface forum at http://fas.sfu.ca/dataface/forum and ask for help.

Debugging Information:
On line 675 of file /var/www/vhosts/cultures.cawthron.org.nz/httpdocs/xataface/Dataface/Application.php in function printStackTrace()
On line 1403 of file /var/www/vhosts/cultures.cawthron.org.nz/httpdocs/xataface/Dataface/Application.php in function startSession()
On line 5 of file /var/www/vhosts/cultures.cawthron.org.nz/httpdocs/admin/index.php in function display()


By the way, I do not have shell access to the server, just FTP and Plesk access.

Any help appreciated.

Regards,
Aidan Curran
aidan
 
Posts: 11
Joined: Thu Oct 09, 2008 1:15 am
Location: New Zealand

Postby shannah » Fri Oct 17, 2008 8:10 am

You may want to check and see if your server runs in Safe mode. Safe mode screws up permissions so Xataface can't run properly.

The error indicates that you don't have write permission to the specified session directory. You could (using FTP) go in and try to explicitly change the permissions to 777. Or you could specify a different session directory in the beginning of the index.php file:
Code: Select all
session_save_path('/path/to/directory/that/you/can/write/to');


-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby aidan » Sun Oct 19, 2008 3:55 pm

Hi Steve,
Safe mode was the problem - I had my hosting company turn off safe mode and it worked fine.

Thanks - Aidan
aidan
 
Posts: 11
Joined: Thu Oct 09, 2008 1:15 am
Location: New Zealand

Re: Post Installation - Fatal error: Class 'Dataface_Error' ...

Postby ebookbox » Sun May 09, 2010 6:27 pm

hello Steve

i was also running in Fatal error: Class 'Dataface_Error'
after installation.
after reading this threat
i changed the
/users/myusername/librariandb-0.2/dataface/Dataface/Application.php
with the "new" at
http://weblite.ca/svn/dataface/core/tru ... cation.php
i added to my user dir:
/home/fh/users/i/s/myusername/www/
a temp dir
/home/fh/users/i/s/myusername/www/temp/
("userroot"/temp/)
altered
/users/myusername/librariandb-0.2/index.php
like this
----file:index.php----start
<?php
session_save_path('/home/fh/users/i/s/myusername/www/temp/');
$install = false;
.......following lines not listet.........

and it runs well till to the book list screen
named : books - Dataface Application
on a server at save mod

thanks ebookbox
ebookbox
 
Posts: 4
Joined: Sun May 09, 2010 4:36 pm

Re: Post Installation - Fatal error: Class 'Dataface_Error' ...

Postby ebookbox » Sun May 09, 2010 7:40 pm

hello Steve

after a bright sunbeam here comes a cloud:

as admin:
after set altering record 1 :A Harmony of Samuel, Kings, and Chronicles
i got this meassages several times (33x repeated):

Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/share/pear/Dataface/FormTool/textarea.php) is not within the allowed path(s): (/home/fh/users/i/s/myusername/www:/home/tmp/php) in /home/fh/users/i/s/myusername/www/librariandb-0.2/dataface/Dataface/FormTool.php on line 629

start altering
cause:

Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/share/pear/Dataface/FormTool/static.php) is not within the allowed path(s): (/home/fh/users/i/s/myusername/www:/home/tmp/php) in /home/fh/users/i/s/myusername/www/librariandb-0.2/dataface/Dataface/FormTool.php on line 629

Warning: Cannot modify header information - headers already sent by (output started at /home/fh/users/i/s/myusername/www/librariandb-0.2/dataface/Dataface/FormTool.php:629) in /home/fh/users/i/s/myusername/www/librariandb-0.2/dataface/actions/edit.php on line 188

maybe the colon after www is the reason?

creating a new record is also not possible same reason?

Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/share/pear/Dataface/FormTool/static.php) is not within the allowed path(s): (/home/fh/users/i/s/myusername/www:/home/tmp/php) in /home/fh/users/i/s/myusername/www/librariandb-0.2/dataface/Dataface/FormTool.php on line 629

Warning: Cannot modify header information - headers already sent by (output started at /home/fh/users/i/s/myusername/www/librariandb-0.2/dataface/Dataface/FormTool.php:629) in /home/fh/users/i/s/myusername/www/librariandb-0.2/dataface/actions/new.php on line 156

is it possible to remove the colon after www ?
in order to make it run in save mode !

please ebookbox
ebookbox
 
Posts: 4
Joined: Sun May 09, 2010 4:36 pm

Re: Post Installation - Fatal error: Class 'Dataface_Error' ...

Postby shannah » Sun May 09, 2010 8:40 pm

Hi. The problem would appear to be the open_basedir restrictions. Why is it looking in the /usr/local/share/pear for Dataface files? Is this a shared server or do you run it? You either need to add /usr/local/share/pear to your open_basedir directories or remove it from your include path.

-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Post Installation - Fatal error: Class 'Dataface_Error' ...

Postby ebookbox » Sat May 15, 2010 5:30 am

hello Steve
didn't expect your answer so fast.

shannah wrote:The problem would appear to be the open_basedir restrictions. Why is it looking in the /usr/local/share/pear for Dataface files?


i don't know (i am a lamer) http://en.wikipedia.org/wiki/Lamer

shannah wrote: Is this a shared server or do you run it?


i use it on a shared server in save mode
i am allowed to write/alter files at (my user account only...)
/home/fh/users/i/s/myusername/www/...

shannah wrote:You either need to add /usr/local/share/pear to your open_basedir directories or remove it from your include path.


where is the file to alter?
where is "open_basedir directories" ?
where is "include path"?
is it in the dataface directory or unreachable for me on the server?

thanks for you fast support
ebookbox
ebookbox
 
Posts: 4
Joined: Sun May 09, 2010 4:36 pm

Re: Post Installation - Fatal error: Class 'Dataface_Error' ...

Postby shannah » Sat May 15, 2010 8:29 am

i use it on a shared server in save mode


Do you mean safe mode? That would be the problem. Xataface won't run in safe mode because it needs to be able to write its cached smarty templates, and safe mode messes with the permissions on this. Safe mode is really a thing of the past and is set to be removed as of PHP 6. Most web hosts now have more reliable security measures at the OS level that render safe mode unnecessary.

-Steve
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Post Installation - Fatal error: Class 'Dataface_Error' ...

Postby ebookbox » Wed May 19, 2010 2:23 pm

Hello steve

i gave Library DB (xataface) a last try, and updated the
/librariandb-0.2/dataface/ directory with the new "xataface-1.2.4" version

i renamed the /xataface-1.2.4/ directory to /dataface/ and copied it to

/librariandb-0.2/ in order to replace /librariandb-0.2/dataface/

no i am able of creating and altering database entries.

The Sun is rising

thanks steve

i am suggesting updating the Library DB download file also.

p.s
by the way is it possible to create a user, who is able to create but not to alter or delete an database entry?
ebookbox
 
Posts: 4
Joined: Sun May 09, 2010 4:36 pm


Return to Library DB Discussion

Who is online

Users browsing this forum: No registered users and 10 guests

cron
Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved