• Hello,

    I am using a WP Template (MassivePress) which displays the images from each post in a box in the sidebar as a secondary – visual – index of posts. You can click on an image and it takes you to the post.

    In order for this to work, it is necessary to create a category and name it ‘featured’.

    This means that each time I make a post I have to create a small image or particular dimensions – and add each post to the category named ‘featured’ – as well as the relevant content category.

    – BUT the default URL for every post is
    https://www.domainname.com/featured/postname.html
    instead of what I woudl prefer (and what would be far more SE friendly) –
    https://www.domainname.com/relevantcategory name/postname.html

    I don’t understand why it always defaults to ‘featured’ category – is there some way of changing this or ‘hiding’ that category in some way. It is only necessary for the sidebar feature and has no other useful function on my site.

    Thanks,
    P

Viewing 5 replies - 1 through 5 (of 5 total)
  • Try doing this.

    In your admin dashboard –> Settings –> Writing –> Default Post Category –> Select your category. Save changes.

    Thread Starter Phildub

    (@phildub)

    Thanks – do you mean I have to do that for every post? There doesn’t seem to be an option to link default to particular posts.

    Currently mine is set to ‘General’ – yet none of my posts have General in the URL when it displays.

    In the Default Post Category drop down menu it gives me the name of all the categories I have created but, of course, I don’t want it do default to one category – I want it simply not to default to ‘Featured’ every time and see nothing in this which explains why it dies so.

    Thanks for posting – any further advice or suggestions gratefully received.
    Phil

    You can change the category that features your post, but we need to see the code to tell you what to change.

    You might even want to change it to a tag instead of category. Just post the relevant code from the theme here. Or, at least link to the theme.

    Phildub,

    I think the problem lies in the fact that you have multiple categories (featured + relevant) for a post, and permalinks set to categories.

    WordPress can only pick one for the permalinks.

    There are some workarounds:
    1 – I looked at the Massive Press live demo, and their permalinks are set to date+name of post. (To me the best is “name of the post”)
    You can customize the permalinks in your admin settings.
    This is the easiest way.

    2 – Read “manage categories”, and “using multiple categories in a post”.

    3 – I looked at the Massive Press theme, and the files where the “featured” category is called, are:

    third-page.php
    third-single.php
    third.php

    the call appears like this
    <?php query_posts('category_name=featured&showposts=9'); ?>

    What you can try to do is, uncheck the “Featured” category for your last three posts.

    Then take away the call to that category from the files
    <?php query_posts('showposts=9'); ?>

    Test to see is now the last three posts show their relevant category.

    Hope this helps!

    How do you make images into the thumbnails? I just can’t figure it out!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Can I Change The Default Category Name Which Appears In My URLs?’ is closed to new replies.