Skip to:
Content
Pages
Categories
Search
Top
Bottom

How to make a simple banner ads plugin


  • akgt
    Participant

    @akgt

    Hi I was wondering how to make a simple banner ads plugin

    Ive looked all over and cant find that is simple as it should be,

    all I need is to be able to is add a image and link in the standard ad sizes and thats it

Viewing 1 replies (of 1 total)

  • modemlooper
    Moderator

    @modemlooper

    Use add_action to include your banner ad. If you look through template files you will find do_action code, these are placed there so you can hook code to.

    This example will place an image with a link around it above the activity stream.

    `function my_banner_ads_plugin() {

    echo ‘<a href=”url”><img src=”path-to-image”></a>’;

    }

    add_action( ‘bp_before_directory_activity_content’, ‘my_banner_ads_plugin’ );`

Viewing 1 replies (of 1 total)
  • The topic ‘How to make a simple banner ads plugin’ is closed to new replies.
Skip to toolbar