Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Discussion Url Change

hi, my english is bad. Sorry.. I want to change url.

for example;

mydomain.com/vanilla/discussion/6/title ==>> mydomain.com/vanilla/6/title or mydomain.com/vanilla/test/6/title

Answers

  • mydomain.com/vanilla/discussion/6/title ==>> mydomain.com/vanilla/6/title or mydomain.com/vanilla/test/6/title

  • R_JR_J Ex-Fanboy Munich Admin

    Look at this two discussions
    https://open.vanillaforums.com/discussion/13226/resolved-change-discussions-url-name
    https://open.vanillaforums.com/discussion/31488/how-to-make-short-discussion-urls-for-vanilla

    @riverred said:
    mydomain.com/vanilla/discussion/6/title ==>> mydomain.com/vanilla/6/title or mydomain.com/vanilla/test/6/title

    In that example I would like to replace "vanilla" by "forum" to avoid confusions

    Your address consists of the following parts
    Domain: "example.com"
    Subfolder: "forum"
    Controller: "discussion"
    DiscussionID: "123"
    Discussion Name: "some-title"

    That is standard:
    example.com/forum/discussion/123/some-title

    That is impossible, because discussions can be named the same:
    example.com/forum/some-title

    All the rest is possible but beware that there are naming conventions in your forum:
    example.com/forum/profile/123/username
    Taht is a valid profile link and it must still work if some discussion is named "profile". Therefore you shouldn't use that pattern for discussions:
    example.com/forum/some-title/123/some-title

    The safest way to get shorter urls is described in the second link above.

  • exactly what I want;

    mydomain.com/vanilla/discussion/6/title ==>> mydomain.com/vanilla/konu/6/title
    mydomain.com/vanilla/profile/serkan ==>> mydomain.com/vanilla/profil/serkan
    mydomain.com/vanilla/categories ==>> mydomain.com/vanilla/kategori
    mydomain.com/vanilla/discussion/comment/82/ ==>> mydomain.com/vanilla/konu/yorum/82/
    mydomain.com/vanilla/activity ==>> mydomain.com/vanilla/aktivite

    I want to translate all...

  • K17K17 Français / French Paris, France ✭✭✭

    @riverred It work as R_J say's above.
    I think translate all link would need to change controller names (don't know if it's possible without core changes).

  • R_JR_J Ex-Fanboy Munich Admin

    @riverred said:
    exactly what I want;

    mydomain.com/vanilla/discussion/6/title ==>> mydomain.com/vanilla/konu/6/title
    mydomain.com/vanilla/profile/serkan ==>> mydomain.com/vanilla/profil/serkan
    mydomain.com/vanilla/categories ==>> mydomain.com/vanilla/kategori
    mydomain.com/vanilla/discussion/comment/82/ ==>> mydomain.com/vanilla/konu/yorum/82/
    mydomain.com/vanilla/activity ==>> mydomain.com/vanilla/aktivite

    I want to translate all...

    Look here: https://open.vanillaforums.com/discussion/31488/how-to-make-short-discussion-urls-for-vanilla

    Instead of shortening the "discussion" to "d" make it "konu".

    Repeat for all the others.

  • K17K17 Français / French Paris, France ✭✭✭

    @R_J a dit :
    Instead of shortening the "discussion" to "d" make it "konu".

    Repeat for all the others.

    But this will not change links, so for vanilla it will be /discussion in all liks displayed ?

  • R_JR_J Ex-Fanboy Munich Admin

    @K17 said:

    But this will not change links, so for vanilla it will be /discussion in all liks displayed ?

    Oh yes, you are absolutely right! I totally forgot about that. Vanilla has some internal functions which build those links (though not all of them).

    There are the functions discussionUrl(), commentUrl() and userUrl which would have to be changed, too. Replacing those functions (by copying them to bootstrap.before.php and changing them there) should take care for some of those "issues"

    But I suspect that there are several other places which have some of this words hard coded, e.g. the Smarty functions and class.theme.php

    So there might be no way for a 100% transformation...

Sign In or Register to comment.