DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:googleads

Google Adsense for DokuWiki

Compatible with DokuWiki

  • 2024-02-06 "Kaos" unknown
  • 2023-04-04 "Jack Jackrum" unknown
  • 2022-07-31 "Igor" unknown
  • 2020-07-29 "Hogfather" yes

plugin This tool allows you to set a code for use with Google AdSense, which allows you to put targeted advertisements on your site.

Last updated on
2020-09-15
Provides
Admin
Repository
Source

Similar to google_adsense2

Tagged with advertising, embed, google

License

Download

Before downloading or using this product, make sure you understand and accept the terms of the license.

After downloading, make sure to follow the install instructions or upgrading instructions below; trust me, they're worth reading.

  • Older downloads are available on request only.

Note: http://cloud.github.com/downloads/tatewake/dokuwiki-plugin-googleads/googleads-stable.tar.gz always points to the latest stable version!

Installation

Use the plugin manager to install, or…

  1. download the tarball/zip-file
  2. unpack it into <dokuwiki>/lib/plugins/
  3. login as admin and change the plugin in the configuration manager

using git:

% cd <dokuwiki>/lib/plugins/
% git clone git://github.com/tatewake/dokuwiki-plugin-googleads.git googleads

Debian install (or probably any other distribution):

# cd /usr/share/dokuwiki/lib/plugins/
# wget http://cloud.github.com/downloads/tatewake/dokuwiki-plugin-googleads/googleads-stable.tar.gz
# tar -xvzf googleads-stable.tar.gz
# chown -Rv 33 googleads/

Note: http://cloud.github.com/downloads/tatewake/dokuwiki-plugin-googleads/googleads-stable.tar.gz always points to the latest stable version!

About

This plugin allows you to include Google Adsense advertisings into your wiki page. It is possible to configure whether or not ads are shown to admins and/or logged-in users.

To use it you'll have to insert the following code into your template:

<?php
if (file_exists(DOKU_PLUGIN.'googleads/code.php'))
include_once(DOKU_PLUGIN.'googleads/code.php');
if (function_exists('gads_code')) gads_code();
?>

Note: Inserting the code above is required, not optional.

Install

As a plugin all you need to do is unpack the file into the lib/plugins/ directory (you should end up with a lib/plugins/googleads folder.)

Upgrading

To upgrade, remove the original lib/plugins/googleads folder, and install the new version as instructed above. You may wish to make a note of your google adsense code first though.

Discussion

  • Start all subtopics using H2. (Heading 2.)

Fatal error: Call to undefined method admin_plugin_googleads::plugin_locale_xhtml()

Fix: Fatal error: Call to undefined method admin_plugin_googleads::plugin_locale_xhtml() in /lib/plugins/googleads/admin.php on line 94

Edit

 plugins\googleads\admin.php 

Replace:

print $this->plugin_locale_xhtml('intro');

With:

print $this->locale_xhtml('intro');

Regards.

How to disable ads for one particular page?

Is is possible with this plugin to not run the ads on some particular page?

Regards


plugin/googleads.txt · Last modified: 2020-09-15 10:38 by tjgrant@tatewake.com

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki