<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Stripe &#8211; WordPress Memo</title>
	<atom:link href="https://blog.riverforest-wp.info/tag/stripe/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.riverforest-wp.info</link>
	<description>WordPress に関する覚え書き</description>
	<lastBuildDate>Fri, 09 May 2025 12:48:52 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://blog.riverforest-wp.info/wp-content/uploads/2018/05/cropped-icon-256x256-1-32x32.png</url>
	<title>Stripe &#8211; WordPress Memo</title>
	<link>https://blog.riverforest-wp.info</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>WooCommerce Stripe 決済での Apple Pay Google Pay への誘導</title>
		<link>https://blog.riverforest-wp.info/woocommerce-stripe-apple-pay-google-pay-notice/</link>
		
		<dc:creator><![CDATA[Katsushi Kawamori]]></dc:creator>
		<pubDate>Tue, 14 Nov 2023 01:50:52 +0000</pubDate>
				<category><![CDATA[WooCommerce]]></category>
		<category><![CDATA[Apple Pay]]></category>
		<category><![CDATA[Google Pay]]></category>
		<category><![CDATA[Stripe]]></category>
		<guid isPermaLink="false">https://blog.riverforest-wp.info/?p=3519</guid>

					<description><![CDATA[はじめに WooCommerce の決済で、プラグイン WooCommerce Stripe Payment Gateway を利用しています。このプラグインでは、Express checkouts で、Apple Pa [&#8230;]]]></description>
										<content:encoded><![CDATA[
<h3 class="wp-block-heading">はじめに</h3>



<p><strong><a href="https://ja.wordpress.org/plugins/woocommerce/">WooCommerce</a></strong> の決済で、プラグイン <strong>WooCommerce Stripe Payment Gateway</strong> を利用しています。このプラグインでは、<strong>Express checkouts</strong> で、<strong>Apple Pay</strong>, <strong>Google Pay</strong> を利用する事が可能です。</p>



<figure data-wp-context="{&quot;imageId&quot;:&quot;69cc63456133c&quot;}" data-wp-interactive="core/image" data-wp-key="69cc63456133c" class="wp-block-image size-large wp-lightbox-container"><img fetchpriority="high" loading="eager" decoding="async" width="1024" height="429" data-wp-class--hide="state.isContentHidden" data-wp-class--show="state.isContentVisible" data-wp-init="callbacks.setButtonStyles" data-wp-on--click="actions.showLightbox" data-wp-on--load="callbacks.setButtonStyles" data-wp-on-window--resize="callbacks.setButtonStyles" src="https://blog.riverforest-wp.info/wp-content/uploads/20231114/Screenshot-WooCommerce-Stripe-Settings-Express-Checkout-1024x429.png" alt="" class="wp-image-3530" srcset="https://blog.riverforest-wp.info/wp-content/uploads/20231114/Screenshot-WooCommerce-Stripe-Settings-Express-Checkout-1024x429.png 1024w, https://blog.riverforest-wp.info/wp-content/uploads/20231114/Screenshot-WooCommerce-Stripe-Settings-Express-Checkout-300x126.png 300w, https://blog.riverforest-wp.info/wp-content/uploads/20231114/Screenshot-WooCommerce-Stripe-Settings-Express-Checkout-768x321.png 768w, https://blog.riverforest-wp.info/wp-content/uploads/20231114/Screenshot-WooCommerce-Stripe-Settings-Express-Checkout.png 1381w" sizes="(max-width: 1024px) 100vw, 1024px" /><button
			class="lightbox-trigger"
			type="button"
			aria-haspopup="dialog"
			aria-label="拡大する"
			data-wp-init="callbacks.initTriggerButton"
			data-wp-on--click="actions.showLightbox"
			data-wp-style--right="state.imageButtonRight"
			data-wp-style--top="state.imageButtonTop"
		>
			<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" fill="none" viewBox="0 0 12 12">
				<path fill="#fff" d="M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z" />
			</svg>
		</button></figure>



<p>ただし、 Apple Pay, Google Pay が<strong>対応している端末でしかボタンが表示されません</strong>。ユーザーが非対応端末で購入の際、「Apple PayとGoogle Payに対応した端末とブラウザをご利用の場合は、それぞれのボタンが表示されます。」の様なメッセージが出れば、決済手段が増え、買い手・売り手共に、有益であると思います。その辺りを、<a href="https://wordpress.org/support/topic/message-when-hiding-apple-pay-and-google-pay/"><strong>サポートフォーラム</strong></a>へ投稿し、提案中です。提案が通るか通らないかわかりませんし、それまでに時間がかかるだろうと思われるので、標準の WooCommerce のフックで対応してみました。</p>



<div class="wp-block-columns is-layout-flex wp-container-core-columns-is-layout-28f84493 wp-block-columns-is-layout-flex">
<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow">
<style>
.simpleblogcard_img_blockbfc16c8cc64a426a11a7d39c2badb52b {
  float: right;
  padding: 10px;
}
.simpleblogcard_borderbfc16c8cc64a426a11a7d39c2badb52b {
  border-left: solid 8px #cd162c;
  padding: 0.25em 0.25em;
  background: transparent;
}
.simpleblogcard_titlebfc16c8cc64a426a11a7d39c2badb52b {
  line-height: 155%;
  font-weight: bold;
  display: block;
}
.simpleblogcard_descriptionbfc16c8cc64a426a11a7d39c2badb52b {
  line-height: 155%;
  color: #333;
}
</style>
<div class="simpleblogcard_wrap">
			<a style="text-decoration: none;" href=https://ja.wordpress.org/plugins/woocommerce-gateway-stripe/>
				<figure class="simpleblogcard_img_blockbfc16c8cc64a426a11a7d39c2badb52b">
			<img decoding="async" style="border-radius: 5px; width: 100px; height: 32px;" src="https://ps.w.org/woocommerce-gateway-stripe/assets/banner-772x250.png?rev=3234748" alt="WooCommerce Stripe Payment Gateway – WordPress プラグイン | WordPress.org 日本語" />
		</figure>
		<div class="simpleblogcard_inner">
		<div class="simpleblogcard_borderbfc16c8cc64a426a11a7d39c2badb52b">
			ja.wordpress.org			<div class="simpleblogcard_titlebfc16c8cc64a426a11a7d39c2badb52b">
				WooCommerce Stripe Payment Gateway – WordPress プラグイン | WordPress.org 日本語			</div>
							<div class="simpleblogcard_descriptionbfc16c8cc64a426a11a7d39c2badb52b">
					Accept debit and credit cards in 135+ currencies, many local methods like Alipay, ACH, and&#8230;				</div>
					</div>
	</div>
	<div style="clear: both;"></div>
	</a>
</div>
</div>



<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow">
<style>
.simpleblogcard_img_block03a49fb5f0fc9bedf7bf35cd67e6e2de {
  float: right;
  padding: 10px;
}
.simpleblogcard_border03a49fb5f0fc9bedf7bf35cd67e6e2de {
  border-left: solid 8px #cd162c;
  padding: 0.25em 0.25em;
  background: transparent;
}
.simpleblogcard_title03a49fb5f0fc9bedf7bf35cd67e6e2de {
  line-height: 155%;
  font-weight: bold;
  display: block;
}
.simpleblogcard_description03a49fb5f0fc9bedf7bf35cd67e6e2de {
  line-height: 155%;
  color: #333;
}
</style>
<div class="simpleblogcard_wrap">
			<a style="text-decoration: none;" href=https://www.apple.com/jp/apple-pay/>
				<figure class="simpleblogcard_img_block03a49fb5f0fc9bedf7bf35cd67e6e2de">
			<img decoding="async" style="border-radius: 5px; width: 100px; height: 52px;" src="https://www.apple.com/jp/apple-pay/images/meta/apple_pay__h5hcdax8_c08w264834sy_og.png?202603300140" alt="Apple Pay - Apple（日本）" />
		</figure>
		<div class="simpleblogcard_inner">
		<div class="simpleblogcard_border03a49fb5f0fc9bedf7bf35cd67e6e2de">
			www.apple.com			<div class="simpleblogcard_title03a49fb5f0fc9bedf7bf35cd67e6e2de">
				Apple Pay &#8211; Apple（日本）			</div>
							<div class="simpleblogcard_description03a49fb5f0fc9bedf7bf35cd67e6e2de">
					Apple Payは安全で、安心で、プライバシーを守りながら支払える方法です。				</div>
					</div>
	</div>
	<div style="clear: both;"></div>
	</a>
</div>
</div>



<div class="wp-block-column is-layout-flow wp-block-column-is-layout-flow">
<style>
.simpleblogcard_img_blockf46ec34e2574951c2f4caced520a530d {
  float: right;
  padding: 10px;
}
.simpleblogcard_borderf46ec34e2574951c2f4caced520a530d {
  border-left: solid 8px #cd162c;
  padding: 0.25em 0.25em;
  background: transparent;
}
.simpleblogcard_titlef46ec34e2574951c2f4caced520a530d {
  line-height: 155%;
  font-weight: bold;
  display: block;
}
.simpleblogcard_descriptionf46ec34e2574951c2f4caced520a530d {
  line-height: 155%;
  color: #333;
}
</style>
<div class="simpleblogcard_wrap">
			<a style="text-decoration: none;" href=https://pay.google.com/intl/ja_jp/about/>
				<figure class="simpleblogcard_img_blockf46ec34e2574951c2f4caced520a530d">
			<img decoding="async" style="border-radius: 5px; width: 100px; height: 53px;" src="https://lh3.googleusercontent.com/-HMMzVNh69gL0SsLMReGytn-Wf10oFHBOO05oixe5pKe5762nCu8YGadIHQ2xj5wGW4irBS_eUZ3riQhsl63THzhkMjJYx43mzBa2Z7Wf8NNGT4HicbO=w1200-l80-sg-rj" alt="Google Pay - オンラインでのシームレスなお支払い、店舗でのお支払い、送金に" />
		</figure>
		<div class="simpleblogcard_inner">
		<div class="simpleblogcard_borderf46ec34e2574951c2f4caced520a530d">
			pay.google.com			<div class="simpleblogcard_titlef46ec34e2574951c2f4caced520a530d">
				Google Pay &#8211; オンラインでのシームレスなお支払い、店舗でのお支払い、送金に			</div>
							<div class="simpleblogcard_descriptionf46ec34e2574951c2f4caced520a530d">
					Google Pay を使用すれば、オンラインや店舗でのお支払いも、友だちや家族への送金も迅速、簡単、安全に行なえます。お支払いも Google で。				</div>
					</div>
	</div>
	<div style="clear: both;"></div>
	</a>
</div>
</div>
</div>



<h3 class="wp-block-heading">表示</h3>



<p>カート画面と支払い画面に表示するようにしました。ただし、対応端末でアクセスしてボタンが表示されている時にもメッセージが見えてしまいます。</p>



<figure data-wp-context="{&quot;imageId&quot;:&quot;69cc6345625f4&quot;}" data-wp-interactive="core/image" data-wp-key="69cc6345625f4" class="wp-block-image aligncenter size-full wp-lightbox-container"><img loading="lazy" decoding="async" data-wp-class--hide="state.isContentHidden" data-wp-class--show="state.isContentVisible" data-wp-init="callbacks.setButtonStyles" data-wp-on--click="actions.showLightbox" data-wp-on--load="callbacks.setButtonStyles" data-wp-on-window--resize="callbacks.setButtonStyles" width="504" height="764" src="https://blog.riverforest-wp.info/wp-content/uploads/20231114/screenshot-cart.png" alt="" class="wp-image-3531" srcset="https://blog.riverforest-wp.info/wp-content/uploads/20231114/screenshot-cart.png 504w, https://blog.riverforest-wp.info/wp-content/uploads/20231114/screenshot-cart-198x300.png 198w" sizes="auto, (max-width: 504px) 100vw, 504px" /><button
			class="lightbox-trigger"
			type="button"
			aria-haspopup="dialog"
			aria-label="拡大する"
			data-wp-init="callbacks.initTriggerButton"
			data-wp-on--click="actions.showLightbox"
			data-wp-style--right="state.imageButtonRight"
			data-wp-style--top="state.imageButtonTop"
		>
			<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" fill="none" viewBox="0 0 12 12">
				<path fill="#fff" d="M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z" />
			</svg>
		</button></figure>



<figure data-wp-context="{&quot;imageId&quot;:&quot;69cc634562c4a&quot;}" data-wp-interactive="core/image" data-wp-key="69cc634562c4a" class="wp-block-image aligncenter size-full wp-lightbox-container"><img loading="lazy" decoding="async" data-wp-class--hide="state.isContentHidden" data-wp-class--show="state.isContentVisible" data-wp-init="callbacks.setButtonStyles" data-wp-on--click="actions.showLightbox" data-wp-on--load="callbacks.setButtonStyles" data-wp-on-window--resize="callbacks.setButtonStyles" width="858" height="784" src="https://blog.riverforest-wp.info/wp-content/uploads/20231114/screenshot-checkout.png" alt="" class="wp-image-3532" srcset="https://blog.riverforest-wp.info/wp-content/uploads/20231114/screenshot-checkout.png 858w, https://blog.riverforest-wp.info/wp-content/uploads/20231114/screenshot-checkout-300x274.png 300w, https://blog.riverforest-wp.info/wp-content/uploads/20231114/screenshot-checkout-768x702.png 768w" sizes="auto, (max-width: 858px) 100vw, 858px" /><button
			class="lightbox-trigger"
			type="button"
			aria-haspopup="dialog"
			aria-label="拡大する"
			data-wp-init="callbacks.initTriggerButton"
			data-wp-on--click="actions.showLightbox"
			data-wp-style--right="state.imageButtonRight"
			data-wp-style--top="state.imageButtonTop"
		>
			<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" fill="none" viewBox="0 0 12 12">
				<path fill="#fff" d="M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z" />
			</svg>
		</button></figure>



<h3 class="wp-block-heading">コード</h3>



<pre class="prism line-numbers"><code class="language-php language-html">/** ==================================================
 * WooCommerce Notice Apple Pay or Google Pay
 *
 */
function notice_apple_pay_google_pay() {
  ?&gt;
    &lt;div class="woocommerce-info"&gt;Apple PayとGoogle Payに対応した端末とブラウザをご利用の場合は、それぞれのボタンが表示されます。&lt;/div&gt;
  &lt;?php
}
add_action( 'woocommerce_after_cart_totals', 'notice_apple_pay_google_pay' );
add_action( 'woocommerce_before_checkout_form', 'notice_apple_pay_google_pay' );
</code></pre>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
