AndroApp Tricks to change post content

This guide is for little advanced users, who know little bit of php.

We will suggest to try out below changes on test setup and check it is not breaking your website or app.
It will change only the app content, your website content remains as it is.

To Add before the content of all posts

Add this code to functions.php

add_filter( 'json_prepare_post','androapp_overwrite_content_pre', 8, 3 );

function androapp_overwrite_content_pre($data, $post, $context) {
 if(!($data['type'] == "post" || $data['type'] == "page")){
 return $data;
 }
 $textToBeAdded = "add your html code here";
 $data['pwapp_post_content'] = $textToBeAdded.$data['pwapp_post_content'];
 return $data;
}

To Add after the post content

Add this code to functions.php
Continue reading “AndroApp Tricks to change post content”

Ad guidelines for AndroApp

This is to help you setup ads on your app via AndroApp plugin

      1. Please create publishers account on Admob, Mopub and Appnext
      2. Fill Interstitial ad id for Appnext, Mopub and Admob, We give preference in this order mopub, appnext and than Admob. If you dont want to use any provider just leave the ad id blank.
      3. Enter Mopub or Admob Bottom Ad unit in bottom/top/listView ad unit ids.
      4. To honor the Admob guidelines, we suggest to keep only bottom ad unit or top and listview ad unit(depending on the content on your page). We suggest to honor one ad on a screen at a time strictly as we have seen in past, google rejected few of our clients admob accounts.
      5. AppNext Intersitial ads will not work on woocommerce enabled sites, we disabled it due to some technical issue.

Mopub Setup Guidelines

  1. Create an account on Mopub.
  2. Create a new app by clicking on Add a New App button on top right.
  3. Go to App and than create a new Ad unit by clicking Add a Ad Unit button on top right. fill this ad unit id in AndroApp Account Settings Tab
  4. Go to networks tab and Add a new network by clicking Add Network button on top right
  5. Select ad network of your choice, like Admob, StartApp for facebook audience network etc.
  6. Fill in the required information in Set Up Your Inventory section
  7. Go to Segments tab from top
  8. Click on Global Segments
  9. Clear the filters by clicking on Clear All link
  10. under your Ad, disable enable by selecting the network and clicking on play/pause buttons in Segment Waterfall section
  11. set a ECPM for example $0.05
  12. you can add multiple ad networks for one mopub ad unit and those ad networks will fight with each other for a place in your app.

Hide Elements on Post Page

Hide some elements on Post Page

These options are valid only when Post Content type is set as post processed.
Screen Shot 2015-12-19 at 9.43.05 AM
To hide some content in your post page you can put below css in the define custom css here for post processed content type (see screenshot above)

Hide Featured Image
.androappfimage{
display:none;
}
Continue reading “Hide Elements on Post Page”

AndroApp – Create Google Analytics Property

Google Analytics tracking ID identifies the analytics property for which mobile tracking is enabled. Follow the below steps to get your property tracking ID.

1. Sign in to your Google Analytics account.

2. Select the Admin tab.

3. In the ACCOUNT dropdown, click on Create new account. (or select if you already have an account for your website)
Continue reading “AndroApp – Create Google Analytics Property”