1.2 Route Filters

Thảo luận trong 'Have you seen...?' bắt đầu bởi [BOT] Leecher, 17/5/13.

1votes
5/5, 1 vote

  1. [BOT] Leecher

    [BOT] Leecher Member

    Bài viết:
    31
    Likes :
    109
    Route Filters are a new system in XenForo 1.2 to allow you to change the standard URLs generated by XenForo, including any URLs generated by add-ons.

    It's a fairly simple system to show, but it's very powerful with a little thought. Let's look at what you can set with it:

    s61

    Other than a list of route filters, that's really it for the system. So how about a few examples...

    Changing a route prefix
    There's an add-on that does this right now, but we can do it simply from here. For example, if you want to change the resources URL to downloads, you'd just enter resources/ in the find box and downloads/ in the replace box.

    Instantly, any links to http://xenforo.com/community/resources/ would become http://xenforo.com/community/downloads/. URL canonicalization would still happen, but it'd use the new URLs.

    So yes, if you want to change the forums prefix, you can do that.

    Note that the find and the replace fields both need to start with a "prefix" (basically, alphanumeric and dash), so you can't simply remove a route prefix. Doing that would break everything.

    Changing a more specific URL
    If you want to change a specific URL--or any URL that begins with a particular string--you can do that with route filters.

    Maybe you have a page with a URL like pages/page-name/ and you'd rather it be page-name/. You can do that by simply entering those in the find and replace boxes respectively.

    You can even create different URLs for specific threads if you wanted to, or maybe a different URL for navigating pages in threads--find: threads/{title}/page-{num:Digit}, replace: threads/{title}/{num:Digit}-duplicate-posts .

    While it may require a bit of manual work, you could get pretty creative with your URLs. You could even give your page URLs hierarchy, if that's how you store your pages:

    pages/btcc/ -> btcc/
    pages/btcc-2013/ -> btcc/2013/
    pages/btcc-2013-drivers/ -> btcc/2013/drivers/
    pages/btcc-2013-races/ -> btcc/2013/races/

    Creating aliases
    Up until this point, I haven't mentioned the "incoming URL conversion only" option. I've assumed that it hasn't been checked up until now.

    This option lets you allow a URL to work but it doesn't affect what's considered the canonical version. So maybe we want to have releases/114 take us to our 1.1.4 release threads/xenforo-1-1-4-released.47030/ but we want the original URL to be the real URL. We could do that by putting threads/xenforo-1-1-4-released.47030/ in the find box and releases/114 in the replace box. I'm aware this might seem backwards, but the system is written from the perspective of outgoing conversions, so find represents the URL XF is generating; the incoming conversion reverses it. It means that you don't have to swap the values in find/replace if you check/uncheck the incoming only option.



    ...So go wild!
     
    Đang tải...
  2. Mr.Huy

    Mr.Huy Member

    Bài viết:
    221
    Likes :
    27
  3. VXF

    VXF Be like no other .. Staff Member

    Bài viết:
    1,277
    Likes :
    2,175
    Đây là 1 chức năng của Xenforo 1.2. Sao bạn lại hỏi có addon ko ?​
     
    thuatdl and Mr.Huy like this.
  4. Mr.Huy

    Mr.Huy Member

    Bài viết:
    221
    Likes :
    27
    để xài cho 1.1.5, bị auto reg nick ko có cách nào chặn hết bạn à
     
  5. ku Hiệu

    ku Hiệu Lì Lắm Luôn

    Bài viết:
    1,345
    Likes :
    862
    đổi capcha là xong
    các loại capcha trên rum có đó
     
  6. Mr.Huy

    Mr.Huy Member

    Bài viết:
    221
    Likes :
    27
    Là sao bạn, đổi câu trả lời hay để dạng captcha nhập ký tự?
     
  7. Hoàng Thiên Quân

    Hoàng Thiên Quân Member

    Bài viết:
    544
    Likes :
    110
    có nhiều loại capcha, như xếp hình, , nhập câu trả lời.... tùy vào hình thức sử dụng, nhưng tất cả chỉ là hạn chế tối đa có thể, chứ ko hoàn toàn 100%
     
  8. Mr.Huy

    Mr.Huy Member

    Bài viết:
    221
    Likes :
    27
    Nó vượt captcha mà bạn
     
  9. Hoàng Thiên Quân

    Hoàng Thiên Quân Member

    Bài viết:
    544
    Likes :
    110
    mình ko có nói là hạn chế 100% mà, nếu hạn chế 100% thì làm gì có update :D
     
  10. thuatdl

    thuatdl Member

    Bài viết:
    672
    Likes :
    182
    Cái auto reg nick nó vượt được capcha nhưng ko vượt được câu hỏi bảo mật, đặc biệt là câu hỏi Tiếng Việt.
     
  11. Mr.Huy

    Mr.Huy Member

    Bài viết:
    221
    Likes :
    27
    được bạn, mình đặt câu hỏi nó vượt ào ào luôn đấy
     
  12. lamnm88

    lamnm88 Member

    Bài viết:
    159
    Likes :
    10
    của mình cũng bị vượt ào ào mới đau

    http://raovat141.com/ bác nào vào xem thử hộn cái ? spam banh xác luôn
     
comments powered by Disqus

Chia sẻ trang này

Đang tải...