summaryrefslogtreecommitdiff
path: root/src/components/Scotsoun.astro
diff options
context:
space:
mode:
authorJoe Carstairs <65492573+Sycamost@users.noreply.github.com>2023-08-13 20:33:03 +0100
committerJoe Carstairs <65492573+Sycamost@users.noreply.github.com>2023-08-13 20:33:03 +0100
commitf19fc78a151c761642cf7c9b654e0da9db3c4418 (patch)
tree4fb1c40c51151572ebd2c283e5ae8a6e819b83f1 /src/components/Scotsoun.astro
parentf6d45f7b9374444ae1ab751a213d86827b64eb8f (diff)
More robust relative path handling
Diffstat (limited to 'src/components/Scotsoun.astro')
-rw-r--r--src/components/Scotsoun.astro5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/components/Scotsoun.astro b/src/components/Scotsoun.astro
index 13c6fa9..1491ebc 100644
--- a/src/components/Scotsoun.astro
+++ b/src/components/Scotsoun.astro
@@ -5,6 +5,7 @@ import tComponent from '$i18n/translations/components/scotsoun';
import type Locale from '$types/Locale';
import type Scotsoun from '$types/Scotsoun';
import PayPalButtons from './PayPalButtons.astro';
+import relativePath from '$lib/relativePath';
interface Props {
locale: Locale;
@@ -30,7 +31,9 @@ const t = translate(locale);
</header>
<div class="product__action-block">
<img src={`/images/scotsoun/sscd${scotsoun.scotsounId}.jpg`} />
- <PayPalButtons successPageUrl={`./${scotsoun.scotsounId}/payment-success-confirmation`} />
+ <PayPalButtons
+ successPageUrl={relativePath(Astro.url.pathname, `payment-success-confirmation`)}
+ />
</div>
</div>