Andy Tschiersch
Forum Replies Created
-
Regarding this message:
<body <br /> <b>Notice</b>: Undefined index: apple_pay in <b>wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-apple-pay.php</b> on line <b>290</b><br /> class="home page-template-default page page-id-4647 logged-in">
This is a simple thing. This notice (it’s not an error) occurs only until you saved the stripe settings page and the value for the checkbox “Enable Apple Pay” is set to yes or no. Let’s have a look on the code where this notice occurs:
public function body_class( $classes ) { if ( 'yes' === $this->_gateway_settings['apple_pay'] && isset( $gateways['stripe'] ) ) { $classes[] = 'wc-stripe-legacy'; } return $classes; }
The isset() check should here be the first condition. Further I think $gateways[‘stripe’] is here irrelevant, because is not defined in this inside this function. It should look so:
if ( isset( $this->_gateway_settings['apple_pay'] ) && 'yes' === $this->_gateway_settings['apple_pay'] ) {
- This reply was modified 7 years, 8 months ago by Andy Tschiersch.
- This reply was modified 7 years, 8 months ago by Andy Tschiersch.
Forum: Plugins
In reply to: [qTranslate] HOME menu link resets selected language back to defaluti just found out that the additional plugin “qTranslate slug” fixed this problem allready. if you also want to translate url slugs of pages und posts, you want this plugin anyway.
Forum: Plugins
In reply to: [qTranslate] HOME menu link resets selected language back to defalutin my opinion the best work arround (works with banner-link and home-nav-link):
add this code to your functions.php
function qtrans_convertHomeURL($url, $what) { if($what=='/') return qtrans_convertURL($url); return $url; } add_filter('home_url', 'qtrans_convertHomeURL', 10, 2);
i found this solution here
Forum: Plugins
In reply to: Custom Post Type with rewrite slugomg, my fault, my fault, my fault…
I have forgotten to ad the $rewrite-Array to the $args-Array:
'rewrite' => $rewrite,'
I’m so sorry.
AndyForum: Plugins
In reply to: Custom Post Type with rewrite slugHi Christoph,
thank you very much for this hint, but unfortunately it still does not work. I have also read this article (https://omfgitsnater.com/2012/06/using-flush_rewrite_rules-with-your-custom-post-types/) and tried a lot. I’m afraid I’ll have to rename the CPT, but I would like to know why this does not work.
Thank you,
Andy