-
Notifications
You must be signed in to change notification settings - Fork 0
wikiplugin_bobshop.php (main bobshop function)
(for TikiWiki Plugin Newbies)
This page is about the main bobshop functions.
`wikiplugin_bobshop_info()`
and
`wikiplugin_bobshop($data, $params)`
In a TikiWiki-Page a plugin is called by
`{bobshop type=shop}`
In this example "type" is a parameter which have to defined in the wikiplugin_bobshop_info function.
Wonder what is $data about?
You have to call the plugin this way:
`{BOBSHOP type=shop}Here comes the body variable{BOBSHOP}`
The function wikiplugin_bobshop($data, $params) will be executet. It should contain vailid PHP-Code.
To use the $params, you have to use extract($params, EXTR_SKIP)
.
Print the articles The layout is defined in the template wikiplugin_bobshop_shop.tpl.
Print the "add to cart button". The layout is defined in the template wikiplugin_bobshop_button_add.tpl.
Print the cart. The layout is defined in the template wikiplugin_bobshop_cart.tpl.
Print the cahierpage. If there is no user logged in, the Login-Page and a link to the Register-Page will be displayed.
Payment?
The layout is defined in the template wikiplugin_bobshop_cahsierpage.tpl.