Post Pay Counter

The best way to pay authors on WordPress

  • Features
  • Addons
  • Cart
  • PRO version
  • Support
  • Tutorials
    • Questions and Answers

Add a custom column to the stats table

December 3, 2018 by Stefano 2 Comments

Sometimes you may want to add an additional custom column to the stats table. This cannot be achieved through native plugin features, but some light custom coding is enough.

This tutorial will provide developers a sketch code of how this can be done. It should be easily be adapted to your needs with some (PHP) coding skills. Be sure to review the code, because there are several optional checks just to showcase them (for example, permission checks).

In the example, we add a custom column to show the user email address.

PHP
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
add_filter( 'ppc_general_stats_format_stats_after_cols_default', 'add_email_col_html' ), 10 );
add_filter( 'ppc_general_stats_each_field_empty_value', 'email_td_html' ), 10, 4 );
 
/**
* Adds custom field column to stats page.
*
* Hooks to PPC_HTML_functions::get_html_stats() - ppc_general_stats_html_cols_after_default.
*
* @param $cols array Stats columns
*/
static function add_email_col_html( $cols ) {
global $ppc_global_settings;
 
//Only add column to general stats page
if( $ppc_global_settings['current_page'] != 'stats_general' ) return $cols;
 
$perm = new PPC_permissions();
 
if( $perm->can_mark_as_paid() )
$cols['author_email'] = __( 'Email', 'ppc' );
 
return $cols;
}
 
/**
* Populates custom field in stats page.
*
* Hooks to PPC_HTML_functions::get_html_stats() - ppc_general_stats_html_after_each_default.
*
* @param $author int author id
* @param $formatted_data array formatted stats
* @param $raw_data array sorted stats
*/
static function email_td_html( $field_value, $column_name, $author_stats, $author_id ) {
global $ppc_global_settings;
 
//Only add column to general stats page
if( $ppc_global_settings['current_page'] != 'stats_general' ) return $field_value;
if( $column_name != 'author_email' ) return $field_value;
$perm = new PPC_permissions();
 
if( $perm->can_mark_as_paid() OR $perm->can_see_paypal_functions() ) {
$user_data = get_userdata( $author_id );
$author_email = $user_data->user_email;
 
return $author_email;
}
 
return $field_value;
}

Filed Under: Developer documentation, Tutorials

How to mark posts as paid and pay with PayPal

March 23, 2017 by Stefano Leave a Comment

One of the most useful features of the PRO version is the Mark as paid one. This tutorial will guide you through how you can mark authors and posts as paid with Post Pay Counter, and how to use the plugin to pay authors through PayPal in just a few clicks.

Marking as paid is useful especially because it allows for automated payment managing! You will not need to take care of how much you paid an author last month and how much you should pay him this month. The plugin will keep a payment history and will make all the math needed.

Setting up permissions

First thing you need to care about is permissions. Post Pay Counter has detailed permissions settings to keep users from accessing features they should not. You yourself may not yet have access to payment features because you lack permissions to do so.

Head over to Post Pay Counter > Options and look for the Permissions box. Let’s start by ticking all payment-related permissions. Of course, you can play around with them and decide exactly which you want to be active, but we are going to present all the available features now.

When your setup will be complete, you may want to personalize user settings in order to hide those features from normal users and only see them yourself.

Mark as paid posts and authors

Payments happen in the stats page, so let’s go to Post Pay Counter > Stats now. Payment features are available both in the general stats view (where authors are displayed) and in the detailed stats view (where posts details from a single author are displayed). We will be showing them off for the detailed view of a specific author now.

[Read more…]

Filed Under: Tutorials Tagged With: mark as paid, paypal, post pay counter pro

Pay writers per visit on WordPress

January 16, 2015 by Stefano 21 Comments

If you are using the Post Pay Counter plugin to calculate and keep track of how much money each author should be paid for their posts, there are currently at least three sure ways to pay authors per visit.

1. Google Analytics visits

Post Pay Counter PRO allows you to automatically pull views data from your Google Analytics account and use it to compute payments. Since Analytics is possibly the most accurate and reliable visits-counting method, this should be the preferred choice. Here is the tutorial on the setup and its working, if you want to know more.

Pay writers per visit WordPress - Analytics

[Read more…]

Filed Under: Tutorials Tagged With: post pay counter, visits

Google Analytics setup and configuration with Post Pay Counter PRO

April 26, 2014 by Stefano

Post Pay Counter PRO allows you to pay your writers on WordPress basing on how many Google Analytics visits their posts logged. This tutorial shows how to set it up. After setting it up, you may be interested in putting up an effective visits payment flow.

Note: Post Pay Counter PRO does not keep track of Analytics visits, it can only use them to compute the payments. For the tracking you will need something like Google Analytics for WordPress.

First thing to look for is the Google Analytics Settings box. Every section is explained quite in detail, but what is important is that you go through these settings before going on with the setup. They are already set up in a standard and usually-fine way, but if you do want to change them, you should do that before anything else. Don’t forget to hit the Save options button when you are done.

[Read more…]

Filed Under: Tutorials Tagged With: google analytics, post pay counter pro

Share Adsense Revenues in WordPress with Post Pay Counter

May 15, 2015 by Stefano 24 Comments

More and more websites are paying users with a share of the Adsense revenues their posts generate: Post Pay Counter PRO now allows you to automatically get the total Adsense revenue for each post, calculate the share due to an author, and display all data in a nice stats table, ready for payment and record storing.

Revenues3

Adsense 3

Let’s get started to see how sharing Adsense revenues in WordPress works.

[Read more…]

