Forums

[resolved] changing permalink format (23 posts)

  1. visual mechanics
    Member
    Posted 2 years ago #

    i have permalinks settings in the "ugly" format and i want to change them to a pertty format as described in the how to section of this. what i don't understand is how to set up the new file strings.

    for instance i have a category called "pools" and want all the posts with that category name to be moved into an archive pools with the file string resembling category/pools/... and so forth.

    i am not sure if this will resolve how the category archives display. right now they display as abbreviated title only posts when the archive category is clicked on. I would like it to resolve to showing all the posts in full display per category and date archive. is this possible?

    how do i go about setting this up and is it possible once the blog is already in place?

    thanks in advance.

  2. Okoth1
    Member
    Posted 2 years ago #

    In the Admin area go to Settings --> Permalinks. Choose the last option and in the box behind it fill in

    /%category%/%postname%/

    Your link looks like: domain.com/pools/postname/

  3. visual mechanics
    Member
    Posted 2 years ago #

    that's all? what happens to posts that were originally broadcast in the ugly format?

  4. James
    Happiness Engineer
    Posted 2 years ago #

    WordPress automatically handles the 301 (permanent) redirects involving the old URLs.

  5. visual mechanics
    Member
    Posted 2 years ago #

    if i have several categories pools, stripmalls, skateparks, etc? can i create archive directories for these?

    pardon the questions, i just need to understand this in laymans terms before embarking on this.

    thanks.

  6. James
    Happiness Engineer
    Posted 2 years ago #

    I'm not sure what you mean by "archive directories".

  7. weirdnews
    Member
    Posted 2 years ago #

    If you would like to be found in google news you can set your custome permalinks to /%year%%monthnum%%day%%hour%/%category%/%postname%-%post_id% as google news looks for the 3 digit ending.

    Also if you do have trouble with "page not found 404 errors" I use plugins seo ultimate which tracks any 404 error then I use Redirection plugin and copy the dead link from the seo 404 and then place the new url both into redirection for 301. Also use webmaster tools so you can stay up on any 404s google may have and add those and their good links to your redirection plugin. Now you do not suffer any losses ;)

    WP does have a built in 301 redirection but I have found it doesn't work with many templates and themes.

  8. haydenhancock
    Member
    Posted 2 years ago #

    @visual mechanics,

    You can utilize the conditional tags in your archive.php to display information specific to each category.

    Or you can create category-[x].php files for specific categories (where [x] is your category name).

  9. visual mechanics
    Member
    Posted 2 years ago #

    @ macmanx, by directories i mean archives (or folders for lack of a better word) per category. the user wants the ability to be able to click on a category in the sidebar and load all of the posts related in full view, not just the links for each post as the default settings function.

    this is an example of how the archives should load.

    http://readymade.com/blogs/culture

    inside this blog when you click on the music archives in the sidebar on the lower right of the page they roll out like this...

    http://readymade.com/blogs/culture/category/music/

    still trying to wrap my head around this, and concerned that when i switch the permalinks to to a new structure the blog is gonna get all messed up.

    ??thanks,
    rob

  10. visual mechanics
    Member
    Posted 2 years ago #

    can anyone advise how and what i need to do to get these permalinks reconfigured so my posts are archived into literal strings?

    thanks

  11. James
    Happiness Engineer
    Posted 2 years ago #

    I guess I must be misunderstanding, because when I go to http://readymade.com/blogs/culture/category/music/ I see full posts, not "just the links for each post" that you mentioned. Were you able to resolve the issue?

  12. visual mechanics
    Member
    Posted 2 years ago #

    No I haven't been able to resolve this.

    If you go to http://readymade.com/blogs/culture and scroll down to the archive links on the right hand side of the page click on any of the categories.

    for instance the archive for "art"
    http://readymade.com/blogs/culture/category/art/

    in here all of the entries are previewed in full. this is what i am trying to resolve on my blog. when you click a category link on my blog it goes to a page the says "category archives: pools" with the entry titles. from there you have to click on a individual link rather than simply scrolling and previewing the entries in their entirety.

    does this make sense?

    thanks

  13. James
    Happiness Engineer
    Posted 2 years ago #

    Oh, so this is for a different blog. More than likely, your blog is using the_excerpt to display content in the category template. This only displays part of the post. You'll want to use the_content instead. See these for more info:

    http://codex.wordpress.org/Template_Tags/the_content

    http://codex.wordpress.org/Template_Tags/the_excerpt

  14. visual mechanics
    Member
    Posted 2 years ago #

    where do i put this code? correction.... is this the code i substitute for??

    <?php the_content( $more_link_text, $strip_teaser, $more_file ); ?>

    there was another detail regarding if need to display all of the content (which I want to do)

    <?php
    global $more; // Declare global $more (before the loop).
    $more = 1; // Set (inside the loop) to display all content, including text below more.
    the_content();
    ?>

    am i on the right track, if so what php file do I swap this code into?

    thanks

  15. James
    Happiness Engineer
    Posted 2 years ago #

    Look in your category template for a php tag that mentions "the_excerpt" and replace it with your tag.

    Yes, you're on the right track.

  16. visual mechanics
    Member
    Posted 2 years ago #

    the categories.php file within the wp-admin folder? the only file i can find named such. however, no mention of a tag in there containing the_excerpt

  17. James
    Happiness Engineer
    Posted 2 years ago #

    It's in your theme's folder. Go to Appearance/Editor in your admin panel and look for something like "Categories" or "categories.php".

  18. visual mechanics
    Member
    Posted 2 years ago #

    I'm using a theme called simplr and it doesn't have a categories.php file...

    these are all the files within my themes folder
    archive, archives, attachment, comments, footer, functions, header, image, index, links, nav, page, print.css, search, sidebar, single, sitemap, style.css

    feeling like i might be outta luck on this one...

  19. James
    Happiness Engineer
    Posted 2 years ago #

    The theme author has pobably combined the archive and category templates into one. Check "archive" and "archives".

  20. visual mechanics
    Member
    Posted 2 years ago #

    found this in the archive.php file

    <?php the_excerpt('<span class="more-link">'.__('Continued reading >', 'simplr').'</span>') ?>

    do i swap only the_excerpt tag or the entire string of code with 1. this string...
    <?php the_content( $more_link_text, $strip_teaser, $more_file ); ?>

    or
    2. this string..

    <?php
    global $more; // Declare global $more (before the loop).
    $more = 1; // Set (inside the loop) to display all content, including text below more.
    the_content();
    ?>

  21. James
    Happiness Engineer
    Posted 2 years ago #

    That is going to depend on how the theme works. First, try replacing "the_excerpt" with "the_content". Then, try replacing the entire tag with your first tag, then try replacing it with your second tag.

    Keep going, and maybe mix-and-match, until you get something you like.

  22. visual mechanics
    Member
    Posted 2 years ago #

    voila! the first attempt worked. i just swapped "the_excerpt" with "the_content".

    thanks so much for helping me with this. you rule!!!

    -rob

  23. James
    Happiness Engineer
    Posted 2 years ago #

    You're welcome!

Topic Closed

This topic has been closed to new replies.

About this Topic