Forum Replies Created

Viewing 13 replies - 1 through 13 (of 13 total)
  • replacing this code

    $wp_remote_get_args = array(
    "user-agent" => "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.89 Safari/537.1"
    );

    with this code:

    $wp_remote_get_args = array(
    "user-agent" => "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.89 Safari/537.1",
    "sslverify" => false
    );

    Totally worked for me.

    Thread Starter ryanbuckley

    (@ryanbuckley)

    The filename for the template I am using is issuesinphotography.php and the code is here:

    https://gist.github.com/anonymous/9059752

    I also have the following function added to allow for the switch to a single-issues.php for the single page of this category. That function is:

    //Gets post cat slug and looks for single-[cat slug].php and applies it
    	add_filter('single_template', create_function(
    		'$the_template',
    		'foreach( (array) get_the_category() as $cat ) {
    			if ( file_exists(TEMPLATEPATH . "/single-{$cat->slug}.php") )
    			return TEMPLATEPATH . "/single-{$cat->slug}.php"; }
    		return $the_template;' )
    	);

    And permalink setting is set to custom: https://www.be-hold.com/%category%/%post_id%

    Thanks

    Thread Starter ryanbuckley

    (@ryanbuckley)

    Any ideas? The website is https://www.be-hold.com/

    I got it to work, but only through trial and error. Apparently I needed the attribute source=”albums” in my shortcode, although I didn’t see that anywhere in the documentation. However, although the following does work:

    [ngg_images source=”albums” album_ids=”1″ display_type=”photocrati-nextgen_basic_compact_album”]

    I am still getting the same error for:

    [ngg_images source=”albums” album_ids=”1″ display_type=”photocrati-nextgen_basic_slideshow”]

    Interestingly, the shortcode works fine for galleries, just not albums

    [ngg_images gallery_ids=”2,3,4,5,6″ display_type=”photocrati-nextgen_basic_thumbnails”]

    Is giving me a full grid of thumbnails for all the above-listed gallery ids. What’s wrong with the album shortcode?

    I’m having the same issue. Adding the following shortcode via the “text” panel, so smartquotes aren’t the issue. The obsolete shortcode, [album id=1 template=extend], at least shows my images, but the styling is totally off.

    [ngg_images album_ids=”1″ display_type=”photocrati-nextgen_basic_thumbnails”]

    Is giving me:

    Gallery not found. Please check your settings.

    Please help.

    Thread Starter ryanbuckley

    (@ryanbuckley)

    My apologies. Here is the correct formatting:

    <h1><?php echo single_cat_title( '', false ); ?></h1>
    <?php if ( category_description() ) : // Show an optional category description ?>
    <div><?php echo category_description(); ?></div>
    <?php endif; ?>
    </header><!-- .archive-header -->
    </div>
    
    <div style="clear:both;"> </div>
    
    <? /* Start the loop */
    if(have_posts()) : while(have_posts()) : the_post(); ?>
    
    <?php
    $this_category = get_category($cat);
    
    //if this is a parent category, only show sub-categories
    if (($this_category->cat_ID == 23) or ($this_category->cat_ID == 24) or ($this_category->cat_ID == 27)) { ?>
    
    <ul class="sub-categories">
    <?php wp_list_categories('sort_column=ID&sort_order=asc&list=1&optioncount=0&hide_empty=0&use_desc_for_title=1&children=0&child_of='.$this_cat.'&hierarchical=1&title_li='); ?>
    
    <?php /* end of Display sub-categories */ } ?>

    Thread Starter ryanbuckley

    (@ryanbuckley)

    I’ve actually gotten it to work. I’ll post my solution for others who may stumble upon this post in their own hunt.

    The code below will show all sub-categories to a parent category page, as long as you add those parent category IDs where they belong below:
    ` <h1><?php echo single_cat_title( ”, false ); ?></h1>
    <?php if ( category_description() ) : // Show an optional category description ?>
    <div><?php echo category_description(); ?></div>
    <?php endif; ?>
    </header><!– .archive-header –>
    </div>

    <div style=”clear:both;”> </div>

    <?<!– Start the loop –>
    if(have_posts()) : while(have_posts()) : the_post(); ?>

    <?php
    $this_category = get_category($cat);

    //if this is a parent category, only show sub-categories
    if (($this_category->cat_ID == 23) or ($this_category->cat_ID == 24) or ($this_category->cat_ID == 27)) { ?>

    <ul class=”sub-categories”>
    <?php wp_list_categories(‘sort_column=ID&sort_order=asc&list=1&optioncount=0&hide_empty=0&use_desc_for_title=1&children=0&child_of=’.$this_cat.’&hierarchical=1&title_li=’); ?>

    <?php /* end of Display sub-categories */ } ?>

    Thread Starter ryanbuckley

    (@ryanbuckley)

    Thank you alchymyth. Yes, I did create a category.php theme, and the $category_id values are outputting as expected. I don’t think it’s a theme issue though, so not sure if it belongs in the flato forum.

    As per Pioneer’s suggestion, I’ve been looking for themes that could do what I want, but I’ve found none.

    I’ll explain in more detail.

    I want a main “Inventory” page, which will link to my two main catogories “Photographers” and “Categories”. In each of these Parent pages, I would like to show a list of all the Sub-categories for only that parent category. Then, when the user clicks on a sub-category, all the posts for that sub-category are listed. The latter works, but the former parent-cateogry lists do not.

    I imagine this working like a folder system. Click on the parent folder, and you only see the contents of that ‘folder’. Nothing I’ve seen in any other theme so far has been useful for me to appropriate.

    Here is my category.php code:
    https://codepad.org/xQE0tjfi

    Forum: Plugins
    In reply to: Help finding solution
    Thread Starter ryanbuckley

    (@ryanbuckley)

    I’ve got this pretty-much figured out, but now encountering an odd error with wp_list_categories()

    I have it before the loop, and even with categories for which I know there are posts, i still get “No categories”.

    https://www.be-hold.com/category/category
    is a parent category to
    https://www.be-hold.com/category/category/contemporary-color
    which, as you can see, does contain posts

    Here is the code for my Categories page, which loads a grid if the visitor is viewing the subcategory (or child), or a list of categories if their on the parent:

    <?php if (is_category())
    {
    $category_id = get_query_var('cat');
    if ($category_id == '27' || $category_id == '24' || $category_id == '23') { ?>
    	<ul>
    	<?php wp_list_categories('child_of=$category_id'); ?>
    	</ul>
    <? }
    else {
    /* USER IS ON A SUB-CATEGORY, SO SHOW POSTS */

    Thanks

    I think this is a great request. I second it. Timbthumb is obsolete now that WP has its own thumbnail feature.

    i’m having the same issue. the permissions are correct and i do have GD installed on my server. any help?

    Forum: Plugins
    In reply to: Help finding solution
    Thread Starter ryanbuckley

    (@ryanbuckley)

    Okay, this request was probably a little overwhelming, but i’ve managed to figure out enough to get me started. I am using categories in conjunction with the “Category Grid View Gallery” plug-in. This way I am able to generate descriptive text and employ a shortcode to display all relevant posts in a thumbnail grid. Hope this helps anyone else looking for a similar solution.

Viewing 13 replies - 1 through 13 (of 13 total)