- https://woffice.io
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Add the Vue.js library, the Google MAP API and our own component | |
* | |
* We are using a CDN for the library | |
*/ | |
public function addScripts() | |
{ | |
// Vue.js library | |
wp_enqueue_script( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add our JS files | |
add_action('wp_enqueue_scripts', array($this, 'addScripts')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Load the BuddyPress members coordinates | |
* | |
* This is an Ajax callback, we just output the locations as a formatted JSON array | |
* | |
* @return void | |
*/ | |
public function loadMembers() { | |
$is_request_safe = ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Fetch the members positions | |
add_action('wp_ajax_wpffice_map_members', array($this, 'loadMembers')); | |
add_action('wp_ajax_nopriv_woffice_map_members', array($this, 'loadMembers')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* The private Google API key used for the GeoCoding API | |
* | |
* @var string | |
*/ | |
private $privateApiKey = 'aaaaaaa'; | |
/** | |
* Woffice_Members_Map constructor. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Class Woffice_Members_Map | |
* | |
* This class handles the Members Map backend actions and callbacks. | |
* | |
* As well as the render part | |
* | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="buddypress"> | |
<?php do_action( 'bp_before_activation_page' ); ?> | |
<div class="page" id="activate-page"> | |
<?php do_action( 'template_notices' ); ?> | |
<?php do_action( 'bp_before_activate_content' ); ?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function revert_to_old_design() { | |
return "woffice-2-x"; | |
} | |
add_filter('woffice_design_version', 'revert_to_old_design') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Traitement | |
*/ | |
session_start(); | |
if(isset($_GET['articles_list']) && !empty($_GET['articles_list'])) { | |
// Du formulaire |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Get Sales total from a REMOTE .json file | |
* | |
* @link https://shopicruit.myshopify.com/admin/orders.json?page=1&access_token=c32313df0d0ef512ca64d5b336a0d7c6 | |
* @author François Forest | |
* @version 1.0.0 | |
*/ | |
Class ShopifyIntern | |
{ |