Welcome Guest, Not a member yet? Register   Sign In
HMVC url help
#1

[eluser]breaddes[/eluser]
I've built a newsletter module which is structured as follows:

Controller
application/modules/newsletter/controllers/addmember.php

Views
application/modules/newsletter/views/form.php
application/modules/newsletter/views/confirm.php

The controller addmembers has methods to load the form view, to validate input and to load the confirm view. As default it is showing the form view.

That's all all what the module is about. The module can be added to any view of my actual site. My site is structured as follows:

Controller
application/controllers/homesite.php

Views
application/views/homesite.php

If I echo modules::run('newsletter/addmember/form') the default module state is displayed within my homesite view.

Now the problem is that I have to send my form to newsletter/addmember/validate. That's simply because there's the method to validate my form-data. Without ajax this would simply load a fragment without it's outer site context (I mean html-output).

Therefore I would have to load the homesite instead which would make no sense. Although it reloads the same page my module doesn't know that the form has been sent.

How can I deal with that problem?


Messages In This Thread
HMVC url help - by El Forum - 09-23-2010, 07:30 AM
HMVC url help - by El Forum - 09-24-2010, 09:07 AM



Theme © iAndrew 2016 - Forum software by © MyBB