docs: donation embed & redirect-to-thank-you-page documentation - #1364
Draft
caseyhelbling wants to merge 2 commits into
Draft
docs: donation embed & redirect-to-thank-you-page documentation#1364caseyhelbling wants to merge 2 commits into
caseyhelbling wants to merge 2 commits into
Conversation
Document the donation form's embed parameters (donate button and custom iframe), with emphasis on the redirect / skipFinish / offsite interaction that is easy to get wrong. - docs/donation-iframe-embed.md: engineering source-of-truth for all embed query params and their data-attribute equivalents, plus the URL-construction rules (single ?, & encoding, redirect encoding for UTM destinations). - docs/help-center/: Help Scout article source for nonprofits, covering redirecting donors to a custom thank-you page, with a README handoff for CSR.
A hand-written iframe cannot perform the redirect on its own: on completion the form posts a commitchange:redirect message to the parent, and only the loader script (donate-button.v2.js) listens for it and navigates. Without the script on the host page, the redirect silently does nothing (the issue a live client hit). - Engineering doc: new section on the host-page listener requirement, the script snippet, and the stylesheet/resize side effect. - Help Scout article: iframe method now has Step 1 (add helper script) + Step 2 (iframe), a resize heads-up, and a troubleshooting entry.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds documentation for the donation form's embed parameters, prompted by a client (Warrior Foundation) hitting the common pitfalls when hand-writing a redirect iframe. None of this was documented anywhere (not the Help Scout KB, not the repo, not the tix/houdini wikis).
Files
docs/donation-iframe-embed.md— engineering source-of-truth. Full table of every embed query param and itsdata-*button equivalent, plus theredirect/skipFinish/offsiteinteraction and URL-construction rules. Verified against the widget/donate source (file refs included in the doc).docs/help-center/redirecting-donors-to-a-custom-thank-you-page.md— customer-facing Help Scout article source (nonprofit-friendly).docs/help-center/README.md— explains the help-center source folder and contains the CSR handoff notes.Key facts documented (verified in code)
?— a second?silently swallowsredirectinto the previous param (the bug the client hit).&is HTML encoding, correct inside an iframesrc; never typed in an address bar, never%26-encoded.skipFinishis iframe/query-only — there is nodata-skip-finishon the donate button.offsite=t(followup-step.js), which is why the button method redirects after "Finish" and the iframe+skipFinishredirects automatically.redirectvalue only needs URL-encoding once its destination has its own query string (e.g. UTMs).Handoff
docs/help-center/README.mdfor title/category/related-links.