submitting form containing comboboc and xxxx_new elements

Hello,

I have been looking at using your combobox, and have implemeneted it here:

trains.bbarker.co.uk/index.php

When I submit the form however, the:

element which is created by the javascript is included in the url as posted data:

?crs=liv&crs_new_value=false&filterType=to&filterCRS=cbg&filterCRS_new_value=false&type=all

I am trying to keep my URL easy to understand - these extra posted parameters (xxx_new_value)don’t actually break anything, but I’m looking for some way of preventing them from being submitted at all, so that the URL people see on the next page is as easy to understand as possible. Any ideas?

Hello,

filterCRS_new_value=false shows if option is selected from the list or the new value typed by user.

Combo creates DOMelem_hidden_input2 hidden field and in order to not submit it you 'll need to modify dhtmlxcombo.js - comment the following lines:

z = document.createElement(‘input’);
z.type = ‘hidden’;
z.name = (name||"").replace(/(]?)$/, “_new_value$1”);
z.value=“true”;
self.DOMelem.appendChild(z);
self.DOMelem_hidden_input2 = z;

that seemed to have the unfortunate side effect of completely breaking the autocomplete -perhaps there was a problem with my edit, but I can’t see one.

Ah… but commenting out just:

z.name = (name||"").replace(/(]?)$/, “_new_value$1”);

(and leaving the other lines alone) seems to have done the trick. Cheers.