You need replace every instance of $this->settings[‘opt-name’] with $this->get_option(‘opt-name’) in the shipping-awd.php file.
For example, on line 55 you must replace
$this->enabled = $this->settings['enabled'];
with
$this->enabled = $this->get_option('enabled');
Replace every instance and the plugin will work again.
ok i will do that and say the result !
… no work : this one not at all shipping !
It works like a charme for me. Are you sure you’ve modified the right lines of code?
Hello
in textwrangler i have choice in search > Find and replace
$this->settings
to
$this->get_option
and no shipping !
yet
is it important change [ to ( ?? maybe that
i will see
Of course it is. “get_option” is a function.
you are a nice guy but… now
Fatal error: Can’t use method return value in write context in /homez.764/artisanau/www/wp-content/plugins/awd-weightcountry-shipping/shipping-awd.php on line 65
on this lign i get
$this->options = isset( $this->get_option(‘options’) ) ? $this->get_option(‘options’) : ”;
désolée je vois bien que c’est une imbécilité, mais je ne sais pas la corriger ! in english
sorry I see that this is a stupidity, but I do not know the correct!
Thank you guy to help me yet !
Here is the final “init” function:
function init() {
$this->init_form_fields();
$this->init_settings();
$this->enabled = $this->get_option('enabled');
$this->title = $this->get_option('title');
$this->country_group_no = $this->get_option('country_group_no');
$this->sync_countries = $this->get_option('sync_countries');
$this->availability = 'specific';
$this->countries = $this->get_option('countries');
$this->type = 'order';
$this->tax_status = $this->get_option('tax_status');
$this->fee = $this->get_option('fee');
$this->options = (array) explode( "\n", $this->get_option( 'options' ) );
}
wouhh (ouahh in french) yeh
that work now
thank you so much !
and good year to you !
You’re welcome!
And happy new year to you too 😉