0

Hi,

I would like to add filter using textbox. So I created CFilterOption

CFilterOption opt = api.Filter.NewFilterOption(); opt.SetRawHtmlForm(string.Format("", api.PluginPrefix)); opt.sName = api.PluginPrefix + "scustomername"; opt.sQueryParam = api.PluginPrefix + "scustomername"; opt.sHeader = "Customer name"; opt.sQueryParam = api.PluginPrefix + "scustomername";

But after submit when I'm trying to get value from textbox using

api.Request[api.PluginPrefix + "scustomername"]; in FilterCommitBefore(CFilter filter) event

But in request there is no data

Any idea?

Thanks

flag

1 Answer

0

In which plugin interface method are are you creating the CFilterOption? Without adding the filter option to a CFilter object, it won't do anything on its own.

Also, where is this field being displayed so that users can enter a value?

Can you show us more of your code so we can have a better idea of what you're trying to do? Or maybe walk us through what you'd like the workflow to be?

link|flag
I'm implementing IPluginFilterOptions and I'm creating CFilterOption (opt) in method public CFilterOption[] FilterOptions(CFilter filter) and return value is return new[] { opt }; The field is displayed when you click on "Refine Further", then you select "Customer name". Textbox and submit button is displayed properly, but the value from textbox isn't passed. – Tomas Vlcek Mar 25 2011 at 13:45
It looks like you're missing the plugin prefix from the input's "name" attribute. This help – Tomas Vlcek Mar 28 2011 at 10:41

Your Answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.