• hi,

    i am using wp 1.5.1 on an apache 1.3.20 and want to use the category-base field form “Edit Permalink Structure” in order to create permalinks like the pattern showed below:


    https://myblog.org/tarzan/
    https://myblog.org/tarzan/photos/
    https://myblog.org/tarzan/movies/

    wp is installed directly in the root directory and the value “/.” seems to let the wp_list_cats() run properly, but the links fail and i am getting a 404.

    mod_rewrite works fine, so i’ve no idea where to screw. any help appreciated. thx.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Perhaps Ryan’s little plugin will help:

    https://boren.nu/archives/2005/03/08/ungreedy-rewrite-plugin/

    Thread Starter infranic

    (@infranic)

    @kafkaesqui:
    many thxs for your advice! so i’ve found what i was searching for.

    hi there,
    i have a pretty similar problem, but the above site cant be reached (is boren.nu down?) …

    so maybe som1 knows how to deal with a “possibly-not-default” category-base. I want to link each Category-Name ($cat->cat_name) with its appropriate URL, but the only thing that comes into mind, is this URL joined together with a hardcoded /category/ in the middle:
    echo "href=\"" . get_bloginfo('url') . "/category/" . $cat->category_nicename."\"> bla </a>";

    how do i get the correct category-base from the db? (most preferrably using a template-tag… )
    thanks in advance

    pleeeaase im a db-fool … :-/

    ok, got it… but it only works the way i expected, when a category-base is set:
    <?php $catbase = $wpdb->get_var(“SELECT option_value FROM $wpdb->options WHERE option_id=47”); ?>

    what can i do to adress the case that no category_base is set: (if no value is set for category_base it returns “/” in my case, at least) how can i make sure, that my $catbase is always correct?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘using category-base for short paths’ is closed to new replies.