Browser asks how to save page or displays error message.

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

Postby Aoirthoir » Wed Oct 18, 2006 7:09 pm

This is interesting and Ive not had it happen before. Thus far just on grandpa lamp.

I have those dbf files I converted. I create an ID for them Now any time I go to view the very first record in the mysql with DF I get the browser trying to offer to save as in firefox, in IE I just get a cant display error. Now it doesnt matter what the first record is. I moved the first record by changing ID and that of course did not work. I can view that former first record as the last record without issue. But the new first record gives me the same behavior as the previous first record. I dont get this on any other records.

I will investigate tomorrow to see if I get it on other DBs....

For now I just did a save as new record in phpmyadmin, then I deleted all the data in the fields of the first record and put a big DO NOT USE in the main fields. Also I will inform my users of the error tomorrow when i start training them.

Also the error occurs no matter what the name of the php file is and whether I have an .htaccess or not.

Thank you for your consideration.
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm

Postby Aoirthoir » Wed Oct 18, 2006 7:31 pm

Okey Doke....

Well that works for the specific table. Unfortunately I get the same error on other tables. For instance if I try to click one of my relationship tabs, I get the error. I realize it is probably a mime time thing someplace in the apache setup. I've not had to deal with these before (thus my lack of knowledge about the AllowOverride that Mr. Steve explained to me yesterday). Up until now Ive just been running all of my web stuff and dataface items on either prebuilt things like XAMPP (to insecure) or my dreamhost space.

So I am assuming there is something I have to set for a mimetype or something similar to fix this..just not sure where....the pages it is trying to download are:

http://lamp-dev/estim/index.php?-table=PATDATA&-action=browse&-cursor=0&-skip=0&-limit=30&-mode=list

and

http://lamp-dev/estim/index.php?-table=PATDATA&-action=related_records_list&-cursor=1&-skip=0&-limit=30&-mode=list&-relationship=D_NOTE

But other pages work fine, like this:

http://lamp-dev/estim/index.php?-table=PATDATA&-action=browse&-cursor=1&-skip=0&-limit=30&-mode=list

(lamp-dev is the machine name)

As usual any comments, suggestions or hints are most appreciated.

Thank you kindly in advanced.
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm

Postby Aoirthoir » Wed Oct 18, 2006 7:48 pm

Definitely something on the server end. I just uploaded the DF app to my dreamhost and a few records from the DB and it worked fine.
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm

Postby shannah » Wed Oct 18, 2006 11:25 pm

Check out step #11 at
http://dan.drydog.com/apache2php.html

Basically you just need to add php as a type so the server knows how to handle it.

This should get you going.

Best regards

Steve
--
Steve Hannah
@shannah78 (on twitter)
sjhannah.com blog
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby Aoirthoir » Thu Oct 19, 2006 7:53 am

Thanks for the advice Mr. Steve.

Gave a bit of it a try but then the system broke. I am able to access most php pages. Just that anything with skip=0 was giving me an error...for now i am bringing up the puppy xampp so I can train my users and then I will figure this out..thanks for the help bro.
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm

Postby Aoirthoir » Thu Oct 19, 2006 12:55 pm

Ok busy day so Ive been trying to track this inbetween..going to hit it now furiously...

But to update, I tried the same thing in Xampp on puppy and got the same error. I dont get it with all the databases just with the one that gots almost 40 thousand records. My LCMS runs without any errors at all as does my IBPM. Its just this particular one. When I run on my dreamhost..again no errors...all my other php files go through fine.

So I am wondering....is it possible that there is a hangup with the records on the mysql...since there are so many it is taking a LONG time to process them..up to seven seconds (on my dreamhost its taking no more than two seconds most times)...so could it be that the grandmalamp is so slow it just is timing out without handing the proper headers?

I'm wondering about this because....all of the other php files are definitely being parsed by the php application..as in fact is the public.php in lcms, and index.php in my app..I only get the error on the first record...

So in theory I assume..but am not one hundred percent sure..that if php files are being parsed..it might be an error in another area?

Thanks kindly in advance.
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm

Postby shannah » Thu Oct 19, 2006 1:44 pm

It's hard to say, here. It still sounds like some apache setting most likely.. but it would be interesting to see the raw http request/response headers that are sent.
You can do this via telnet:

http://evolvedcode.net/content/doc_alttelnet/index_p2.asp


You would start off by typing:
Code: Select all
telnet yourdomain.com 80


Then type:

Code: Select all
GET /path.to.your.app/index.php?-skip=0&-table=foo HTTP/1.0


And hit enter twice.

This should give you some output and hopefully some clues as to what is happening.

-Stevec
--
Steve Hannah
@shannah78 (on twitter)
sjhannah.com blog
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby Aoirthoir » Thu Oct 19, 2006 3:45 pm

Mr. Steve,

Well, I attempted the things you suggested and it needed me to log in. (I kept getting that information in the html output). So I just commented out the [_auth] section and did a mv conf conf.on.hold. Anyhow then I clicked it to get the error and I was able to access the first record no problem. So I am assuming somewhere Ive got an error in my Application Delegate class...I am pasting the entire thing here..but if you like I will delete sections of it later to clean up this post....and I am going to examine that and my conf.ini and see if I am missing something just in case...however it is the same file I am using in the other apps...

