URL Portion when creating new Forum

Ryan Kent

Well-known member
I recognize the URL Portion is an optional field which can either rename the URL to the forum, or simply remove the id #. Can anyone offer some examples of a situation where it would be a benefit to use this option?

I noticed it is used on the XenForo site for about half the forums: Announcements, Have You Seen, Styles, etc. I am just not clear on the value of this change.
 
That worked!

I checked the Use Full Friendly URLs option and it seems thinks look good. It seems like I am learning because, as a teacher once shared with me...."you know you are learning when an answer to one question leads you to two more". I am hoping you can enlighten me a bit further to two follow up questions this creates

1.
Use Full Friendly URLs
If you enable this option, the links generated by the system will not include "index.php?". However, to enable this, mod_rewrite must be available and an appropriate .htaccess file must be in place.

Since the friendly URLs are appearing am I to assume that mod_rewrite is available and the appropriate .htaccess file is in place?

2. My URL now matches what I see on the XenForo forums. For example my "website" forum link is http://www.terapvp.com/community/forums/website

The URLs Floris provided seem cleaner. I understand the reason for the URL length is because my forum software was installed in the community folder within my public_html folder. Is there a way for me to remove "community" from all my URLs without removing the folder and dumping all my files into the general public_html folder? Or is there another benefit to leaving the /community level in similiar to these XenForo forums?
 
There's no real benefit to leaving the community directory intact, it just contains your forum and prevents your other files getting lost within the XenForo directory. It also separates your main site from your forum, assuming you run it separately.

As for removing the directory but containing the files in a directory (other than public_html) I'm not too sure. I've never done it before.
 
Since the friendly URLs are appearing am I to assume that mod_rewrite is available and the appropriate .htaccess file is in place?
Yes.
If it's working then your server meets the requirements.


Is there a way for me to remove "community" from all my URLs without removing the folder and dumping all my files into the general public_html folder? Or is there another benefit to leaving the /community level in similiar to these XenForo forums?
You can't remove it from the URL without physically relocation the files.

Only you can decide whether ton install the forum in the root or a directory.
It depends what your future plans are and whether you will ever have, for example, an index.php in the root, which you wouldn't be able to do if you installed the forum there.
You can't have 2 index.php files in the same directory.
 
Just when I thought I had all the universe's answers on URL Portions, a new question arose....

The URL Portion box says "Note that once specified, changing this value will cause URLs to be broken." My question is what if you don't originally provide a value in the URL Portion box, but later add one. Will that cause links to be broken?

Example. A forum is created called XenForo - Europe. When the forum is created the URL Portion field is left blank. A month later you decide to split the forum in two: XenForo - Eastern Europe and XenForo - Western Europe. The old XenForo-Europe forums is renamed to XenForo - Eastern Europe, and a new forums is added for XenForo - Western Europe. When the change is made, you add a URL Portion of XF-East. Will this change cause any links to break?
 
Oracle, when adding a URL portion, you can still access it purely from the ID. The portion of the URL before the ID (if an ID is appended) is irrelevant, see below:
http://xenforo.com/community/forums/2 (Announcements)
http://xenforo.com/community/forums/something.2 (Announcements)
http://xenforo.com/community/forums/announcements/ (Announcements)

If you don't add a URL portion, you will (by default) be using link #2 above. As you can see, the forum/category name is irrelevant as long as the ID is correct.

Hopefully this answers your question.
 
It's only the forum URL link which will change, not any posts or threads as the URLs for those do not include the forum.
This thread for example is: http://xenforo.com/community/threads/url-portion-when-creating-new-forum.12313

So as long as you don't have hundreds of links to the forum URL (assuming you give it a URL stub), it won't really be an issue.

Edit: Ninja'ed by James :D
 
Top Bottom