• Resolved flushdrew

    (@flushdrew)


    Hello,
    I want to customize the PDF so i copy the content of the Simple folder into my-child-theme/woocommerce/pdf/i-copy-here and my custom PDF isn’t apply.

    The original one is. How can i do this please?

    Thank you

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

    (@pomegranate)

    Have you also selected the ‘i-copy-here’ folder in the PDF Invoices > General settings? This folder needs to have a name other than ‘Simple’.
    We also have step by step instructions in the documentation: Creating a custom PDF template

    Let us know if that helps!
    Ewout

    hello I have a problem, in my ftp the path: wp-content / themes / enfold / woocommerce / pdf / yourtemplate does not exist. When I log in, I arrive at this point wp-content / themes / enfold / after I do not have the woocommerce folder but I have several woocommerce folders, but none of them just snooze “woocommerce” can you help me?

    and also wanting to enter the woocommerce folder (which is however out of the theme folder) inside, there is no pdf folder, so the whole path is not like the one you indicate. I do not know what I have to do

    Plugin Contributor kluver

    (@kluver)

    Hi @madame_ruvida,

    If your theme is WooCommerce enabled there will be a folder called ‘woocommerce’ if you go to wp-content/themes/enfold/. If there is no folder there your theme might not be WooCommerce enabled and you will have to create the ‘woocommerce’ folder yourself.

    Inside that folder you will have to create the ‘pdf’ folder yourself. And inside that you can copy the template files to create your custom template.

    So to recap. Go to wp-content/themes/enfold/. If there is no ‘woocommerce’ folder create one, and inside that folder create the ‘pdf’ folder for your template files.

    Here you can read the whole thing in a bit more detail: Creating a custom template
    Also I would recommend creating a child-theme when creating a custom template. If you create the custom template in your main theme and you update it your template will be lost.

    I hope this helps.

    With kind regards,

    Michael

    hello thanks for the quick reply, I tried to do what you suggested, I created in the folder of the theme “enfold” “woccomerce” and then inside woocommerce I created “pdf” and the template folder. seemed to work, but then in the checkout page when I try to pay the site crashes and does not send the invoice, first instead, yes, in fact if I delete the folders created everything starts to work properly. Moreover doing so, even after modifying the invoice.php file as shown, it still did not take my custom field “tax code / p.iva” so the problems are 2. Do you think that if I create the folder “pdf” directly in the folder “woocommerce” that I have out of the theme folder “enfold” can work? my theme is compatible with woocommerce in fact I installed a demo shop

    Plugin Contributor Ewout

    (@pomegranate)

    Hi! If the invoice does not get generated, it means that there is an error somewhere in your custom invoice.php.

    As michael mentioned, you should preferably not put any customizations in your theme folder because they will get overwritten when your theme is updated.

    Since you have 2 different problems, lets split the approach too ??

    Step 0: I strongly recommend creating a child theme first. Enfold has documentation about this too: Using a Child Theme . This step is not required for debugging the issue though.

    Step 1: Create the folder woocommerce/pdf/madame_ruvida in your (child) theme and copy the contents of the Simple template to this folder. Don’t make any changes yet. Can you select the new ‘madame_ruvia’ folder in the settings? Can you still create an invoice? Good! you have successfully created a custom template

    Step 2: Make your customizations. If something goes wrong, post the customizations you made so we can review what’s wrong.

    Ewout

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Custom PDF not work’ is closed to new replies.