Hello Jorugar,
Thanks for the report!
Since version 1.4.4 (and some improvements for alternative folder stuctures like Bedrock in 2.0.8), paths to the template files are stored relatively to the site base. However, if you have been using the plugin for a long time, it’s possible the paths were indeed still absolute. I have done many migrations myself without any issues.
Here’s an example of the settings as stored on one of my staging sites (table: wp_options, option_name: wpo_wcpdf_settings_general):
array (
'download_display' => 'display',
'template_path' => 'wp-content/plugins/woocommerce-pdf-invoices-packing-slips/templates/Simple',
'paper_size' => 'a4',
'currency_font' => '1',
'header_logo' => '',
'shop_name' =>
array (
'default' => '',
),
'shop_address' =>
array (
'default' => '',
),
'footer' =>
array (
'default' => '',
),
'extra_1' =>
array (
'default' => 'Extra 1',
),
'extra_2' =>
array (
'default' => 'Extra 2',
),
'extra_3' =>
array (
'default' => 'Extra 3',
),
)
As you can see, the path is relative, starting with wp-content
.
So I’m not sure why this was not working for you, but I’d like to fix this if possible.
Could you try the following?
- Go to WooCommerce > PDF Invoices > General
- Save the settings (to make sure it’s not stored as an absolute path if that’s how you have set that up now)
- Check the option
wpo_wcpdf_settings_general
in the wp_options
table in your database
If that is still the absolute path, could you send us an email at [email protected] so we can investigate the issue?
We don’t delete the settings when the plugin is deleted because sometimes people need to temporarily delete the plugin and don’t want to lose their settings. This shouldn’t be an issue when the paths are relative, but if that’s not working on some configurations obviously we need to fix that.
I hope you’re willing to cooperate for that, thanks in advance!
Ewout