Filed Under: Tutorials Tagged With: post pay counter pro

Display stats details in public pages with Post Pay Counter PRO shortcode

July 16, 2014 by Stefano 23 Comments

One of the most appreciated features of Post Pay Counter PRO is the shortcode, which provides the ability to display the statistics and payment details in public pages. The stats table will use your theme’s style and will be thus seamlessly integrated with the look of your site.

This allows your users to see stats without having to access the admin section. This is useful when users are not supposed to ever access wp-admin, neither for writing posts nor for any other matter. In this way, they will not need to access wp-admin to see their earnings and to interact with the plugin.

Shortcode stats

Shortcode usage

The shortcode is [ppc]. If you use it as it is, with no parameters, the default stats page will be shown: general stats with a time range which is the default one set in Options > Misc settings > Default stats time range. This is what you would see if you just went to the wp-admin Stats page.

[Read more…]

Filed Under: Tutorials Tagged With: post pay counter pro, shortcode

PayPal setup and configuration with Post Pay Counter PRO

April 15, 2014 by Stefano

Post Pay Counter PRO does not only compute payments on your WordPress blog, but it allows you to pay your writers without having to manually head to PayPal’s website and enter the amounts and emails. Up to 6 users can be paid at a time, each transaction needs to be explicitly authorized before it is completed (works just like a Checkout page), currency conversion is supported and it is possible to choose whom pays the PayPal fees, either the admin (sender) or the users (receivers). The plugin works with the Adaptive Payments API, if you ever wanted to know.

This tutorial will walk you through setting up PayPal with the plugin. If you want to know how to actually pay authors, see this other tutorial. To know how users can enter their PayPal addresses, see this tutorial.

[Read more…]

Filed Under: Tutorials Tagged With: paypal, post pay counter pro

Set up an effective payment flow for lifetime visits

May 27, 2016 by Stefano Leave a Comment

If you already know how to pay your writers per visits, you may want to pay them for all the visits their posts record through all time, not just for the current month. This can be easily achieved through the PRO version mark as paid feature. This tutorial will guide you through how to set up the payment flow in order to achieve that.

How to pay authors per views across multiple months

  1. If you use Google Analytics, make sure you have selected the desired start day for visits. This can be done through the Update Analytics Data feature in the Google Analytics Status box. For example, if you want to pay writers for views since the beginning of 2016, then you need to select 2016/01/01. You may well want to start counting visits since the day you install the plugin, in which case just select that day or don’t do anything.
    [Read more…]

Filed Under: Tutorials Tagged With: google analytics, mark as paid, post pay counter pro, visits

How to set users’ PayPal email address

September 9, 2017 by Stefano

Post Pay Counter PRO allows to pay authors through PayPal with ease. However, users must enter the PayPal email address which they would like to be paid to, for the feature to work.

There are several ways in which you can make them do that.

1. Their profile page

The user profile page is the easiest place in which they can set their PayPal email address, just as any other profile settings. The feature is enabled by default and you need to take no action. However, this requires that authors have access to wp-admin, at least for profile editing, which they may not depending on your setup.

PayPal-Setup-6

2. Any public page of your choice

The PRO version comes with several shortcodes for stats. It also ships a shortcode to display the PayPal email address form in any public page of your choice. You just need to create a new page, enter [ppc_user_paypal_email_settings] as text and publish it. Logged-in users visiting that page will see the apt field to enter and change their PayPal email address.

[Read more…]

Filed Under: Tutorials Tagged With: developer documentation, payments, paypal, post pay counter pro

Exclude columns from stats in BuddyPress page

November 10, 2017 by Stefano Leave a Comment

The BuddyPress addon allows you to display Post Pay Counter author’s stats in the BuddyPress Member page. However, by default, all columns are displayed. This may include columns that you are not interested into, or that you may not want to show to authors.

Below is a PHP code that allows to exclude some columns from display.

1
2
3
4
5
6
7
8
9
/**
* Exclude post status and post type from BuddyPress stats table
*/
static function ppc_buddypress_exclude_stats_columns( $shortcode ) {
$exclude_columns = ''; //comma separated list of columns to be excluded
 
return substr( $shortcode, 0, strlen( $shortcode )-1 ) . ' exclude="'.$exclude_columns.'"]';
}
add_filter( 'ppc_buddypress_stats_shortcode', 'ppc_buddypress_exclude_stats_columns' );

You should change the following line with the columns IDs you would like to hide:

1
$exclude_columns = ''; //comma separated list of columns to be excluded

Valid columns IDs are: post_id, post_title, post_type, post_status, post_publication_date, post_words, post_visits, post_adsense_revenues, post_images, post_comments, post_bonus, post_total_payment, post_due_payment.

[Read more…]

Filed Under: Tutorials Tagged With: buddypress

  • 1
  • 2
  • Next Page »

Your cart

Number of items in cart: 0

  • Your cart is empty.
  • Total: €0.00
  • Checkout

What are you looking for?

Connect on Facebook

Follow the Post Pay Counter page on Facebook to be up-to-date with discounts and latest releases!

Questions and answers

  • How do licenses work? Which one should I buy?
  • How can I use the payment features and pay through PayPal?
  • How do I set Google Analytics up and use it?
  • How do I set Google Adsense up and use it?
  • How do I set PayPal up and use it?
  • How do I use the shortcode to display stats in public?
  • Are there any known incompatibility issues?
  • Can I hide the stats box while editing a post?
  • Why posts I've never paid show up as paid?

Copyright © 2019 · Centric Theme on Genesis Framework · WordPress · Log in

This site uses cookies, as all sites on the planet do -- More info