Skip to main content Skip to navigation

Step 4: Create a What's New page

Finally, we'll create a What's new page so we can see when students update their pages. This is a simple extension of creating a page for each student, but with the special Sitebuilder HTML passed to the atom client and extra properties to tell Sitebuilder the page type.

// finally, create a "What's new" page
String pageUrl = atomClient.createPage("whatsnew", "<html><body><!-- SITEBUILDER_MERGE_DYNAMIC_STATIC --></body></html>");
editPageProperties(pageUrl, {
	// the page to edit
	page: pageUrl,
	// tell Sitebuilder that we're saving the page
	_submit: "submit",

	// set the page heading, title bar caption and link caption to
	// "What's new"
	title: "What's new?",
	shortTitle: "What's new?",
	linkTitle: "What's new?",

	// set a description
	description: "Recent changes in contributed module content for ${moduleCode}",

	// add keywords to the page
	keywords: "user contributed content, whats new, ${moduleCode}",

	// make sure the sort order is greater than all the profiles
	pageOrder: "100",
	
	// change the page type to a What's New page
	contentType: "SiteChangesPageTransformation"
});