• Resolved chicodarave

    (@chicodarave)


    Hello.
    I’m very newbie at html and php.
    I want to make several customizations in the css file, but just for slips (not for invoice).
    Which is the best way to do this?
    Is a good idea to have one css for each? Is this possible?
    My worry is to change something in the css and it change in both.

    Thanks.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Contributor Ewout

    (@pomegranate)

    Hi! You can use the document type (packing-slip or invoice) as a prefix:

    
    .packing-slip .order-number { display: none; }
    .invoice .billing-address { font-size: 120%; }
    

    Ewout

    Thread Starter chicodarave

    (@chicodarave)

    Perfect!
    Thank you very much!

    Your code worked but not on customized fields.
    How do I apply it on customized fields?

    That’s my code:
    .packing-slip .wc_order_field_2725 { font-size: 120%; }

    .invoice .wc_order_field_2725 { font-size: 120%; }

    Plugin Contributor Ewout

    (@pomegranate)

    You’ll need to make sure the custom field is wrapped in a div or span with that class!

    
    <span class="wc_order_field_2725">[your custom field code]</span>
    

    Where would I add your code;
    <span class=”wc_order_field_2725″>[your custom field code]</span>
    Besides the Custom Styles under PDF invoices?

    My customized field is added with a customizer plugin on woocommerce.
    I want the woocomerce pdf invoice to have those fields in bigger font size when I print it.
    You code (.invoice .wc_order_field_2725 { font-size: 120%; })worded on regular fields.
    Not on those customized fields.

    Plugin Contributor Ewout

    (@pomegranate)

    That code would go into your custom template. What’s the code you used to add the custom field? Did you follow the documentation – Displaying a custom field?

    Let me know!
    Ewout

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘CSS for invoice and slip’ is closed to new replies.