PremiumPress Theme Documentation

Here's a more detailed look into using PremiumPress themes.

Getting Started

Getting started with the PremiumPress responsive framework is easy. This page will walk you through the complete process from setting up your website to developing your own child themes and plugins.

Using this documentation

This documentation has been written to help you better understand the PremiumPress responsive themes and framework. The contents of this documentation may include some programming and computer terminology however where possible jargon free advice is given.

To get started, simply select your desired page from the left navigation menu.

Documentation Notes

This documentation is an on-going development and features may change.

Last Updated: July 2018

Theme Installation

All PremiumPress themes are installed the same way as every other WordPress theme; via the admin area of your WordPress website under the Appearence -> Themes.

Here is a video tutorial to show you how it's done;

License Key

Where do i find my license key?

Your theme license key can always be found within your members area;

My key doesn't work, what should i do?

Contact our support team and they will investigate for you.

Key Usage

You may use your license key on any website that you own, it can be used as many times as you like as long as each website is owned by you.

Under no circumstances should your key be distributed or given out to third-parties.

You are responsible for the distribution and usage of your license key, if your key is abused and/or distributed your account will be closed without appeal.

Basic Design Setup

Watch and learn what design options you have available within your new PremiumPress theme.

Page Setup

The theme comes with a number of pre-designed template pages that are used throughout your website. (e.g. My account, checkout, search pages etc)

Please watch the video below to learn how to setup and apply these pages if your website has not been pre-configured.

video coming soon

Language Setup

Watch the video tutorial below and learn how to setup and configure multiple language options for your PremiumPress theme.

Admin Area Overview

Admin - General Setup

Admin - Home Page Setup

Customzing your website page setup

Admin - Design Setup

Admin - Email Setup

Setting up your website emails

Admin - Listing Setup

Setting up your listing and membership packages

Custom Fields

In this video tutorial you'll learn how to setup custom fields.

Listing Packages

In this video tutorial you'll learn how to setup listing packages.

Membership Packages

In this video tutorial you'll learn how to setup listing packages.

Admin - Advertising Setup

Creating and managing your advertising spaces

Admin - Payment Setup

Hooks & Filters

Getting started with built in hooks and filters.

The basic concept

Hooks and filters essentially enable you to modify content through your own plugin's/functions without modifying the core theme files. This is useful because you can then create additional plugin's/functionality that is not overwritten during a core system update and can be re-used/shared between projects.

What's the difference?

Hooks - enable you to drop in new content

Filter - enables you to modify content before its displayed.

More information about the fundamentals of hooks and filters and be found in the official WordPress guide below.

Hooks & filters within White-label themes

We have added a number of our own hooks and filters so that you can fully utilize the feature we have added and modify them if and where required.

You will find hooks for both front and back end allowing you to build additional plugin's that can be used over multiple website's.

All hooks can be found in the file:


Additional Resources & Useful Links

Creating Admin Plugin's

New Admin Menus

