Forum Replies Created

Viewing 15 replies - 1 through 15 (of 18 total)
  • Thread Starter LBA1403

    (@lba1403)

    Now it works perfectly. Thanks again, Chrystl!

    Hehe, I am sort of my own theme author. I made the theme following along a youtube-tutorial, and after that I’ve sort of expanded the site to able to fit my needs.

    This problem concern those who has followed the WP theme tutorial made by AwfulMedia.

    Thread Starter LBA1403

    (@lba1403)

    I found my wp_nav_menu. Turns out it was in the header, not in the functions

    ‘<?php wp_nav_menu( array( ‘container_class’ => ‘main-nav’, ‘container’ => ‘nav’ ));?>’

    Thread Starter LBA1403

    (@lba1403)

    Hmm, it turns out I don’t have one. The only thing I have in my functions concerning menus is the register_nav_menus

    Thread Starter LBA1403

    (@lba1403)

    I can’t really understand how I’ve done it, but it seems the first time I managed to remove the Locale-code when I added Norwegian. However, I fixed it by simply deleting Norwegian from the list and then adding it again.

    Now it works perfectly, thank you very much for your time and your suggestions Chrystl!

    Thread Starter LBA1403

    (@lba1403)

    After I tried the new flags it worked for the English, so I’m halfway!

    When I try to change the “Locale” for Norwegian and I hit “update” it won’t save my change! Any idea why it’s like this?

    Thread Starter LBA1403

    (@lba1403)

    Yeah, I have done that as well. I want to have flags for English and Norwegian, and I’ve saved the files as “en_US.png” and “nb.png” in the wp-content/polylang directory and uploaded them (I can see them in my browser when I enter the directory)

    In the “locale” field it’s correct for the US one, but it wont save it for the norwegian.

    Thread Starter LBA1403

    (@lba1403)

    Hi Chrystl

    Nope, it still doesn’t work.

    Thread Starter LBA1403

    (@lba1403)

    @andrew

    I do not see where you mean @chirag asked for my login credential , he was just trying to help me fix my problem. Also, as this is a rather small job, paying for this sort of service was not my intention.

    @chirag I ended up removing “larsarholmnet_posts” as it was causing too much problems, and then everything worked out just fine. Thank you very much for your time and your answer.

    Thread Starter LBA1403

    (@lba1403)

    @chirag

    I am quite sure since all posts showed up before I added this code, and these were only posts from larsarholmnet_posts. The categories are also selected..

    I just don´t understand why it doesn´t work..

    Thread Starter LBA1403

    (@lba1403)

    @chirag

    Thank you very much for answering my question. Your explanation makes much sense, however it does not appear to work. When I try to enter my categories page it does not show any content, only the header and the footer. If you enter larsarholm.net you can see for yourself. Do you have a different suggestion?

    Also, it was a small mistake in the suggested code, it lacked a comma after the “larsarholmnet_posts”, which did cause a white screen of death until being fixed. So that is not the problem..

    Thread Starter LBA1403

    (@lba1403)

    @webbrewers Well, if WP already did it, I would not be asking. I haveset it up with categories in the navigation, but the posts are not sorting them, only giving me all the posts in all the categories pages..

    Thread Starter LBA1403

    (@lba1403)

    I most certainly can do!

    <?php get_header();?>
    
    <section class="featured-post fifteen columns row">
    <h1><?php single_cat_title(); ?></h1>
    <ul>
    <?php
    	$query = new WP_Query( $args );
    	while ($query->have_posts()) : $query->the_post();
    	?>
    
        <div class="cat-thumb">
        <a href="<?php the_permalink(); ?>">
       <h2><?php the_title();?></h2>
        <?php the_post_thumbnail('cat-thumb'); ?>
       <p><?php the_excerpt(); ?></p>
         </a></div>
    
    <?php endwhile;?>
        </ul>
    <div id="push"></div>
    </section>
    
    <?php get_sidebar();?>
    
    <?php get_footer();?>
    Thread Starter LBA1403

    (@lba1403)

    Thank you for your response!

    I am a bit new to both WP and php, so I’ll have to ask the stupid question, when you say “without a query in category.php” do you mean to remove the lines I’ve posted in the first post and then copy+paste the code-snippet into my functions.php?

    I guess it wasn’t, because when I did that it didn’t make it any better, it shows no posts..

    But I made a child theme, seemed like a very good idea, thanks for the suggestion!

    Thread Starter LBA1403

    (@lba1403)

    Currently I have this on top of my category.php:

    $cat_name = get_the_category( $id );
    “$args = array( ‘posts_per_page’ => 6, ‘post_type’ => ‘larsarholmnet_posts’, ‘category-name’ => ‘$cat_name’ );”

    How would it be possible for me to alter this so that it only shows one category pr. page based on the category name?

    Thread Starter LBA1403

    (@lba1403)

    Hmm, I do not understand why, but suddenly it works perfectly fine after I added a page.php, not that it should matter.. Well, I guess Im just supposed to go on never knowing what the error was, oh well, at least it works now, thank you Steven for your suggestions anyway!

Viewing 15 replies - 1 through 15 (of 18 total)