Skip to main content

Changing the order of my hosts, tickets in an event page

I have a fundraising event page. I'm using hosts and selling tickets. 

Hosts appear in alphabetical order in the drop-down menu I've noticed. I need the primary hosts (the people who's home the event is being held at) to appear first on this drop-down. Is there any way for me to change this order? 

Ticket levels appear smallest to largest. I need them to appear largest to smallest. Same thing, anywhere I can change this?

 

Official response from

Both host names and ticket levels are displayed using Liquid output tags and sorted as described by default. You can copy the generated HTML tags by viewing the source of the page and re-arrange the items in the page template, replacing the Liquid tags. This is considered a hack and any changes to ticket levels in the control panel will not be reflected.


 

UPDATE FROM BRIAN PALMER:

Per Jeffrey's comment below, you can reverse the order by adding "reversed" to the forloop. If you want the tickets to show up in an order other than highest-to-lowest or lowest-to-highest, there is another "code hack" for this that will allow changes made to ticket types in the control panel to update on the site:

If you take a look at the code in the "Template" tab of an event page (using a custom page template), you'll find a liquid forloop that loops through each ticket level. It will look something like this:

Screen_Shot_2017-03-03_at_8.15.37_AM.png

 

You can duplicate this forloop multiple times, using liquid IF/THEN statements to determine which ticket type each one applies to, like so:

Screen_Shot_2017-03-03_at_8.26.11_AM.png

 


 

Because you cannot copy and paste from that screenshot, the "IF" statements used were as follows:

{% if ticket_level.name == "General Admission" %}

{% endif %} 

 

{% if ticket_level.name == "VIP" %}

{% endif %} 

 

{% unless ticket_level.name == "General Admission" or ticket_level.name == "VIP" %}

{% endunless %}

Share this post

Showing 12 reactions

How would you tag this suggestion?
Please check your e-mail for a link to activate your account.