jduffell
Forum Replies Created
-
Forum: Developing with WordPress
In reply to: wp_query repeating blocks@bcworkz Nothing I can spot, I’ve stripped out any additional code and it appears to be doing the same, I am using the Advanced Custom Fields plugin, but aside from that, it’s a bit of a head scratcher. A long work around I’ve found is within the loop to parse the blocks, however I’m having to print values from an array into the relevant elements which is long winding and means additional code which is a bit of a pain.
add_action('acf/init', 'my_acf_init_block_types'); function my_acf_init_block_types() { if( function_exists('acf_register_block_type') ) { acf_register_block_type(array( 'name' => 'case-study', 'title' => __('Case Study'), 'description' => __('Predefined case study layout'), 'render_template' => 'templates/parts/block-case-study.php', 'enqueue_assets' => function() { wp_enqueue_style( 'css', get_template_directory_uri() . '/style/case-study.css' ); }, 'category' => 'formatting', 'icon' => array( 'background' => '#9FFF9F', 'foreground' => '#000000', 'src' => 'layout', ), 'mode' => 'edit', )); } }
Forum: Developing with WordPress
In reply to: wp_query repeating blocks@weboccults sure can ??
<?php $args = array( 'post_type' => 'case-study', 'nopaging' => true, 'orderby' => 'date', 'order' => 'asc', 'paged' => $paged, ); $wp_query = new WP_Query($args); if($wp_query->have_posts()) : while($wp_query->have_posts()) : $wp_query->the_post(); the_content(); endwhile; else: ?> <span class="content"> Sorry, no matching case studies could be found </span> <?php endif; wp_reset_query(); ?>
Forum: Fixing WordPress
In reply to: User relationships based on domaincheers for all the suggestions, good point about generic email addresses, it’s for a fairly closed site, and all I’m really trying to do is see if a related user has a value in one particular field, so shouldn’t really be pinching any other user data.
Cheeers
Forum: Fixing WordPress
In reply to: Storing array in session@lorro, cheers, very straight forward, I was certainly trying to overcomplicate it. Thanks for pointing me in the right direction.
^JD
Have done ??
Bingo, created a new app and it worked first time.
Cheers
Forum: Plugins
In reply to: [WP-PageNavi] Get pagination with $_POST@benattenborough cheers, I’ve got my fingers crossed that the plugin creator possibly knows of a work around, I’ve used the plugin throughout my site now and it works perfectly if only it could reference the necessary values when a pagination links submitted. Plus it works perfectly with a WP_User_Query script I have running.
It’s one of those where I feel so close but at the same time totally stumped for a workaround.
^JD
Forum: Plugins
In reply to: [WP-PageNavi] Get pagination with $_POSTHi guys, I’m having the exact same issue, I’m filtering posts using variables pulled with $_POST and when the navigation is selected these values are lost / not applied.
Did anyone have any look / have a possible solution that could be worth testing out.
Cheers.
^JDForum: Plugins
In reply to: [WP eCommerce] goldcart / sagepay protocol 3I’m having the same problem, please post if there are any solutions.
Cheers,
^JDForum: Fixing WordPress
In reply to: Conditional statement within an arrayCheers for that, I was totally overlooking this.
Forum: Plugins
In reply to: [Groups] WP_User_Query by GroupHi gtsiokos,
Cheers for that, I came across this and actually use it on profiles to output the user level which works quite well, I was trying to get users with a specific group at with WP_User_Query so that I could get 15 profiles, if I run the above within the actual loop and only 5 users belong to a certain queried group, the other 10 results would be redundant. So by filtering via the actual query I was hoping to eliminate that issue if that makes sense?
Cheers for the response though, much appreciated.
Forum: Plugins
In reply to: [amr users] User output@anmari cheers for getting back, it was mainly for the filters, I liked how simple they were to get on the front end, not really tinkered with creating my own front end filters but I may dig into it, cheers for the suggestions.
^JD
Forum: Fixing WordPress
In reply to: echo custom fields into arrayarray_sum sorted me out with a DB query
Forum: Meetups
In reply to: Liverpool/Wirral Meetups?Just had a goose, the next ones Sheffield (https://central.wordcamp.org/schedule), Liverpool sounds good, nice and close to Preston ??
Forum: Meetups
In reply to: Brighton Meet UpHi @jessicavalentine, the next UK meetup is in Sheffield.