Combo filtering - error on certain filters masks

Hi,

I am using a combo with a filter. Most of the time it works well, i.e. I can see the items in the dropdown list.

However, there are a few occasions when I type in a particular filter and I get thrown an alert with seemingly correct xml (this alert doesn’t show when the filter works) and the dropdown box of the combo only has a partial list. I do get a not-well-formed error from firefox but I can’t figure out what’s wrong.

Any ideas?

Hi
To reproduce it we need completed demo
docs.dhtmlx.com/doku.php?id=othe … leted_demo

Hi,

I think it might be due to special characters in the data. If the filtered data contains say a unicode character such as “é” and the data returned is, for example, “résumé”, then I get thrown the alert with the not well-formed xml error.

Is there any way to fix this?

Here is the php code segment that generates the XML for the combo filter:

...
include("dhtmlxConnector/codebase/data_connector.php");
...
$data = new DataConnector($conn, "MySQL");
$data->render_sql("SELECT * FROM ....");
...

If you are storing data in non utf encoding you need to add one more command to connectors, similar to the next

$data = new DataConnector($conn, "MySQL"); $data->set_encoding("iso-8859-1"); //set used encoding $data->render_sql("SELECT * FROM ....");

Thanks,

That solved the issue when I am trying to display the xml data but it didn’t fix the filtering issue in the combo box. So, I guess data encoding is not the issue.

Is there any way I can troubleshoot the filtering? For example, how can I simulate a filter being passed to the php script if my script was named filterscript.php?

For example, can I call localhost.com/filterscript.php?filter=xxxx? or something similar?

Hi,

Can someone tell me if there is an easy way to troubleshoot this or point me to some docs that can tell me how to…

Thanks!

No response? No one can tell me how this is done?

Hi,

For example, how can I simulate a filter being passed to the php script if my script was named filterscript.php?

The combo sends “mask” parameter. Therefore, you can use something like this:

localhost.com/filterscript.php?mask=xxxx

Hi,

I tried using localhost.com/filterscript.php?mask=xxxx

but the return results is the same as the unfiltered version …

i.e. calling

localhost.com/filterscript.php?mask=xxxx

returns the same results as

localhost.com/filterscript.php

Am I missing anything else?