You can add a new admin menu page within your plugin's using the syntax below;

    $GLOBALS['new_admin_menu'][] = array("50" => array("title" => "New Page","function" => "_new_page_function" ));
    function _new_page_function(){
    /* your page content here */


Adding New Admin Tabs

You can add a new tab to an existing admin page using the syntax below;

    function new_admin_tab($c){
    return $c."< li>< a href='#example_new_content' data-toggle='tab'>New Tab< /li>";

Adding New Admin Tab Content

You can add content for your new tab using the syntax below

    function new_admin_tab_content(){
    < div class="tab-pane fade" id="example_new_content">
    /* your page content here */
    < /div>


Creating New Payment Gateways


Creating a payment gateway is simple and contains 3 main elements;

    1. Admin Options - For the webmaster to enter their gateway details
    2. Payment Form - Passes the data to the payment gateway
    3. Callback - Handles the responce from the payment gateway and creates the order

1. Admin Options - Creating the admin interface

Payment gateways are stored in one big Array, to add a new one you simply add a new value to the array.

function example_new_gateway($gateways){

    $nId = count($gateways)+1;
    $gateways[$nId]['name'] 		= "My Gateway Name"; // STRING - NAME OF YOUR GATEWAY
    $gateways[$nId]['logo'] 		= ""; // STRING - http:// link to your logo file
    $gateways[$nId]['website'] 		= ""; // STRING - http:// link to the merchants website for more details
    $gateways[$nId]['function'] 	= "gateway_example"; // STRING - name of your callback function
    $gateways[$nId]['callback'] 	= "no"; // YES/NO - FOR DISPLAY PURPOSES ONLY
    $gateways[$nId]['fields'] 	= array(
    '1' => array('name' => 'Enable Gateway', 'type' => 'listbox','fieldname' => $gateways[$nId]['function'],'list' => array('yes'=>'Enable','no'=>'Disable') ),
    '2' => array('name' => 'Example Text Box', 'type' => 'text', 'fieldname' => $gateways[$nId]['function'].'_textbox'),
    '3' => array('name' => 'Example List Box', 'type' => 'listbox', 'fieldname' => $gateways[$nId]['function'].'_listbox' ,'list' => array('1'=>'Display Value 1','2'=>'Display Value 2', '3'=>'Display Value 3','text value' => 'Display Value 4')), 
    '4' => array('name' => 'Display Name', 'type' => 'text', 'fieldname' => $gateways[$nId]['function'].'_name', 'default' => 'Pay Now - Example Text') ,
    return $gateways;


2. Payment Form

The payment form is simply the HTML form that sends the user to the payment gateway.

The import thing to remember here is that the FUNCTION NAME must match the one you have set in your gateway array function above

$gateways[$nId]['function'] 	= "gateway_example"; // STRING - name of your callback function

AND your function name matches the one the user can enable;

 '1' => array('name' => 'Enable Gateway', 'type' => 'listbox','fieldname' => 'gateway_example','list' => array('yes'=>'Enable','no'=>'Disable') ),

The payment form function might look like;

    function gateway_example($data){  
    // shopping cart
    $GLOBALS['global_cart_data'] <-- array 

    < FORM METHOD="POST" ACTION="" name="example_gateway">
    < INPUT TYPE="HIDDEN" NAME="ButtonAction" VALUE="checkout">
    < INPUT TYPE="HIDDEN" NAME="custom" VALUE="">
    < INPUT TYPE="HIDDEN" NAME="total" VALUE="">
    < BUTTON TYPE="submit">Process Payment< /BUTTON>
    < /FORM>

3. Handling The Callback

Once the payment has been made you will want to handle the data sent back to the website by the payment gateway.

function example_callback(){ 

	global $CORE;

        $order_data = array();
		$order_data['orderid'] 		= "";
		$order_data['description'] 	= "";
		$order_data['items']		= "";
		$order_data['shipping']		= "";
		$order_data['tax']			= "";
		$order_data['total']		= "";
		$order_data['status']		= 3;	 // 3 = COMPLETED / 0 = FAILED
		$order_data['email']		= "";
    	$order_data['shipping_label'] =  ""; // BLOB, STORE ADDRESS FROM THE PAYER
		return "success";
		return "error";



Getting started with shortcodes.

Available Shortcodes

Below is a list of all the currently available shortcodes for PremiumPress responsive framework;

  • [FIELDS]
  • [FILES]
  • [IMAGE]
  • [RATING]

More details about each are found in their corresponding sections below;

[FIELDS] Shortcode

Short Description

This shortcode is used to display a list of listing custom fields. It should be used on the listing page only.

[FIELDS show="" hide=""]

Example would be: [FIELDS show="field1|field2|field3" hide="my_custom_field"]

[GOOGLEMAP] Shortcode

Short Description

This shortcode is used to display a google map on the listing page. This will only show if the users listing has the option enabled.

[GOOGLEMAP tab=false]

Example would be: [GOOGLEMAP]

[CATEGORIES] Shortcode

Short Description

This shortcode is used to display a list of categories.

[CATEGORIES SHOW="123,456" HIDE="678,890" COUNT="1"]

Example would be: [CATEGORIES SHOW="123,456" HIDE="678,890" COUNT="1"]

[LISTINGS] Shortcode

Short Description

This shortcode is used to display a list of your website listings.

[LISTINGS cat='' orderby='' order='' show=10] 

Example would be: [LISTINGS cat='1' orderby='post_title' order='desc' show=10]

[TIMESINCE] Shortcode

Short Description

This shortcode is used to display a timer between the date the listing was create and the current date.

[TIMESINCE text_before="", text_after =""] 

Example would be: [TIMESINCE text_before="This listing was posted", text_after ="ago"]

[RATING] Shortcode

Short Description

This shortcode is used to display a star rating for a listing.

[RATING size=16 id=177] 

Example would be: [RATING size=16 id=xxxx] where xxxx is the post ID.

Sample Query Strings

Below are a few samples of query strings;

  • Featured Listings: meta_key=featured&meta_value=yes
  • Latest products :: orderby=ID&order=desc
  • Most visited products :: meta_key=hits&orderby=meta_value_num&order=desc
  • Random products : orderby=rand