Definition of the MO Button module. More...
Enumerations | |
enum | MO_BUTTON_VERSION |
Define the version of the MO Button module. More... | |
Functions | |
mo_button_init () | |
Implementation of hook_init(). | |
mo_button_perm () | |
Implementation of hook_perm(). | |
mo_button_menu () | |
mo_button_filter ($op, $delta=0, $format=-1, $text= '') | |
Implementation of hook_filter(). | |
mo_button_theme () | |
Implementation of hook_theme(). | |
mo_button_get_path () | |
Get the current path to the image data. | |
mo_button_load ($name, $clear=FALSE) | |
Read a button from the database. | |
mo_button_save ($button) | |
Write a button to the database. |
The MO Button module is used to add very nice buttons to your website. It supports Ubercart in order to add URLs to your products.
http://www.m2osw.com/mo_button contact@m2osw.com
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
enum MO_BUTTON_VERSION |
This variable defines the version of the MO Button module. This will always be the same as the version defined in Drupal (throught the .info file.)
mo_button_filter | ( | $ | op, | |
$ | delta = 0 , |
|||
$ | format = -1 , |
|||
$ | text = '' | |||
) |
This is the filter definition used to replace the button tags in an actual button with a link.
[in] | $op | The filter operation |
[in] | $delta | The filter being applied, ignore if $op = "list" |
[in] | $format | The format referencing our filter, -1 if undefined |
[in] | $text | The text to be filtered |
References mo_button_process().
mo_button_get_path | ( | ) |
This function generates the currently selected path. Users can change it at any time by editin the global settings.
Referenced by mo_button_buttons(), and mo_button_replace().
mo_button_init | ( | ) |
Initialize the mo_button module.
The function adds a CSS to support different button styles.
mo_button_load | ( | $ | name, | |
$ | clear = FALSE | |||
) |
This function reads the specified button from the database.
If it is not defined in the database, a default button object is returned. This does not mean the button exists on the server.
[in] | $name | The name or identifier of the button to be read. |
[in] | $clear | If true, clear that entry (i.e. mo_button_save() changed the button) |
Referenced by mo_button_edit(), mo_button_replace(), and mo_button_save().
mo_button_menu | ( | ) |
Implementation of hook_menu().
Defines /admin/build/mo_button/... to administrate the buttons.
mo_button_perm | ( | ) |
This function returns an array of all the permissions defined in the MO Button module.
mo_button_save | ( | $ | button | ) |
This function writes the specified button to the database.
If it is not yet defined in the database, a new button object is created.
[in] | $button | The button object to be saved. |
References mo_button_load().
Referenced by mo_button_edit_submit().
mo_button_theme | ( | ) |
This function returns the list of supported themes.
The themes can easily be overridden to implement a different better adapted output to your theme.