Forum Replies Created
-
AuthorPosts
-
thoughtwell
MemberI suspect it may have something to do w/ the way I have the site's settings to display the home page. In the settings, I have the front page set to a page titled, 'home' in my pages. I then used a template file simply labeled 'home.php' but looking back, I probably should have named the file 'page-home.php' or 'front-page.php' and it would probably work as I originally intended.
Ultimately, I just used a conditional in the genesis simple hooks plugin under the genesis_after_header Hook for to get this to work by inserting:
<?php if( is_front_page() ) { ?> <div class="slideshow-wrapitup"> <div class="wrap"> <div class="flexslider"> <ul class="slides"> <?php $loop = new WP_Query(array('post_type' => 'smt_hm_slide', 'posts_per_page' => -1, 'orderby'=> 'ASC')); while ( $loop->have_posts() ) : $loop->the_post(); ?> <li> <div class="slide"> <?php $url = get_post_meta(get_the_ID(), 'url', true); if( ! empty($url)) { ?> <a href="<?php echo $url ?>"> <?php the_post_thumbnail('full'); ?> </a> <?php } else { echo the_post_thumbnail('full'); } ?> <div class="caption"><?php if( ! empty($url)) { ?> <a href="<?php echo $url ?>"><h5><?php the_title(); ?></h5></a> <?php } else { ?> <h5><?php the_title(); ?></h5><?php } the_content();?> </div> </div> </li> <?php endwhile; wp_reset_query(); ?> </ul> </div><!-- end flexslider --> </div><!-- end wrap --> </div><!-- end slideshow-wrapitup --> <?php genesis_widget_area( 'cta-1', array( 'before' => '<div class="ctawrap"><div class="wrap"><div id="cta1">', 'after' => '</div></div></div>', ) ); } ?>
... and then the rest of my 'home.php' template file kicks in. The 'home' page in my pages is just left blank. Probably a more efficient way to do this would be to combine everything into one file, renamed 'front-page.php' but at this point, I've moved on... so I will mark as resolved.
thoughtwell
MemberJust in case anyone else runs across this and needs help, I've answered my own question.
This article was a good bit of help:
http://davidchu.net/blog/genesis-2-0-html5-hooks/
You have to set priority and it will do what you (and I) wanted it to do.
badomp!
thoughtwell
MemberI'm not familiar w/ Agency Pro, but in most instances, the reason you may not be able to override those styles for gravity forms is because they are located within gravity forms's own plugin folder. You may be able to set classes for your gravity forms form elements in the advanced tabs, then assign styles to those classes to help you manipulate your form as needed.
Looks like you need to reduce the padding or margin on that form element to get the submit button tighter. You can do this in the related css file in your gravity forms plugin folder w/o having to assign custom classes, but if you ever update the plugin, you will have to rework the stylesheet because updates will overwrite your changes. I would see if you can assign custom classes in the form editor's advanced tabs for your form elements, first.
thoughtwell
MemberI found the answer. Set the grid_content_limit to the string, TRUE. This should remove the excerpt. However, it will move up the 'more' text/link (or whatever you have that as.) If you set this to FALSE, it may cut that off as well, but I didn't try it. Hope this helps.
thoughtwell
MemberCharlie, did you ever find any sort of answer for this? I am wondering how to do the same thing. I can't find this info, anywhere. I can see how to limit it to a specific number of characters, but I'm not sure of what value one would enter to achieve this effect. It could even be a string. Just not sure which one.
thoughtwell
MemberI checked out my version in the theme details and it says 2.0.1, so I think that should be correct. I also re-downloaded Nick's plugin again at version 0.8.1 from the WP Plugin Directory and tried reinstalling, but I still couldn't get it to work. I also tried opening the zip file and putting the entire plugin folder into my plugins directory, but still no luck.
I went into the actual plugin's file and I can see the function that checks the Genesis versioning. The variable, $latest is set to 1.8; I have 2.0.1 installed, so maybe it's something else, but I only have a very minimal amount of other plugins installed.
I think I have found the problem, though. In the plugin file, there is a statement that says something along the lines of if the templatepath is not set to genesis, the plugin forces deactivation and flags and error.
Soo...
Simple enough: You just have to deactivate your child theme, activate the Genesis parent theme, activate the plugin, then reactivate your child them.
This allowed me to activate the plugins. I still think it's strange I had to do this since I had Genesis installed the whole time; but I guess maybe there is something in my child theme that was conflicting that templatepath or whatever.
Thanks for your help on this... and I definitely agree that one must roll up their sleeves and dig a little deeper if they are going to create anything substantial. I think this rule applies across the board.
thoughtwell
MemberThanks David. No, I'm definitely not what you would call a good coder... but the idea is that by making myself do this when time permits, I will hopefully get there, lol. It's a long road, man.
I will try your suggestion and see if it works, but perhaps the plugin authors will eventually update the plugins for Genesis 2.0 now that it's been out for a few months... which is kind of one of the things about plugins... they just eventually lose support or things change, then my guess is you need to be a good coder if you want to keep on using them so you can debug/update on your own, especially the freebies.
The Genesis community has been great, though; so far very helpful, and there are a good amount of plugins at my disposal should I decide to take advantage.
thoughtwell
MemberThanks, Brad. The post on your blog was very informative. Changing the labels seems pretty straightforward, as explained.
Where I'm having trouble is actual default functionality of the breadcrumbs omitting the hierarchal taxonomy of the custom post type and pointing to the entire custom post type archive.
I notice in your post, there is an argument for hierarchal categories that points to 'true' which is maybe somewhat in the vein of what I'm looking for... but since the custom post type uses taxonomies rather than categories to organize the individual custom post types, I take it this argument is having no effect towards pointing the page level up to the taxonomy archive rather than the custom post type archive.
I guess I just need to figure out how to add in this functionality for taxonomies as well as categories if this is along the lines of what I should be looking at.
thoughtwell
MemberBrad, can you post a link of your article? I went to your blog, but it's so awesomely laden w/ articles that I had trouble finding this guide. BTW, your site has some great reading to it. I just subscribed!
Thx!
thoughtwell
MemberSo, before my loop, I just put:
query_posts(array('post_type'=>'product-categories','orderby'=>'menu_order','order'=>'ASC'));
Now, it seems to be working how I want it to. I'm not sure if this is the most current, semantic way to do this for 3.6 and Genesis 2.0, but it's doing what I want it to, so if anyone has any better suggestions using WP_Query, I'm all ears, but for now this seems to work.
thoughtwell
MemberHere is what is contained within my archive-product-categories.php page before trying to do the sorting filter w/ WP_Query:
<?php /** * The custom product-categories post type archive template */ /** Force full width content layout */ add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); /** Remove the post info function */ remove_action( 'genesis_entry_header', 'genesis_post_info', 12 ); /** Remove the post content */ remove_action( 'genesis_entry_content', 'genesis_do_post_content' ); /** Remove the post image */ remove_action( 'genesis_entry_content', 'genesis_do_post_image', 8 ); /* Add Product Category Title */ add_action('genesis_before_content', 'summit_productspg_title'); function summit_productspg_title() { ?> <header class="entry-header porthead"><h1 class="entry-title" itemprop="headline">Home Medical Equipment Products</h1></header> <?php } /** Add the featured image after post title */ add_action( 'genesis_entry_header', 'summit_productcat_grid' ); function summit_productcat_grid() { if ( has_post_thumbnail() ){ echo '<div class="productcat-featured-image">'; echo '<a href="' . get_permalink() .'" title="' . the_title_attribute( 'echo=0' ) . '">'; echo get_the_post_thumbnail($thumbnail->ID, 'product-categories' ); echo '</a>'; echo '</div>'; } } /** Remove the post meta function */ remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); genesis();
Here is what I have tried so far:
<?php /** * The custom product post type archive template */ /** Force full width content layout */ add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); /** Remove the post info function */ remove_action( 'genesis_entry_header', 'genesis_post_info', 12 ); /** Remove the post content */ remove_action( 'genesis_entry_content', 'genesis_do_post_content' ); /** Remove the post image */ remove_action( 'genesis_entry_content', 'genesis_do_post_image', 8 ); /* Add Product Category Title */ add_action('genesis_before_content', 'summit_productspg_title'); function summit_productspg_title() { ?> <header class="entry-header porthead"><h1 class="entry-title" itemprop="headline">Home Medical Equipment Product Categories</h1></header> <?php } // The Query $args = array( 'meta_key' => 'order', 'orderby' => 'meta_value', 'order' => 'DES' ); $query = new WP_Query( $args ); // The Loop if ( $query->have_posts() ) { while ( $query->have_posts() ) { $query->the_post(); echo add_action( 'genesis_entry_header', 'summit_productcat_grid' ); function summit_productcat_grid() { if ( has_post_thumbnail() ){ echo '<div class="productcat-featured-image">'; echo '<a href="' . get_permalink() .'" title="' . the_title_attribute( 'echo=0' ) . '">'; echo get_the_post_thumbnail($thumbnail->ID, 'product-categories' ); echo '</a>'; echo '</div>'; } } } } /** Remove the post meta function */ remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); genesis();
I don't know if it maybe has something to do w/ there being a key and value both set to 'order' (I'm really in the infancy of my php skillset). Also, since this is a custom post type archive file, is it really necessary to set the post_type? Well, I went ahead and did it anyhow, but it was still broken. Basically, making these edits breaks the page/gets me errors.
One of the things that confuses me is meta_key. If the 'order' field is natively set in the post attribute panel, it's technically not a custom field I have set up, per se. However, may it very well be that it is? I wouldn't think so, since I didn't actually set up a custom field in the post, but rather just input numerical values under the order field shown in the attributes panel.
-
AuthorPosts