Recent Topics

call categories by its cat_ID

Started by on Sep 17, 2007 – Contents updated: Sep 17, 2007

Sep 17, 2007 15:08    

I think this is a bug because as far as testing goes, all variations of URLs resolves correctly to the specific post except when the category name was changed. So, I thought, it was one of the logics missed, since all the rest are implemented.

I am talking about the Single post links and Category links.

I tried every possible combo configuration, moving categories here and there, making a category a sub-cat, making a sub-cat a parent, and so on and so forth, and all links resolves to the actual post or category even if the old URL variation is used.

Great! Whoever is behind that, great brain to track all of those. My theory is that the posts are called by their post_ID and the categories have a check if it is a sub-category, if true, it will pull the name of the parent cat, and so on. These two formula solves all other logics that may arise. (And I think b2evo is the first application that did this, others do a .htaccess or other tricks.)

But I found one that is not resolving, and that is, as the title "hints", if a category changes its name (which I will call "cat_name"), it makes the URLs using the cat or sub_cat "extra-path" methods invalid or 404 error.

I think it is best to the call the categories by its cat_ID so even if the cat_name changes, all old URLs with the "old cat_name" will still be valid and resolve correctly.

Old URL: http://domain.tld/technology/post-title1/
New URL: http://domain.tld/tech/post-title1/

The old URL above becomes invalid because the cat_name was changed.

So far, as far as testing goes, this is the only one logic left that do not resolves. All other variations, no matter how many times the blogger changes category parent-child order, or changes extra-path configurations, are all resolving correctly to the "new URL".

So congrats to that, I love it! That's why no matter what people say to me to migrate to Wordpress, I don't listen, coz the brains here in b2evo are the greatest.

One more logic, and every b2evo blogger can play with the URLs as much as they want.

Question, is moving a post from one blog to another really not possible and will kill the URL? Just noticed, since all post_IDs are "global", I mean, no post_ID will be the same on any blog (on a single b2evo installation), maybe there's a possibility. (another logic)

If we can do that, then I guess that will be even better.


Next to test: Sub-Domains, especially non-subdomain URL changes to a sub-domain URL. (another logic)

* Using "logic" to give a term to 'that' - logic.

Sep 23, 2007 00:27


1) renaming a category from technology to tech as in this example:
Old URL: http://domain.tld/technology/post-title1/
New URL: http://domain.tld/tech/post-title1/

will still allow resolution of the URL, as long as you don't change the post-title1 part.

2) It is completely possible to move a post from one blog to another. Just enable it in /conf/_advanced.php

... and let your WP friends know :p


Sep 23, 2007 15:10

Thanks! Tried a few more tests and it works.

Though changing URL from the regular /blogname/ to blogname.domain.tld (subdomain) gives an error.

Anyway, did a .htaccess redirect instead. :)


Form is loading...

Advanced CMS – This forum is powered by b2evolution CMS, a complete engine for your website.