Skip to content

Instantly share code, notes, and snippets.

@mototeam
mototeam / gist:27ee82c87566a5235c44
Last active August 29, 2015 14:09
MotoPress - working with styles
<?php
/**
* Plugin Name: MotoPress Change Styles Example
* Plugin URI: http://www.getmotopress.com/
* Description: This example describes how to add new styles to MotoPress objects
* Version: 0.1
* Author: MotoPress Team
* Author URI: http://www.getmotopress.com/
* License: GPL2 or later
@mototeam
mototeam / gist:1288fe335852623e75b6
Created December 10, 2014 16:13
MotoPress Vertical Tabs
<?php
/**
* Plugin Name: MotoPress Vertical Tabs
* Plugin URI: http://www.getmotopress.com/
* Description: Add vertical style to Tabs widget
* Version: 0.1
* Author: MotoPress Team
* Author URI: http://www.getmotopress.com/
* License: GPL2 or later
@mototeam
mototeam / gist:e757e1df352a9547839f
Created January 10, 2015 10:36
MotoPress Custom Layouts
<?php
/**
* Plugin Name: MotoPress Custom Layouts
* Plugin URI: http://www.getmotopress.com/
* Description: This example describes how to add custom predefined layouts.
* Version: 1.0
* Author: MotoPress Team
* Author URI: http://www.getmotopress.com/
* License: GPL2 or later
@mototeam
mototeam / gist:e8236f4109cf90a222a2
Created February 25, 2015 15:27
MotoPress PressTicket Fix plugin
<?php
/*
Plugin Name: MotoPress PressTicket Fix
Plugin URI: http://www.getmotopress.com/
Description: Fixes an issue with PressTicket plugin by Toan Nguyen http://wpoffice.net/contact/. PressTicket plugin adds custom div to each the_content filter call.
Version: 1.0
Author: MotoPress
Author URI: http://www.getmotopress.com/
*/
@mototeam
mototeam / gist:93aa797aefaf7f4ed3d1
Last active August 29, 2015 14:16
MotoPress Copyright Proof Fix plugin
<?php
/*
Plugin Name: MotoPress Copyright Proof Fix
Plugin URI: http://www.getmotopress.com/
Description: Disable Copyright Proof plugin (frustrate_copy.js) in MotoPress visual editor
Version: 1.0
Author: MotoPress
Author URI: http://www.getmotopress.com/
*/
@mototeam
mototeam / gist:e659a8cb30165c73d1d1
Created March 11, 2015 13:03
Removing all objects example
// mp_code & mp_text can be hidden only
$motopressCELibrary->getObject('mp_code')->setShow(false);
$motopressCELibrary->getObject('mp_text')->setShow(false);
$motopressCELibrary->removeObject('mp_heading');
$motopressCELibrary->removeObject('mp_image');
$motopressCELibrary->removeObject('mp_grid_gallery');
$motopressCELibrary->removeObject('mp_image_slider');
$motopressCELibrary->removeObject('mp_video');
$motopressCELibrary->removeObject('mp_space');
@mototeam
mototeam / gist:c54efbc51aa126083479
Created June 8, 2015 12:58
MotoPress Nested Shortcodes Example
<?php
/*
Plugin Name: MotoPress Nested Shortcodes Example
Plugin URI: http://www.getmotopress.com/
Description: Example of the Nested Shortcodes in MotoPress Content Editor plugin
Version: 1.0
Author: MotoPress
Author URI: http://www.getmotopress.com/
*/
@mototeam
mototeam / gist:d5bf1e7d6d6bf7dc0b5e
Created June 8, 2015 14:18
MotoPress Visual Controls Example
<?php
/*
Plugin Name: MotoPress Visual Controls Example
Plugin URI: http://www.getmotopress.com/
Description: Example of the visual controls for object
Version: 1.0
Author: MotoPress
Author URI: http://www.getmotopress.com/
*/
@mototeam
mototeam / gist:9137cef5ace249833ce462b4bbb6ec0a
Created June 14, 2017 08:01
motopress content editor - dequeue styles
add_action( 'wp_print_styles', 'my_theme_wp_print_styles' );
function my_theme_wp_print_styles() {
if ( is_front_page() ) {
wp_dequeue_style('mpce-theme');
wp_dequeue_style('mpce-bootstrap-grid');
wp_dequeue_style('mpce-font-awesome');
}
}
<?php
/*
* Add font with icons to Getwid plugin.
* Use this code in functions.php or custom plugin.
*/
// add hook
add_action( 'getwid/icons-manager/init', 'my_theme_getwid_add_custom_icons' );