Sean Turtle
Forum Replies Created
-
Hi Metusalem, I seem to have the same issue (also using the same plugins) – can you explain what you did to fix this please?
Forum: Plugins
In reply to: [Front End PM] fep_filter_user_name – don’t show in blocking alertsThank you so much!
- This reply was modified 4 years ago by Sean Turtle.
Forum: Plugins
In reply to: [Front End PM] Add ACF user field$profile_image = get_field('profile_image', 'user_'.$member->ID);
Forum: Plugins
In reply to: [Front End PM] Add ACF user fieldIt’s not the WP avatar I’m using – it’s an ACF image field.
Forum: Plugins
In reply to: [Front End PM] fep_filter_user_name – don’t show in blocking alertsadd_filter( 'fep_filter_user_name', function( $name, $id ){ if ( $name && fep_get_the_id() ) { $name = '<a href="/member/' . $id .'">' . $name . '</a>'; } return $name; }, 10, 2);
Forum: Plugins
In reply to: [Front End PM] fep_filter_user_name – don’t show in blocking alertsSo, in the alert box when you click to block someone, I don’t want the new string I’ve applied using that filter to be shown.
For the alert box, I just want it to remain as you’ve coded it.
Does that make sense?
Forum: Plugins
In reply to: [Front End PM] Automatically insert hyperlinksThat doesn’t appear have changed anything?
Forum: Fixing WordPress
In reply to: Inject custom field into headerSorry, that code wasn’t even correct. This is the code in place:
<?php $css_query = new WP_Query(); $css_query->query('category_name=mag_post&showposts=1'); while ($css_query->have_posts()) : $css_query->the_post(); ?> <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'template_url' ); ?>/css/<?php echo get_post_meta($post->ID, 'custom_css', true); ?>" /> <?php endwhile; ?>
But still nothing.
Forum: Fixing WordPress
In reply to: Load a single post as homepage// Custom Stylesheet box in Pages/Posts add_action('admin_menu', 'digwp_custom_css_hooks'); add_action('save_post', 'digwp_save_custom_css'); add_action('wp_head','digwp_insert_custom_css'); function digwp_custom_css_hooks() { add_meta_box('custom_css', 'Name of custom CSS file', 'digwp_custom_css_input', 'post', 'normal', 'high'); add_meta_box('custom_css', 'Name of custom CSS file', 'digwp_custom_css_input', 'page', 'normal', 'high'); } function digwp_custom_css_input() { global $post; echo '<input type="hidden" name="custom_css_noncename" id="custom_css_noncename" value="'.wp_create_nonce('custom-css').'" />'; echo '<input type="text" name="custom_css" id="custom_css" style="width:100%;" value="'.get_post_meta($post->ID,'_custom_css',true).'" />'; } function digwp_save_custom_css($post_id) { if (!wp_verify_nonce($_POST['custom_css_noncename'], 'custom-css')) return $post_id; if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) return $post_id; $custom_css = $_POST['custom_css']; update_post_meta($post_id, '_custom_css', $custom_css); } function digwp_insert_custom_css() { if (is_page() || is_single()) { if (have_posts()) : while (have_posts()) : the_post(); $filename = get_post_meta(get_the_ID(), '_custom_css', true); if ($filename) { echo "<link rel='stylesheet' type='text/css' href='" . get_bloginfo('template_url') . "/css/" . $filename . "' />"; } endwhile; endif; rewind_posts(); } }
Forum: Fixing WordPress
In reply to: Load a single post as homepageAs potentially going forward, they’ll be a fair few custom css files, and I don’t want to load them all when they’re not required.
Forum: Fixing WordPress
In reply to: Load a single post as homepageHi dhunink
Sorry if it wasn’t clear. I’m using a script I found at ‘Digging into WordPress’, and it allows you to reference a custom css file when you’re putting the post together.
Problem is, it only loads the custom css file once you’ve clicked on the link. If <?php the_content(); ?> is referenced in the home page (minus the css) it looks cack, as it’s using the default css.
Does that make sense?
Turts