Posted by beautifulmind on November 29, 2008 at 9:52am
Hello Views developers!
I read the mission statement of the group and I got some relief:
This group exists as a place for people interested in the group to talk about Views development; all development talk is encouraged here, from people who want to work on Views core to people who are interested in Views' API for their own modules.
I am developing views for my custom modules, but having problem with handlers. I can't figure out how to use those handlers.
I defined handlers but when I select the filter I added to the views it shows and error:
Error: handler for my_table > my_field doesn't exist!Any help?
Regards.

Comments
clever man
you are clever, so you can do it
hook_views_handlers
you need the hook_views_handlers() hook
The full documentation for this hook is in the advanced help.
*_*
Yes I did write the hook_views_handlers(), but any how, it doesn't help.
Also, I've done as mentioned with advanced help section.
Thanks for reply.
:)
Beautifulmind
BeautifulMind
*_*
Now am able to add handler I defined for my module but now it throws following error message:
The error is a javascript alert.
I think, still there is something that am missing in my module. If you have any links for how to defined handlers, it would be help me a lot.
Regards.
:)
Beautifulmind
BeautifulMind
how to see the original error
disable javascript in your browser to see the original error
*_*
That solved my problem!!
Thanks a lot. But when previewing the view, I see an error in which the filter I added does not replaced with value.
Instead it shows Array() in the query.
I use the following code in my plugin.
$this->query->add_where($this->options['group'], "$this->table_alias.$this->real_field ". (empty($this->value) ? '!=' : '=') . " CURRENT_USER");
Its the same as in views_handler_filter_user_current.inc in views.
:)
Beautifulmind
BeautifulMind
more info needed
If it is the same then the problem should be somewhere else. Can you post the full code of your handler?