0

I followed Boyink's tutorial to the letter but still can't get template routes to work.

My multi-entry template is located at company/people. My single entry template is at company/person.

In the Template Route manager, I have /company/people/{bio:alpha_dash} for the `company/person template.

Multi-entry template link code:

<a href="{route="company/people" bio="{url_title}"}">

Single-entry template channel entries tag:

{exp:channel:entries
    channel="people"
    limit="1"
    require_entry="yes"
    dynamic="no"
    url_title="{segment:bio}"
    disable="categories|category_fields|member_data|pagination"}

All of the links in the multi-entry template look like: /company/%7Broute=

I don't understand why the URL's are not getting generated correctly.

Any help is appreciated.

7
  • Have you set the routes on Route Manager?
    – Sobral
    Jun 25, 2015 at 20:57
  • Yes. In the Template Route manager, I have /company/people/{bio:alpha_dash} for the company/person template.
    – mediapimp
    Jun 25, 2015 at 20:58
  • /company/%7Broute= translates as /company/{route=. Is /company/%7Broute= the full generated URL?
    – Sobral
    Jun 25, 2015 at 21:29
  • Yes. That is all that is being generated.
    – mediapimp
    Jun 25, 2015 at 21:30
  • I can't think on anything else than a syntax error. It looks like some " or } is missing somewhere. For now, you can use a root relative link: <a href="/company/people/{url_title}">.
    – Sobral
    Jun 25, 2015 at 22:05

1 Answer 1

0

I can't think on anything else than a syntax error. For now, you can use a root relative link:

<a href="/company/people/{url_title}">

It looks like some " or } is missing somewhere. Maybe some javascript? Or some CSS rule? Try to look for them or to replace the " by ' inside the {route}:

<a href="{route='company/people' bio='{url_title}'}">

You can also, use the good old {url_title_path}:

<a href="{url_title_path='company/people'}">

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.