Form Page web part
All editionsThe Modern DFFS Formpage web part shows a DFFS form on a modern site page instead of in the list. Use it when you want a link that goes straight to a form — a Submit a request link on the intranet front page, or a link in an email that opens one specific item for viewing or editing.
The page reads which list, which form and which item to show from the URL, so one page can host the forms of every DFFS-enabled list in the site.
It only opens through a link. Opening an item from the list view still shows the form the normal way. The web part shows a form only when someone follows a link built in the format described below.
1. Before you start
- The page and the list must be in the same site. The web part looks the list up in the site the page belongs to, and reads the form configuration from that site’s
DFFSConfigurationList. - The list needs a DFFS configuration for each form you link to — New, Display and/or Edit.
- Nothing extra to install. The web part is part of the Modern DFFS package, so it is available on every site where Modern DFFS is added.
2. Add the web part to a page
- Open Site contents → Site Pages and create a new site page, or edit an existing one. A page that does nothing else works best. A one-column section gives the form the full width.
- Click + to add a web part, search for Modern DFFS Formpage (it is in the Other group), and add it.
- Publish the page.
When the page is opened without the URL parameters, the web part shows a placeholder that lists the parameters and gives an example URL that creates a new item, built from the page’s own address. That is the quickest way to get the base URL to work from.
While a form is showing, the web part hides the page’s command bar and removes the section padding so the form fills the page.
3. URL parameters
| Parameter | Required | Value |
|---|---|---|
DFFSList | Yes | The GUID of the list. |
DFFSForm | Yes | new, disp or edit — lower case, exactly as written. |
DFFSID | For disp and edit | The ID of the list item to open. Leave it out for new. |
DFFSContentType | No | New form only, on a list with several content types: the content type to create, by display name or ID. |
DFFSSource | No | Where to send the user after the form is saved or cancelled. See where the user goes next. |
Finding the list GUID
Open the list, then Settings → List settings. The browser address ends in List=%7B…%7D. The GUID is the part between %7B and %7D (those are the encoded curly braces). Use it without the braces.
Example links
Assuming the page is /sites/HR/SitePages/DFFSForm.aspx:
New item:
https://contoso.sharepoint.com/sites/HR/SitePages/DFFSForm.aspx?DFFSList=0b6f2a1e-4c1d-4d9b-9a0e-2f7c3e5b8a11&DFFSForm=new
View item 42:
https://contoso.sharepoint.com/sites/HR/SitePages/DFFSForm.aspx?DFFSList=0b6f2a1e-4c1d-4d9b-9a0e-2f7c3e5b8a11&DFFSForm=disp&DFFSID=42
Edit item 42, then return to the site's front page:
https://contoso.sharepoint.com/sites/HR/SitePages/DFFSForm.aspx?DFFSList=0b6f2a1e-4c1d-4d9b-9a0e-2f7c3e5b8a11&DFFSForm=edit&DFFSID=42&DFFSSource=/sites/HR
New item with a specific content type:
https://contoso.sharepoint.com/sites/HR/SitePages/DFFSForm.aspx?DFFSList=0b6f2a1e-4c1d-4d9b-9a0e-2f7c3e5b8a11&DFFSForm=new&DFFSContentType=Leave%20request
If the DFFSSource address has a query string of its own, URL-encode it. Otherwise its & parameters are read as part of the form page’s URL.
4. Where the user goes next
A form page has no panel to close, so after Save or Cancel the user is sent to another page.
After Save
- If the form’s Custom JS defines
dffs_PostSaveAction, your function is responsible for navigation and DFFS does not redirect. Returnfalsefrom it to let DFFS continue with the steps below. - If the user chose Save and open in edit mode, the saved item opens in the edit form on the same page.
- Otherwise the user goes to
DFFSSourceif it is set, or to the list if it is not.
After Cancel
The user goes to the Source parameter if it is in the URL, then DFFSSource, then the list.
Use
DFFSSource, notSource.DFFSSourceis used after both Save and Cancel, anddffs_PostSaveActioncan still override it. SharePoint’s ownSourceparameter is used only after Cancel.
In this example, dffs_PostSaveAction overrides the redirect for one case and leaves the rest to DFFSSource:
window.dffs_PostSaveAction = function () {
if (getFieldValue("Status") === "Submitted") {
location.href = "/sites/HR/SitePages/Thank-you.aspx";
return;
}
return false; // let DFFS redirect to DFFSSource (or the list)
};
5. From display to edit
Clicking Edit on a display form opens the edit form for the same item, on the same page. The page doesn’t reload, and the address in the browser still shows the original link.
6. Links created from the form page
When a form is open in the web part, links to the item point to the form page rather than to the list:
- The form’s Copy link button copies a form page URL with
DFFSList,DFFSIDandDFFSFormfor the form that is open. - The current item tokens
[[item:link]],[[item:link_disp]]and[[item:link_edit]]resolve to form page URLs too. An email sent by a rule on a form submitted from the form page links back to the form page.
These links don’t include DFFSSource. Add it yourself if the user should land somewhere specific afterwards.
7. Troubleshooting
If the page shows “Ensure you have the correct URL query string parameters set”, check:
DFFSListis the GUID of a list in the same site as the page, and the user has access to that list.DFFSFormis present and is exactlynew,disporedit.- The site has a
DFFSConfigurationListthe user can read. If not, the browser console says so: “DFFS: the list ‘DFFSConfigurationList’ was not found in this site, or you do not have permission to read it.”
If the page shows the placeholder with the parameter list instead of a form, DFFSList is missing from the URL.