Search string too long, giving blank result

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

Search string too long, giving blank result

Postby corestat.consulting » Sat Apr 19, 2008 3:43 am

Hello!

Some of my table's search action gives blank search result page, becouse it is using too long search string:

http://wififalu.com/wifi/index.php?-tab ... res%C3%A9s

Instead of just:

http://wififalu.com/wifi/index.php?-act ... Ajk%C3%A9r

Is it possible to fix the blank result or change it not to search by all the variable just the ones with i have given a value?

Thanks
Benedek Rakovics
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby corestat.consulting » Sat Apr 19, 2008 4:09 am

On my other server its working perfectly, when i search it gives this URL
http://tesztwififalu.corestat.hu/wifi/i ... Ajk%C3%A9r
I don't know what could be the problem, becouse i belive there is no difference in the config file.
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby shannah » Sat Apr 19, 2008 7:38 am

Hi Benedek,

The blank page indicates that there is an error that is not being displayed.
If you have access to the apache error log you can see what this error is.
Otherwise, you should enable errors by adding the following to the beginning of your index.php file:

Code: Select all
ini_set('display_errors','on');
error_reporting(E_ALL);
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

GET

Postby corestat.consulting » Sat Apr 19, 2008 8:11 am

Hello!

Thank you for your reply. I haven't found any errors in the error log. If you need any information that might help, please let me know.

My index.php looks like this:

Code: Select all
<ob_start>display();
?>
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby corestat.consulting » Sat Apr 19, 2008 8:11 am

<ob_start>display();
?>
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby corestat.consulting » Sat Apr 19, 2008 8:13 am

I doesnt't let me post it...

<? ob_start();
error_reporting(E_ALL);
ini_set('displaly_errors','on');
define('DATAFACE_INSTALLATION_PATH', '/home/wififalu/public_html/api');
define('DATAFACE_INSTALLATION_URL', 'http://www.wififalu.com/api');
ini_set('session.save_path', '/home/wififalu/tmp');
$sessionpath = session_save_path('/home/wififalu/tmp');
require_once '/home/wififalu/public_html/api/dataface-public-api.php';
df_init(__FILE__, 'http://www.wififalu.com/api');
$app =& Dataface_Application::getInstance();
$app->display();
?>
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby shannah » Mon Apr 21, 2008 11:28 am

Does it show this bloated url in the address field of your browser?
(http://wififalu.com/wifi/index.php?-tab ... %5B%5D=Abaújkér&-findq%3Aminoseg_status=&-findq%3Aminoseg_datum=&-findq%3Aellenor=&-findq%3Ajavitas_status=&-findq%3Ajavitas_date=&-findq%3Afelelos=&-findq%3Aszolgaltato_nev=&-findq%3Astatus=&-findq%3Amodositva=&--submit=Keresés)

The find form is supposed to use the "POST" method. Xataface then processes this response and redirects to the correct url
(http://tesztwififalu.corestat.hu/wifi/i ... Ajk%C3%A9r )

So it is very strange if the bloated URL actually shows up in the address bar.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby corestat.consulting » Sun Apr 27, 2008 1:20 am

Yes
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby shannah » Sun Apr 27, 2008 10:29 pm

That is bizarre. If you look at the HTML source for the find form, can you check to see the "method" attribute of the FORM tag? It should be "POST". If it is GET, then... something is fishy.

Have you upgraded Dataface from a previous version or is this version the first you have installed. If you have upgraded from a previous version it might be a template caching issue. You should clear the contents of the templates_c directory (in both your application directory if it exists, and the xataface/Dataface directory) to clear the cache.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby corestat.consulting » Mon Apr 28, 2008 1:41 am

<form>

I'm using Dataface 071. I'll try to clean the template_c directory. Where can I find the form action in the source code?
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby corestat.consulting » Mon Apr 28, 2008 1:41 am

<form action="/wifi/index.php" method="get" name="onkormanyzat" id="onkormanyzat">
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby corestat.consulting » Mon Apr 28, 2008 2:44 am

The Form method is the same (GET) on my two applications (on different servers), however on the new server, the bloated URL shows up, with blank page, the other one gives out the results and only shows up: http://tesztwififalu.corestat.hu/wifi/i ... Ajk%C3%A9r
Unlike on the new one:
http://wififalu.com/wifi/index.php?-tab ... res%C3%A9s
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby corestat.consulting » Mon Apr 28, 2008 2:51 am

Cleaning the templates_c did not help.
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest

Postby shannah » Mon Apr 28, 2008 8:47 am

Oh.. 0.7.1... Fix this issue by opening the Dataface/SearchForm.php file, and changing line 81 from:
Code: Select all
parent::HTML_QuickForm($tablename, 'get');

to
Code: Select all
parent::HTML_QuickForm($tablename, 'post');
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Postby corestat.consulting » Mon Apr 28, 2008 9:41 am

Yes! It's working now, thank you :)
CoreSTAT Consulting Bt.
http://www.corestat.hu
corestat.consulting
 
Posts: 13
Joined: Wed Mar 19, 2008 6:31 am
Location: Hungary, Budapest


Return to Xataface Users

Who is online

Users browsing this forum: No registered users and 14 guests

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