Conecting to a remote mysql host in conf.ini
Archived from the Xataface Users forum.
razvanrusu — Sun Feb 08, 2009 5:31 am
Hi everyone
I’m trying to set-up xataface for a web host that has the database server on a different host (not localhost)
When configuring conf.ini for the database I get a blank page. (I use Firefox on a MAC. I also tried Safari)
The configuration file looks like that:
- Code: Select all
- `;;Configuration settings for application
title=”test_mini”[_database]
host=”mysql5.hostbase.net”
name=”test_mini”
user=”user”
password=”password”[_tables]
utilizator = “Utilizator”
categorii = “Categorii”
produs = “Produs”`
Is Dataface working only for localhost?
I tried the a resembling configuration for another server and I get the same results.
Can someone help me? As soon as possible? If I don’t fix this in fast (one or two days), I’ll have to think at another possibility, and I don’t wanna do that.
Thank you in advance.
shannah — Sun Feb 08, 2009 8:31 am
Blank screen means you’re getting an error somewhere. Check your error log. Xataface will work perfectly well with a remote database.
-Steve
razvanrusu — Wed Feb 11, 2009 10:54 am
Hi everyone.
I checked the error log, corrected some configuration path.
I managed to connect to the database but now I have another problem. I have the same blank screen.
When I checked the error log I got this:
- Code: Select all
[Wed Feb 11 19:41:48 2009] [error] [client 93.122.210.22] PHP Warning: Smarty::include() [<a>function.include</a>]: Failed opening '/var/www/vhosts/bidminwin.com/httpdocs/xataface-1.1.3/Dataface/templates_c/dataface/%%E4^E4B^E4B41A3D%%Dataface_List_View.html.php' for inclusion (include_path='.:/var/www/vhosts/bidminwin.com/httpdocs/xataface-1.1.3:/var/www/vhosts/bidminwin.com/httpdocs/xataface-1.1.3/lib:') in /var/www/vhosts/bidminwin.com/httpdocs/xataface-1.1.3/lib/Smarty/Smarty.class.php on line 1258
I have configured 0777 for templates_c. It makes a directory called dataface that has apache as owner. In that directory are some files but their size is 0. As I told you, this is a virtual host, and I don’t have access to command line, nor superuser privileges, only ftp, and a visual interface for some additional services.
Thank you for your answer.
Have a good day
Razvan
shannah — Wed Feb 11, 2009 1:15 pm
Check if PHP is running in safe mode.
You can do this by creating a php script with the following contents:
- Code: Select all
<?php phpinfo();
And navigate to it in your web browser - and look at the line that talks about safe mode.
Note that safe mode is deprecated and has been removed as of PHP 6.0 (http://ca2.php.net/safe_mode).
Unfortunately safe mode messes with directory creation so Xataface cannot work under it.
Other than that, I’d suggest deleting all of the files in your templates_c directory and try again to see if the problem still exists.
-Steve
razvanrusu — Wed Feb 11, 2009 4:19 pm
Unfortunately safe mode is on. I guess I’ll have to think of another way to deal with the project.
But I’m still using xataface for another project I’m working on. And I might ask some questions if I get into trouble.
Thank you for your help.