Posted: January 13, 2023 at 3:45 pm
I have multiple types of tickets on my form and I’m wondering if there is an easier way to create spacers between each section. Right now I’m just creating a ticket named “——–” with zero tickets available (so it shows Sold Out) but that lets me create separate sections. Just wondering if there is a cleaner way to do it. Let me know if you need to see it on our site. It is currently password-protected. Thanks. |
|
Forgot to check the box to notify me of replies. |
|
Can you use CSS to add space between the rows? |
|
I can look at that option. Is it possible to add CSS in between tickets on a registration form? |
|
This reply has been marked as private. | |
Hi there, It depends on what your trying to do really. The ticket selector is a table so you could use some CSS to add extra padding to specific tickets to add spacers, or we have an example of adding in extra rows for additional ‘headers’ in the table: https://gist.github.com/joshfeck/bee2bf7d59be77b363a7054dfd34bf45 That’s using the ticket selector CSS class to add a new row before specific tickets, for example in that snippet if you changed line 9 to be:
That would add a row before with a title ‘Registration’. Does that help? |
|
I’ll give that a try. Thanks! |
|
Tony – where would you add the text example from Github? Would that need to be added to a custom plug-in or does that go somewhere within Event Espresso setup? |
|
All PHP code snippets would go within a custom functions plugin, we have some documentation on creating one here: https://eventespresso.com/wiki/create-site-specific-plugin-wordpress-site/ Multiple sippets can be placed within a single plugin, just depends how you want to manage those. |
|
Tony – I was able to add the headers. Thanks! One more question – how do I change the shading so the header matches the section it is for? You can look at the registration page again to see what I am seeing. |
|
Sorry, I’m not sure I follow. By shading do you mean the font-weight or background? All of the ‘sections’ are the same currently as far as I can tell. |
|
Sorry for the delay in responding. I’m talking about the shaded background behind each ticket. Events and Contests has a gray background, but then Individual On-Site Contests is white. Memberships is white but then each membership ticket is gray. I just wasn’t sure if there was a way to control when it changes. Thanks! |
|
Ah, apologies, that just highlighted how poorly my monitor was set up! I couldn’t see that at all on one of the monitors and didn’t even think to switch. So that’s actually some styles from your theme, its style odd and even rows, adding in those additional single rows throws off the count so you see different styling. Controlling each of those ‘sections’ could be done, but it will need to be done by row count which ends up being fragile or starting each specific row, which then you need to remember to update as you add more tickets. The other option is to force th background to be the same for all rows. If you let me know which option you’d like to use I’ll advise further on how to do it. |
|
OK. That makes more sense that this is coming from the theme. I won’t worry about it then. Thanks! |
|
If just want them all uniform you can use something like this:
Add that to Appearance -> Customize -> Additional CSS. It specifically targets the ticket selector rows and removes the background from them all. |
|
That took care of it. Thanks! You can close the ticket. |
|
Awesome, your most welcome 🙂 |
|
The support post ‘Creating spacers between tickets?’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.