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_shortcode( 'pavenum_video', function( $atts ) { | |
$a = shortcode_atts( array( | |
'id' => '', | |
'ratio' => '', | |
/*'legend' => '',*/ | |
'alt' => '' | |
), $atts ); |
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
window.addEventListener( 'DOMContentLoaded', ()=> { | |
const body = document.body, | |
scrollUp = "scroll-up", | |
scrollDown = "scroll-down", | |
offset = 0; | |
let lastScroll = window.pageYOffset; | |
if ( lastScroll > offset ) { | |
body.classList.add(scrollUp); |
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
//** Oxygen Composite Elements Settings Section **// | |
//** Edit the variables below to change the behavior of the element. **// | |
var closeOtherToggles = true; // Set this to true to close all other accordions when an accordion is expanded. | |
//** That's it, stop editing! **/ | |
jQuery(document).ready(function(){ | |
// Expand the content when row is clicked. | |
jQuery('body').on('click', '.oxel_accordion__row', function() { |
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 | |
function plang() { | |
if ( function_exists('pll_current_language') ) | |
return pll_current_language('slug'); | |
else | |
return 'fr'; | |
} | |
function phome() { |
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_filter('fluentform_rendering_field_data_select', function ($data, $form) { | |
if ($form->id != 10) | |
return $data; | |
if (\FluentForm\Framework\Helpers\ArrayHelper::get($data, 'attributes.name') != 'poste') | |
return $data; | |
$jobs = get_posts( [ 'post_type' => 'job' ] ); | |
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 | |
/* WARNING: Advanced SQL table modifications, USE AT YOUR OWN RISKS */ | |
/* IMPORTANT: You need to RESIGN SHORTCODES after executing this script */ | |
global $wpdb; | |
$sql = 'SELECT meta_id, meta_value | |
FROM ' . $wpdb->postmeta . ' | |
WHERE meta_key = "ct_builder_shortcodes"'; |
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
:root { | |
--columns-gap: 1rem; | |
} | |
@media (min-width:782px) { | |
.wp-block-column:not(:first-child) { | |
margin-left: var(--columns-gap); | |
} | |
} | |
@media (min-width:600px) and (max-width:781px) { |
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_filter( 'script_loader_tag', 'yankiara_defer_scripts', 10, 3 ); | |
function yankiara_defer_scripts( $tag, $handle, $src ) { | |
$defer = array( 'script-handle-1', 'script-handle-2', 'script-handle-3' ); | |
if ( in_array( $handle, $defer ) ) | |
return '<script src="' . $src . '" defer="defer" type="text/javascript"></script>' . "\n"; | |
return $tag; | |
} |
NewerOlder