also of course..if I remove the auth....I dont get the error..and since I cant auth in telnet..i cant get the error in telnet...hope that makes sense...so here it is:

getLoggedInUser();
if ( !isset($user) ) return Dataface_PermissionsTool::NO_ACCESS();
// if the user is null then nobody is logged in... no access.
// This will force a login prompt.
$role = $user->val('ROLE');
return Dataface_PermissionsTool::getRolePermissions($role);
// Returns all of the permissions for the user's current role.
}

function block__html_title(){
echo "Electrical Stim Department AMP Modules";

}


}
?>


Also I verified and there are no blank spaces or blank lines at the end of the file...
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm

Postby Aoirthoir » Thu Oct 19, 2006 3:57 pm

Also just for consistency Im pasting the conf.ini.

It is a copy from the IBPM as is the above application delegate class....thus the reason for all the copyright info...but I am pasting in full just to verify no errors...also if there is a way to auth within telnet...I can do so and see if the error repeats

Thanks again for the help.

; File:ibpm/conf.ini

; Description:

; ------------

; This file contains configuration information for the dataface framework.

; Configuration options include such things as database connection information

; tables to be displayed in the menu, and behavioral and display characteristics

; of the dataface application (like whether to display the menu).

;

;Itty Bitty Project Manager

;Copyright (C) 2006 Advanced Medical Support Services and

;Joseph James Frantz (boscagarda-programming@yahoo.com)

;

;This program is free software; you can redistribute it and/or

;modify it under the terms of the GNU General Public License

;as published by the Free Software Foundation; either version 2

;of the License, or (at your option) any later version.

;

;This program is distributed in the hope that it will be useful,

;but WITHOUT ANY WARRANTY; without even the implied warranty of

;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the

;GNU General Public License for more details.

;

;You should have received a copy of the GNU General Public License

;along with this program; if not, write to the Free Software

;Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.





;Specify how to access your MySQL database here.

[_database]

host = "mysql-dev"

user = "admin"

password = "admin"

name = "amp_medactimport"



;These are the tables needed for your project.

;Notes and Suggestions are not critical and may be

;removed. If they are then tables/D_TASK/relationships.ini

;must be modified to remove references to D_NOTE and D_SUGGESTION.

;Further, in windows these files are not case sensitive.

;In any variant of Unix (including Mac and Linux) they are

;case sensitive. To simplify things, they have been labelled here

;in all caps, and are so in the Create Table statements in

;the .SQL file provided with this package.

[_tables]

PATDATA = "Patients"

;****************************

;IMPORTANT NOTE

;****************************

;This should probably be removed in your app.

;We have it in ours for testing purposes. If you

;have created a full fledged user management

;system or you have a seperate itty bitty UM

;system, then there is absolutely no need for

;this next line. If you do have an itty bitty

;UM module, I am interested in it if it is

;DF based and GPLed.

S_USER = "Users"



;This provides the user authentication. If a different table is used in

;your system, then change the references to

;S_USER and USERNAME and PASSWORD as needed.

;[_auth]

;users_table = S_USER

;username_column = USERNAME

;password_column = PASSWORD



;This enables the History feature of Dataface. To disable

;simply set enabled = 0 or delete this section.

;It is best to keep it though, as all changes to the tables

;will be tracked and can be restored at any time.

[history]

enabled = 1
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm

Postby Aoirthoir » Thu Oct 19, 2006 4:44 pm

Mr. Steve,

I'm not sure if this is the information you are looking for or not..I installed the Tamper Data extension for Firefox. It lets me see the headers from the http (I think)...so this is the initial paste from the error screen when I am logged in: (turned on the auth again so I could test this)

19:37:22.001[1844ms][total 1844ms] Status: 200[OK]
GET http://lamp-dev/estim/index.php?-table=PATDATA&-action=browse&-cursor=0&-skip=0&-limit=30&-mode=list Load Flags[LOAD_DOCUMENT_URI LOAD_INITIAL_DOCUMENT_URI ] Content Size[-1] Mime Type[application/x-unknown-content-type]
Request Headers:
Host[lamp-dev]
User-Agent[Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.7) Gecko/20060909 Firefox/1.5.0.7]
Accept[text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5]
Accept-Language[en-us,en;q=0.5]
Accept-Encoding[gzip,deflate]
Accept-Charset[ISO-8859-1,utf-8;q=0.7,*;q=0.7]
Keep-Alive[300]
Connection[keep-alive]
Referer[http://lamp-dev/estim/index.php]
Cookie[dataface__lang=en; PHPSESSID=56c0b05c561aec87b2efb71936bba0bd]
Response Headers:

(There is the mime type thing again..)

I think you are right in it being a setting....so I am going to just have to start hunting..for now its all on my servers. Also I am looking at the virtual appliances ( http://virtualappliances.net/ ) since the mysql seems to work pretty decently..they are working on an apache vm as well..

Anyhow Im going to keep trying to bugger down and figure it out and appreciate the help.

Thanks kindly
Aoirthoir
 
Posts: 420
Joined: Wed Dec 31, 1969 5:00 pm


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 34 guests

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