Custom design of woocommerce admin tickets on front-end community events

Home Forums Calendar Products Community Events Custom design of woocommerce admin tickets on front-end community events

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #1047222
    Cesar
    Participant

    Hello,

    On the page for creating an event (with community), I want to activate JUST WooCommerce tickets. Also, I want to delete fields like description ticket and customize the HTML.

    I know that the tables to add tickets are in /wp-content/plugins/event-tickets/src/admin-views/meta-box.php but how do you customize ? Via templates or functions ?

    Thank you very much

    #1047510
    Geoff B.
    Member

    Welcome back Cesar,

    Thank you for your question.

    I know that the tables to add tickets are in /wp-content/plugins/event-tickets/src/admin-views/meta-box.php but how do you customize ? Via templates or functions ?

    To customize the HTML, the best approach is to customize the template files by following our Themer’s guide .
    This will give you total control over what you display to your users.

    And since, all the customization is done in your WordPress theme, you can also use your theme’s functions.php to filter out unwanted fields.
    On that topic, I recommend reading the following entry in our Knowledge base (required fields for events submission form).

    I hope this helps you accomplish exactly what you are looking to do.

    Please let me know if you require further assistance on this topic or if you have any other questions.

    Happy holidays!

    Geoff B.

     

    #1047590
    Cesar
    Participant

    Thank you for your response.

    I already customized the plugin with your guide. This works to customize views (in the folder « view » ) but when they are parts of the admin-views folder, you can not customize them.

    I understand for the filters to be included in my functions.php but that does not allow me to change the HTML.

    Thanks

    #1050061
    Geoff B.
    Member

    Good afternoon Cesar,

    Great, I am glad to see you have made some customizations already.

    You are absolutely right, you cannot include the admin views in your template (sorry for the confusion).

    Actually, using filters in functions.php can let you change what is displayed in the HTML (in this case when meta-box.php is called).

    The only catch is that sometimes, your WordPress theme might interfere with the filter.

    To summarize, this leaves you with 3 potential solutions:

    1. Modify meta-box.php directly (which is not ideal and will not survive upgrades)
    2. Use a custom function to filter what is returned in the HTML
    3. Use CSS to hide the unwanted fields that are not mandatory

    Solution 3 is probably the fastest.

    Since all rows have a “ticket” class, you will have to use adjacent sibling CSS targeting.
    Here is an example of how you can hide the “Ticket description” field row

    https://gist.github.com/GeoffEW/58b47ea4097ddda9e962

    Note that the second line is necessary to make sure you only hide the ticket description and not every other field after!

    Hope this helps! Let me know if it does.

    Have a great evening.

    Geoff B.

    #1076451
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘Custom design of woocommerce admin tickets on front-end community events’ is closed to new replies.