Template:GuestbookWidget: Difference between revisions
somepage>Prabal Fix Add-a-Memory link: VE cannot open section=new in visual mode; switch to full-page veaction=edit (works for VE + preload on the first entry) and guard the transclusion with #ifexist so an empty Guestbook doesn't show a redlink |
m 1 revision imported |
(No difference)
| |
Revision as of 20:14, 12 September 2026
Be the first to share a memory.
Drop {{GuestbookWidget}} into any memorial page's
Guestbook section. It works on whichever page it's placed on — no page name to
fill in — by transcluding "<This page>/Guestbook" and linking to a
VisualEditor edit of that same subpage.
Important: do NOT pre-create the "PersonName/Guestbook" subpage. VisualEditor's preload only fires for a page that doesn't exist yet — if the subpage already exists (even blank), the first visitor loses the pre-filled form. The
above shows a friendly placeholder instead of a redlink until
the first memory is saved.
The first memory on a page opens pre-filled via preload. After that, the page already has content, so VisualEditor can no longer preload it automatically — later visitors use VisualEditor's Insert > Template > Memory dialog instead (TemplateData gives it labeled fields and a real photo picker).