Page 1 of 1

creating front end forms for a module

Posted: Fri Nov 27, 2009 11:48 am
by markS
Hello,

I'm busy trying to build a custom module for a website and I've run into a rather frustrating problem that I can't seem to get my head around.

I need to populate a database table from user submitted input and handle it within the confines of this module, it isn't, unfortunately, something that I can use with any of the pre-existing modules.

I thought that maybe I could use the module ModuleForms by SjG as a starting point for my efforts, so I've installed it and  created a form in my module using the API provided and it sort of works - until I submit the form...

The form seems to get directed to the API module rather than my own module and so I never get to handle the data, in fact all I get is the comment in the source , which is reasonable because ModuleForms isn't a tag module.
Having done some digging around, it appears that the variable to redirect the form looks something like:



Surely the module instance created by the call to CreateFormStart should be my module rather than ModuleForms?  How can I make it do that?

Should I even be using ModuleForms like this, it appears that I'm using it in the manner for which it's intended?
Is it compatible with up-to-date versions of cms, could that be the issue as it doesn't appear to have been updated for a while?
Is there some documentation on creating forms in modules as I couldn't really find anything?  What I've discovered so far is by looking into the source, which is always useful, but sometimes it would be nice to have a document too.

Thanks in advance for any advice you can offer me.

Mark.