Upload blank screen..

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

Upload blank screen..

Postby jimr451 » Wed Jul 20, 2011 12:21 pm

Hi,

I posted once before on a similar issue - I'm looking for direction here.

I have a simple table, with a "Upload" field (Type = container).

When I save a record with an uploaded file, the file uploads, the record updates, but I get a "blank screen". After that, any attempt to view or edit the record results in a blank screen.

Can you give any spots where I can begin debugging this? I'm using xataface-1.3rc3, with php 5.3.6. Or is there a workaround for me to "save the file" on my own using the delegate class? I'd go that route if necessary.

-Jim
Jim Roberts
Roberts WebForge, Inc.
http://www.robertswebforge.com
jimr451
 
Posts: 20
Joined: Mon Jun 27, 2011 1:46 pm

Re: Upload blank screen..

Postby shannah » Wed Jul 20, 2011 2:37 pm

Likely there is an error happening... check your error log to see what the error is.

On a side note - I don't have any PHP 5.3.6 instances running yet. My test environments are 5.3.1 and 5.2.8 - so there is a possibility you're uncovering something new.... (but it is more likely something unrelated to the PHP version).

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

Re: Upload blank screen..

Postby jimr451 » Thu Jul 21, 2011 10:22 am

Well, the error_log shows nothing.

I did a lot of tracing, and got into the smarty template:

Dataface_View_Record.html

This line is where it dies:

Code: Select all
{record_view var=rv record=$record}


When I print out "record" the only difference between a good record (with a blank upload field) and the one that crashes, is the uploaded field:


Code: Select all
[site_logo] => Array
                        (
                            [0] => Array
                                (
                                    [0] => Array
                                        (
                                            [0] => logo.png
                                        )

                                )

                        )


Not sure if any of this gives any clue. I don't know smarty templates too well, so I don't really know where to go from here.

-Jim
Jim Roberts
Roberts WebForge, Inc.
http://www.robertswebforge.com
jimr451
 
Posts: 20
Joined: Mon Jun 27, 2011 1:46 pm

Re: Upload blank screen.. SOLVED

Postby jimr451 » Thu Jul 21, 2011 12:51 pm

Hi,

Ok, I traced the problem to not having the "fileinfo" extension on the server.

So in the Record.php, around line 2260 or so, the area where that extension is loaded, my server just bombed out with no error, just a blank screen.

My "fix" is too embarassing to post here, but if anyone else runs into this issue, i hope it points you in the right direction.

-Jim
Jim Roberts
Roberts WebForge, Inc.
http://www.robertswebforge.com
jimr451
 
Posts: 20
Joined: Mon Jun 27, 2011 1:46 pm

Re: Upload blank screen..

Postby shannah » Thu Jul 21, 2011 2:02 pm

What version of Xataface are you using?
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Upload blank screen..

Postby shannah » Thu Jul 21, 2011 2:11 pm

Thanks for posting this. It seems that the dl() function is deprecated in PHP 5.3 and is not included standard anymore. I have removed this attempt to dynamically load fileinfo in SVN. The change may make it into 1.3rc5.

(Note: You'll also need to remove a similar line in Dataface/Application/blob.php if you plan to use blob columns to store your uploads).
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Upload blank screen..

Postby jimr451 » Fri Jul 22, 2011 4:01 am

Cool I'll keep the blob thing in mind. For now i'm happy my uploads are working!

FYI, the php 5.3 also broke some other software out there, as I found when I was searching. I guess a couple functions were removed or changed.


-jim
Jim Roberts
Roberts WebForge, Inc.
http://www.robertswebforge.com
jimr451
 
Posts: 20
Joined: Mon Jun 27, 2011 1:46 pm


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 23 guests

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