0

So {vehicle_make} is the channel field I have created, and it's using a dropdown select. I have entered in 100 vehicle make names, line by line, into this dropdown select.

Now I would like show the appropriate {vehicle_emblem} image linked to each {vehicle_make} on my template.

  1. My first question is with how to link these two channels together: If I pull the {vehicle_make} of Acura (based on segment_3 possibly, if my URL structure is example.com/browse/make/acura), how can I show the {vehicle_emblem} image of the Acura logo next to the {vehicle_make} word of "Acura"?
  2. My second question is how do I link from a list view template page to a details view template page, of the generated {vehicle} channel group content?

Thanks!

1

You could do that way easier! create a channel called something like "vehicle_brands". create a field group with all the fields you can need for the brands such as:

  • {title}
  • {vehicles_brand_name}
  • {vehicles_logo}
  • {vehicles_country}
  • {vehicles_rel_models} (relationship field to a models channel)
  • etc

This way you have all data in from the desired make in one channel entry. So on the example.com/browse/ page you can easily show a listing of all makes, with logo's etc:

{exp:channel:entries channel="vehicle_brands" dynamic="no"}
{vehicles_brand_name} - <img src="{vehicles_logo}" /><br>
This car comes from {vehicles_country}<br>
<a href="/browse/make/{url_title}/">View all details</a><br>
{/exp:channel:entries}

Then for the detail page, create a template in the browse group called make. In there you can show all details like this:

{exp:channel:entries channel="vehicle_brands" dynamic="no" url_title="segment_3" limit="1"}
{vehicles_brand_name} - <img src="{vehicles_logo}" /><br>
This car comes from {vehicles_country}<br>
More details
{/exp:channel:entries}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy