Welcome Guest, Not a member yet? Register   Sign In
Widget plugin (intelligent view partials)
#51

[eluser]hungnm144[/eluser]
Does your widget work with Parser Library?
#52

[eluser]Andy78[/eluser]
What do we actually have to do to convert it to a helper?

Just remove the class and have a bunch of functions or can we use as is in the helper folder of ci 2.0?
#53

[eluser]wiredesignz[/eluser]
Change the file name to widget_helper.php and relocate the file to application/helpers.
#54

[eluser]VicToMeyeZR[/eluser]
Just to clarify, this will work, if we are using the correct widget you posted, if we are using modules?

so /application/modules/model or /application/modules/view ?
#55

[eluser]wiredesignz[/eluser]
Modular Extensions HMVC still allows you to use plugins.
#56

[eluser]VicToMeyeZR[/eluser]
[quote author="wiredesignz" date="1289716038"]Modular Extensions HMVC still allows you to use plugins.[/quote]

Thats true. didn't think about that. ok, thanks
#57

[eluser]Andy78[/eluser]
Can a widget post data back to itself? If so how?

For example my login page is only ever going to be a view partial so I would be as well taking the logic for logging in out of the controller putting it in the widget class and then having the widget view's login form POST the data back to the widget class. Can that be done?

I cant seem to get it to work.
#58

[eluser]wiredesignz[/eluser]
Pass the data to the view and then to the widget from the inside view. Of course a widget can also use the $_POST array or $this->input->post().
#59

[eluser]Andy78[/eluser]
How do you pass the data from inside the view to widget? do you add it as params onto this:

widget::run('user_login');?
#60

[eluser]Andy78[/eluser]
in fact are you talking about an actual view or the widgets own view file?




Theme © iAndrew 2016 - Forum software by © MyBB