PluginProbe
Powerkit – Supercharge your WordPress Site / 2.2.9
Powerkit – Supercharge your WordPress Site v2.2.9
3.1.1 3.1.0 3.0.9 3.0.8 trunk 2.2.6 2.2.7 2.2.8 2.2.9 2.3.0 2.3.1 2.3.2 2.3.3 2.3.4 2.3.5 2.3.6 2.3.7 2.3.8 2.3.9 2.4.0 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 All 87 releases
powerkit / modules / pinterest / class-powerkit-pinterest.php

class-powerkit-pinterest.php in Powerkit – Supercharge your WordPress Site 2.2.9, at modules/pinterest/class-powerkit-pinterest.php

69 lines 2.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Pinterest Integration
4 *
5 * @package Powerkit
6 * @subpackage Modules
7 */
8
9 /**
10 * Init module
11 */
12 class Powerkit_Pinterest extends Powerkit_Module {
13
14 /**
15 * Register module
16 */
17 public function register() {
18 $this->name = esc_html__( 'Pinterest Integration', 'powerkit' );
19 $this->desc = esc_html__( 'Display your Pinterest Board widget in your sidebar or post content via shortcode. Enable Pin It buttons on single images in post content and all post galleries for the easy pinning of your images to Pinterest boards.', 'powerkit' );
20 $this->slug = 'pinterest_integration';
21 $this->type = 'default';
22 $this->category = 'social';
23 $this->priority = 40;
24 $this->public = true;
25 $this->enabled = true;
26 $this->links = array(
27 array(
28 'name' => esc_html__( 'Go to settings', 'powerkit' ),
29 'url' => admin_url( sprintf( 'options-media.php#%s', powerkit_get_page_slug( $this->slug ) ) ),
30 ),
31 array(
32 'name' => esc_html__( 'View documentation', 'powerkit' ),
33 'url' => powerkit_get_setting( 'documentation' ) . '/social-integrations/pinterest-integration/',
34 'target' => '_blank',
35 ),
36 );
37 }
38
39 /**
40 * Initialize module
41 */
42 public function initialize() {
43
44 /* Load the required dependencies for this module */
45
46 // Helpers Functions for the module.
47 require_once dirname( __FILE__ ) . '/helpers/helper-powerkit-pinterest.php';
48
49 // The classes responsible for defining all actions.
50 require_once dirname( __FILE__ ) . '/public/class-powerkit-pinterest-shortcode.php';
51 require_once dirname( __FILE__ ) . '/public/class-powerkit-pinterest-board-widget.php';
52 require_once dirname( __FILE__ ) . '/public/class-powerkit-pinterest-profile-widget.php';
53
54 // Gutenberg blocks.
55 if ( function_exists( 'register_block_type' ) ) {
56 require_once dirname( __FILE__ ) . '/public/class-powerkit-pinterest-block.php';
57 }
58
59 // Admin and public area.
60 require_once dirname( __FILE__ ) . '/admin/class-powerkit-pinterest-admin.php';
61 require_once dirname( __FILE__ ) . '/public/class-powerkit-pinterest-public.php';
62
63 new Powerkit_Pinterest_Admin( $this->slug );
64 new Powerkit_Pinterest_Public( $this->slug );
65 }
66 }
67
68 new Powerkit_Pinterest();
69