The advantages of this plugin:
- Enabling and disabling the banner
- Display banners in different areas.
- Ability to display a banner depending on any special field (category, tag, etc).
- Ability to display a banner depending on the language using the field filter.
- Ability to add/edit a script banner.
- Ability to display a random banner.
- Display banner in content of pages or posts using shortcode.
A brief Markdown Example
Add the following line in your theme:
The parameter of the function is a string that contains variables:
- bannerID : Id of the banner
- zone: a text field that can be used to identify an area of your page (eg sidebar, footer)
- filter: a text field that can be used as a criterion for display (ie value: French, English or Category1, Category2)
- random : display a random banner (random=true)
Add a shortcode into content of pages or posts : [wp-addpub]
Add attributes to the shortcode to get the banner :
* bannerID : Id of the banner. bannerID attribute goes alone. the others could be mixed together.
* zone: a text field that can be used to identify an area of your page (eg sidebar, footer)
* filter: a text field that can be used as a criterion for display (ie value: French, English or Category1, Category2)
* random : display a random banner (random=true)
- Unzip the file and place the folder wp-addpub in the directory plugins wordpress \ wp-content \ plugins
- Activate the plug wp-addpub
- Go on the management of banners in the Options> WP-Addpub
These variables can be used separately or together (example: “zone=sidebar&filter=EN”)
- Can I manage a banner per category ?
Yes, you can use filter to specify the category’s ID.
$catid = get_the_category(); // get the ID of the category
wp_addpub(“filter=”.$catid->term_id); // show banner that has filter equal to the cat id
- Can I add a banner to the content of my post ?
Yes, the shortcode [wp-addpub] allows you to add a banner into pages or posts. For attributes, follow the section “How-to use”.
There are no reviews for this plugin.
Contributors & Developers
“WP-Addpub” is open source software. The following people have contributed to this plugin.Contributors
Translate “WP-Addpub” into your language.
Interested in development?
Browse the code, check out the SVN repository, or subscribe to the development log by RSS.
- (Fixed) Shortcode attribute names are always converted to lowercase before they are passed into the handler function.
- (Fixed) MYSQL error when inserting a new banner.
- Add a banner into pages and posts using the shortcode [wp-addpub]
- A second argument is added to the php function wp_addpub as boolean ($echo). set to true to echo the result or set to false for return the result as string.
- add an ‘alt’ on image
- russian translation by Vladimir Vasilenko (aka jeltoesolnce)
- add the full url to swfobject (reported by Jorge)
- add width to the banner type input
- bug fixed : when updating a banner without uploading a new file, it changes to html code.
- code optimization
- bug : user level access set to 8 (reported by Lars)
- bug : error when adding a html banner (reported by inklude)
- bug div id when displaying many swf in the same page.
- show error if cannot upload the file
- bug ie7 resolved.
- Display a random banner using random argument. e.g. : wp_addpub (“zone=sidebar&random=true”);
- Accept a script as a banner
- Check if there is a new version of the plugin
- Correct bug : Edit banner
- add new file “swfload.swf” => enable to click an swf banner
- BUG Display flash
- Change varchar(255) to TEXT