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 if( !is_user_logged_in() ) : ?> | |
<form action="<?php echo site_url('wp-login.php?action=register', 'login_post') ?>" method="post"> | |
<input type="text" name="user_login" value="Username" id="user_login" class="input" /> | |
<input type="text" name="user_email" value="E-Mail" id="user_email" class="input" /> | |
<?php do_action('register_form'); ?> | |
<input type="submit" value="Register" id="register" /> | |
</form> | |
<?php else : echo 'You are already logged in.'; endif; ?> |
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 | |
acf_form_head(); // Place this before wp_header(); | |
$options = array( | |
'post_id' => 'user_'.$current_user->ID, | |
'field_groups' => array($form_group_ID), // $form_group_ID is the post id of the form group to show. | |
'submit_value' => 'Update Profile' | |
); | |
echo '<p>Your username is <b>'.$current_user->user_login.'</b>. This cannot be changed.</p>'; | |
acf_form( $options ); // http://support.advancedcustomfields.com/forums/topic/front-end-and-custom-user-meta/ | |
?> |
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 | |
/** | |
* acf_group_fields | |
* | |
* This function return an array of all the field names within a field group. | |
* | |
* @type function | |
* @date 24/9/14 | |
* @since 5.0.8 | |
* |
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($) { | |
function fadeloop(){ // loops through elements and fades them sequentially | |
$('.my-element').each(function( index, element){ | |
$(element).delay(index*4000).fadeIn(500).delay(3000).fadeOut(500); | |
}); | |
} | |
function fade(){ // calls itself to repeat | |
window.setTimeout(fadeloop, 0); | |
window.setTimeout(fade, 16000); | |
} |
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 | |
// Loads FontAwesome & assigns dashicon prefixed classes to correspond to FontAwesome fallbacks. | |
// This allows 'dashicons-' to be used when declaring custom post type icons. | |
function font_awesome_icons(){ ?> | |
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> | |
<style> | |
.dashicons-before:before { font-family: dashicons, FontAwesome; } | |
.dashicons-suitcase:before { content: "\f0f2"; } | |
.dashicons-cutlery:before { content: "\f0f5"; } | |
</style> |
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
// LINE 3927 of input.js | |
///////////////////////////// | |
// OLD CODE | |
//////////////////////////// | |
// update inputs | |
this.$el.find('.input-lat').val( lat ); | |
this.$el.find('.input-lng').val( lng ).trigger('change'); |
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 | |
$args = array( | |
// Get children of current page | |
'post_parent' => $post->ID, | |
'post_type' => 'page', | |
); | |
$query = new WP_Query($args); |
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 | |
/** | |
* @func acfw_location_rules | |
* Return an array of rules for use with register_field_group() 'location' key | |
* @param array $a | |
* @param str $param | |
* @param str $operator | |
* @param bool $extended | |
*/ | |
function acfw_location_rules( array $a, $param, $op, $extended = false ){ |
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 | |
$args = array( | |
'post_type' => 'morning_show' | |
); | |
$actors = new WP_Query($args); | |
if ( $actors->have_posts() ) : while ( $actors->have_posts() ) : $actors->the_post() : | |
the_field('actors'); |
OlderNewer