Framework not visible

A place for users and developers of the Xataface to discuss and receive support.

Framework not visible

Postby hdisseldorp » Fri Feb 04, 2011 7:12 am

Hi Everyone,

I have created a smooth running applications build on xataface 1.2.6. It runs smoothly on my MacBook Pro (OS X leopard) under MAMP.
However when porting all the applications to a virtual machine running openSuSE 11.3, I ran into some problems/issues.
The following is the case:
When requesting the application i.e. http://movies.local/index.php, the browser shows the php code of my conf/ApplicationDelegate class!
The code which is displayed starts after the first -> of conf/ApplicationDelegate until the end of the file, in my case:
class conf_ApplicationDelegate {
function getPermissions($&record) {
$auth =& Dataface_AuthenticationTool::getInstance();
$user =& $auth->getLoggedInUser();
if( !isset($user) ) return Dataface_PermissionsTool::NO_ACCESS();
...
}
}

I have checked and double checked all the permissions of my application as well as from xataface-1.2.6 files and folders. In particular templates_c. This folder was empty and contains now the compiled templates of xataface, owned by the web user (which is correct). Also I see that the session data is written to /tmp as well as the cached images (also correct).

When I remove/rename the conf/ApplicationDelegate.php file. The application then displays the code of the first table which has a delegate file (*.php). I ran a little test with no .php and no .ini files (except conf.ini) in my application. The application displays the data from the same tables from the database without the framework (i.e. no images, lines, etc).

OpenSuSE environment is as follows:
OS: openSuSE 11.3 (text, no graphical interface)
configured as server (LAMP)
Apache 2.2.15 (Linux/SUSE)
PHP 5.3.3
MySQL 5.1.46

All the above is installed from the ISO download from openSuSE.org

Does anyone has a clue? I ran out of options.

Kind regards,
Harry
hdisseldorp
 
Posts: 6
Joined: Thu Aug 26, 2010 4:13 am

Re: Framework not visible

Postby shannah » Fri Feb 04, 2011 8:13 am

Either you don't have php installed or you have short open tags off. Check that your php uses the full open tag <?php and not just <?

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

Re: Framework not visible

Postby hdisseldorp » Wed Feb 09, 2011 11:36 pm

Hi Steve,

Thanks for the tip. PHP was installed, but in php.ini the short_open_tags was turned off. I guess by default openSuSE hardens the machine as of it's a production machine. Your tip solved my problem partly. The error messages (or code showing) are gone, but I still don't see the framework. For example, the data of the table tabs are shown one on each line, etc.... It reads the mysql database, the data in list view is shown with the main border. The selection boxes along with the data are output per row.

Do you have any idea what this may cause this?

Thank you in advance.

Kind regards,
Harry
hdisseldorp
 
Posts: 6
Joined: Thu Aug 26, 2010 4:13 am

Re: Framework not visible

Postby shannah » Thu Feb 10, 2011 9:52 am

SOunds like the stylesheets are not being picked up.

Check:

1. The 2nd parameter of the df_init() call in your index.php file. Ensure that it refers to the URL (relative or absolute) to the xataface directory. This is how Xataface finds the stylesheets.

2. Check to make sure that the stylesheet is readable. Try going to http://yourdomain.com/path/to/xataface/plone.css and make sure that you see the stylesheet and not a "Forbidden" message or something like that.

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

Re: Framework not visible

Postby igor-jar » Wed Jun 27, 2012 2:22 pm

Hi Steve,
The same problem here: the framework is not visible but php and mysql are ok.

shannah wrote:1. The 2nd parameter of the df_init() call in your index.php file. Ensure that it refers to the URL (relative or absolute) to the xataface directory. This is how Xataface finds the stylesheets.


This is ok.

shannah wrote:2. Check to make sure that the stylesheet is readable. Try going to ..../xataface/plone.css and make sure that you see the stylesheet and not a "Forbidden" message or something like that.


The text file is displayed correctly.

First I wanted to use the installer.php but got the same error with the login issue that is described here: viewtopic.php?f=4&t=5439
Then I used the makesite script that worked fine.
I use
Apache/2.2.16 (Debian)
PHP Version 5.3.3-7+squeeze13
MySql 5.1.63

Thanks,
Igor
igor-jar
 
Posts: 7
Joined: Wed Jun 27, 2012 2:09 pm

Re: Framework not visible

Postby igor-jar » Thu Jun 28, 2012 9:27 am

I think I got the solution. If you omit "http ://" from the full URL in the second parameter of the df_init() function in index.php file then it will handle it as a relative URL even if you specify a domain. So it will add www .yourdomain... to the application path and therefore it will create a wrong link to the plone.css file.
(As I am a new user of the forum I had to put an extra space after http and www as part of my fight with the spam filter.)

Igor
igor-jar
 
Posts: 7
Joined: Wed Jun 27, 2012 2:09 pm


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 9 guests

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