This file contains 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 | |
/* | |
Our Wordpress is located in https://our-site.com/wordpress | |
Here's the relevant part of our wp-config.php | |
define('MULTISITE', true); | |
define('SUBDOMAIN_INSTALL', true); | |
define('DOMAIN_CURRENT_SITE', 'our-site.com'); |
This file contains 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
#!/usr/bin/php -q | |
<?php | |
// set to true to avoid ' and " converting to HTML special characters | |
@define('skip_glyphs', false); | |
// 3+ uppercase span tag is commented out, as everyone hates it | |
// instruction on how to use it available here: http://foliovision.com/2011/11/08/textile-editing-bbedit | |
// define these before including this file to override the standard glyphs |
This file contains 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 | |
include('wp-load.php'); | |
global $wpdb; | |
$aUsers = $wpdb->get_results("SELECT user_id,meta_value FROM $wpdb->usermeta WHERE meta_key = 'bb_favorites'"); | |
$i = 0; | |
foreach($aUsers as $user){ | |
This file contains 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 | |
include('bb-load.php'); | |
global $bbdb; | |
$aTopics = $bbdb->get_col( "SELECT topic_id FROM $bbdb->topics" ); | |
foreach( $aTopics AS $iTopic ) { | |
echo $iTopic.'<br />'; | |
bb_update_post_positions($iTopic); | |
} |
This file contains 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 | |
/* | |
Please read the bbPress 1 conversion article on foliovision.com before using | |
*/ | |
include('wp-load.php'); | |
global $wpdb; | |
$aPosts = $wpdb->get_results( "SELECT * FROM $wpdb->posts AS p JOIN $wpdb->postmeta AS m ON p.ID = m.post_id WHERE post_type IN ('forum','topic','reply') AND ( meta_key = '_bbp_old_topic_id' ) LIMIT 10000 " ); |
This file contains 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 | |
if( is_multisite() && function_exists('switch_to_blog') ) { | |
add_filter( 'get_avatar', 'fv_pb_global_avatar_start', 20, 5 ); | |
add_filter( 'get_avatar', 'fv_pb_global_avatar_end', 22, 5 ); | |
function fv_pb_global_avatar_start( $avatar ) { | |
switch_to_blog(1); | |
return $avatar; | |
} |
This file contains 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_action( 'wp_enqueue_scripts', 'tweak_fv_player_css_enqueue' ); | |
function tweak_fv_player_css_enqueue() { | |
global $fv_fp; | |
if( method_exists( $fv_fp, 'css_enqueue' ) { | |
$fv_fp->css_enqueue(true); | |
} | |
} |
This file contains 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
jQuery(document).on('mfpClose', function() { | |
jQuery('.flowplayer').data('flowplayer').unload() | |
} ); |
This file contains 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
var player = jQuery('<div id="background-video"></div>'); | |
jQuery('#wp-custom-header').append(player); | |
player.flowplayer( { | |
autoplay: true, | |
disabled: true, | |
loop: true, | |
clip: | |
{ | |
"sources": [ | |
{ src: "https://s3-eu-west-1.amazonaws.com/fv-player-unprotected/dominika-960-31_HD.mp4", type: "video/mp4" } |
This file contains 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 | |
/* | |
Plugin Name: FV Player Pro - Custom CDN | |
Description: Add Settings -> FV Player Pro -> Hosting -> BunnyCDN Extended which signs the URLs for use in SK and US countries only. | |
Author: Foliovision | |
Version: 0.1 | |
*/ | |
add_action( 'plugins_loaded', 'fv_player_custom_cdn_load', 0 ); |
OlderNewer