Skip to content

Commit

Permalink
The selector for picking the DOM-elements is now configurable
Browse files Browse the repository at this point in the history
  • Loading branch information
kai-moritz committed Feb 28, 2013
1 parent 9585948 commit b2876e0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
10 changes: 9 additions & 1 deletion jquery.openx.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,13 @@
* charset: string Charset used, when delivering the banner-codes.
* If empty, the charset is guessed by OpenX. Examples
* for sensible values: "UTF-8", "ISO-8859-1".
*
*
* Other settings:
*
* selector: string A selector for selecting the DOM-elements, that
* should display ad-banners. DEFAULT: ".oa".
* See: http://api.jquery.com/category/selectors/
*/
$.openx = function( options ) {

Expand Down Expand Up @@ -121,6 +128,7 @@
'protocol': document.location.protocol,
'delivery': '/www/delivery',
'fl': 'fl.js',
'selector': '.oa',
'cache': true
},
options
Expand Down Expand Up @@ -158,7 +166,7 @@
*/
src += '?zones=';
for(name in OA_zones) {
$('.oa').each(function() {
$(settings.selector).each(function() {
var
node = $(this),
id;
Expand Down
2 changes: 1 addition & 1 deletion openx.jquery.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"title": "jQuery OpenX",
"description": "jQuery plugin, that loads banner-ads from an OpenX-server in an asynchronous and responsive way",
"keywords": [ "openx", "adserver", "banner", "asynchrone", "responsive" ],
"version": "0.1.2",
"version": "0.1.3",
"author": { "name": "Kai Moritz", "email": "[email protected]" },
"licenses": [ { "type": "LGPLv3", "url": "http://www.gnu.org/licenses/lgpl-3.0.html" } ],
"homepage": "http://juplo.de/openx",
Expand Down

0 comments on commit b2876e0

Please sign in to comment.