Forum Replies Created
-
AuthorPosts
-
photoaddictsaMember
Thanks Brad,
The js loaded as I wanted but my theory failed. Seems like when you load the js in the head the responsive menu does not load at all.
I know the desktop nav flashing briefly before the responsive nav is a small issue but seems to annoy certain folks.
Do you perhaps know of a workaround solution for that problem (It's also described here: https://github.com/studiopress/genesis-sample/issues/102)
photoaddictsaMemberThanks Brad,
Will adding the new navigation code make the desktop navigaton touch friendly on tablets and laptops?
February 22, 2019 at 3:21 am in reply to: Desperate for help here: CPT archive redirects to single post #489666photoaddictsaMemberScratch my last reply, i named the archive php wrong.
Thanks for the help 🙂
February 22, 2019 at 3:14 am in reply to: Desperate for help here: CPT archive redirects to single post #489665photoaddictsaMemberOk, I managed to get it working on this url: https://inthebunch.co.za/live-streams/ by changing this line;
"has_archive" => "live-streams",
But now it looks like it's not using the custom archive page template, I named it:
archive-live-streams.php
photoaddictsaMemberThank you very very much @andytc,
Appreciate you taking the time to answer this, this will most definitely get me going the right way.
photoaddictsaMemberThanks @andytc,
Apologies for not being clearer. I've already got the archive file there, it's the loop that I'm battling with.
I'm using relationship fields, seemed like the best one for this idea.
Here is a graphic of what I'm hoping to achieve.
This one of the relationship fields.
<?php $posts = get_field('route'); if( $posts ): ?> <ul> <li> From:<?php the_field('route_from'); ?> </li> <li> To:<?php the_field('route_to'); ?> </li> </ul> <?php endif; ?>
In the graphic there is a column for the route, the above will then display:
- From: destination a
- To: destination b
Each post on the archive page will look like the graphic, no need to click through to a single post.
photoaddictsaMemberOk, I was searching for a solution from the wrong angle.
Got it sorted with the link you provided, thanks very much.
September 26, 2017 at 11:45 pm in reply to: Desperately need help with custom loop in archive #211908photoaddictsaMemberAh ok, awesome! Thanks very much.
September 26, 2017 at 4:56 am in reply to: Desperately need help with custom loop in archive #211866photoaddictsaMemberFigured it out, I was over thinking the whole thing a bit.
Working through some of your other tutorials actually helped me figure it out 🙂
September 22, 2017 at 1:17 pm in reply to: Desperately need help with custom loop in archive #211761photoaddictsaMemberThanks for the advice Brad, here is the gist link: https://gist.github.com/photoaddictsa/2343851119a91523940de538a831ac57
photoaddictsaMemberOh bloody hell, I never thought of that 🙂
Thank you very much good sir.
June 20, 2017 at 1:05 am in reply to: Display content at top of post inside genesis entry content #207968photoaddictsaMemberAwesome!!
Thanks very much Brad. Will be subscribing to your site, loads I can learn there.
June 20, 2017 at 12:52 am in reply to: Display content at top of post inside genesis entry content #207966photoaddictsaMemberoohh, yea, that's also a great, idea.
In that case (after registering the widget area) my code would look like this?
add_action( 'genesis_entry_content', 'add_genesis_widget_area', 9 ); function add_genesis_widget_area() { genesis_widget_area( 'custom-widget', array( 'before' => '<div class="custom-widget widget-area">', 'after' => '</div>', ) ); }
June 19, 2017 at 6:39 am in reply to: Display content at top of post inside genesis entry content #207930photoaddictsaMemberI had to re-open this one.
Victor, the solution you gave me worked but with a twist.
I'm currently using this code:
add_action( 'genesis_entry_content', include( get_stylesheet_directory() . '/yarpp-template-list.php'), 9);
Problem is that when I do that, the info jumps completely out and sits in the top left corner of the browser. See:
Here is the code of the php file I'm including:
<div class="yarppinline"> <h3>Related Posts</h3> <?php if (have_posts()): $postsArray = array(); while (have_posts()) : the_post(); $postsArray[] = '<a href="'.get_permalink().'" rel="bookmark">'.get_the_title().'</a><!-- ('.get_the_score().')-->'; endwhile; echo implode(', '."\n",$postsArray); // print out a list of the related items, separated by commas else:?> <p>No related posts.</p> <?php endif; ?> </div>
Am I doing something wrong?
June 15, 2017 at 7:36 am in reply to: Display content at top of post inside genesis entry content #207789photoaddictsaMemberI thought as much but had to take a chance 🙂
Thanks for all your help, much appreciated.
June 15, 2017 at 7:07 am in reply to: Display content at top of post inside genesis entry content #207783photoaddictsaMemberahh ok,
That makes perfect sense.
ok one more question, can I just change the priority?
The reason I'm asking is I am using Genesis simple hooks and inserted the content there? If not then I will re-write my code as you explained.
photoaddictsaMemberNever even thought of that one, thanks Brad.
photoaddictsaMemberHi Victor,
The hierarchy thing I get, it's the "if done correctly" bit I was battling with.
I had to call the header and footer for the code to end up working.
<?php /** * Template Name: Custom classifieds Archive * * */ get_header(); ?> <?php global $wp_query; remove_filter("the_content", "adverts_the_content"); echo shortcode_adverts_list(array( "category" => $wp_query->get_queried_object_id() )); ?> <?php get_footer(); ?>
photoaddictsaMemberI managed to track down the CPT slug but was unsuccessful, developer also confirmed it was "event"
I added the following to my functions file
add_post_type_support( 'event', 'genesis-seo' )
but that just breaks the site and gives me a 500 error. -
AuthorPosts