JToolBarHelper::custom('dettaglilibro.details','details.png','details.png','TOOLBAR_DETAILS',true);
This button must work like this:
the admin checks an entry from those listed inside a table and a view which will show the entry's detail is shown, this is what I have

the button is the one called "Dettagli" (it doesn't have an icon at the moment)
How do I have to proceed?
Once the button is clicked the method details() defined into the dettaglilibro controller is called.
Now my idea is:
- details() method calls detteglilibro view (class defined into view.html.php file)
- the view class call an instance of the dettaglilibro model and then a method defined into the model
- the method defined into the model performs a query and returns the data
- the method into the view class retreives the data returned by the model and pass it to the view to be shown on the page
Is this correct? Do I have to proceed in another way?
My problems with this approach are:
- how do I append the id of the checked entry to the address generated by the custom button? Or in other words, how do I pass the id to the controller?
- how do I call the class defiend into the view.html.php of the dettaglilibro view?
if inside the dettaglilibro controller I use $this->display(); it calls not the dettaglilibro view, but anotherone which has the component's name.


Sign In
Create Account


Back to top









