+ <#if article.author[0]??>
+ <#list article.author as author>
+ <#include "${author?replace('.xml', '-details.html')}" parse=false>
+ #list>
+ #if>
+
+ <#list article.page as page>
+ <#if page.page_title[0]??>
+
${page.page_title}
+ #if>
+ <#if page.page_picture[0]??>
+ <#if page.page_picture.image["@xsi:nil"] == "false">
+ <#if page_index % 2 == 1>
+
+

+ <#if page.page_picture.caption["@xsi:nil"] == "false">
+
${page.page_picture.caption}
+ #if>
+
+ <#else>
+
+

+ <#if page.page_picture.caption["@xsi:nil"] == "false">
+
${page.page_picture.caption}
+ #if>
+
+ #if>
+ #if>
+ #if>
+ ${page.page_body}
+ #list>
+
+ <#if article.include_legal_text == "true">
+ <#include "/legal.html" parse=false>
+ #if>
+
+
+
diff --git a/source/test-resources/xforms/examples/article/article-feature.ftl b/source/test-resources/xforms/examples/article/article-feature.ftl
new file mode 100644
index 0000000000..322da242e9
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/article-feature.ftl
@@ -0,0 +1,89 @@
+<#ftl ns_prefixes={"D":"http://www.alfresco.org/alfresco/article","xsi":"http://www.w3.org/2001/XMLSchema-instance"}>
+
+
+
+
+ ${article.title}
+
+
+
+ <#if article.author[0]??>
+ <#list article.author as author>
+ <#include "${author?replace('.xml', '-details.html')}" parse=false>
+ #list>
+ #if>
+
+
+
+ ${article.location} ${article.date} - ${article.teaser}
+
+
diff --git a/source/test-resources/xforms/examples/article/article-list.xsl b/source/test-resources/xforms/examples/article/article-list.xsl
new file mode 100644
index 0000000000..5613760d0f
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/article-list.xsl
@@ -0,0 +1,53 @@
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+ /content/article/
+
+
+ |
+
+
+
+
diff --git a/source/test-resources/xforms/examples/article/article-pdf.xsl b/source/test-resources/xforms/examples/article/article-pdf.xsl
new file mode 100644
index 0000000000..0708591e21
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/article-pdf.xsl
@@ -0,0 +1,120 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ —
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/source/test-resources/xforms/examples/article/article.xsd b/source/test-resources/xforms/examples/article/article.xsd
new file mode 100644
index 0000000000..467fc07f99
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/article.xsd
@@ -0,0 +1,467 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Alabama
+
+
+
+
+ Alaska
+
+
+
+
+ Arizona
+
+
+
+
+ Arkansas
+
+
+
+
+ California
+
+
+
+
+ Colorado
+
+
+
+
+ Connecticut
+
+
+
+
+ District of Columbia
+
+
+
+
+ Delaware
+
+
+
+
+ Florida
+
+
+
+
+ Georgia
+
+
+
+
+ Hawaii
+
+
+
+
+ Idaho
+
+
+
+
+ Illinois
+
+
+
+
+ Indiana
+
+
+
+
+ Iowa
+
+
+
+
+ Kansas
+
+
+
+
+ Kentucky
+
+
+
+
+ Louisiana
+
+
+
+
+ Maine
+
+
+
+
+ Maryland
+
+
+
+
+ Massachusetts
+
+
+
+
+ Michigan
+
+
+
+
+ Minnesota
+
+
+
+
+ Mississippi
+
+
+
+
+ Missouri
+
+
+
+
+ Montana
+
+
+
+
+ Nebraska
+
+
+
+
+ Nevada
+
+
+
+
+ New Hampshire
+
+
+
+
+ New Jersey
+
+
+
+
+ New Mexico
+
+
+
+
+ New York
+
+
+
+
+ North Carolina
+
+
+
+
+ North Dakota
+
+
+
+
+ Ohio
+
+
+
+
+ Oklahoma
+
+
+
+
+ Oregon
+
+
+
+
+ Pennsylvania
+
+
+
+
+ Rhode Island
+
+
+
+
+ South Carolina
+
+
+
+
+ South Dakota
+
+
+
+
+ Tennessee
+
+
+
+
+ Texas
+
+
+
+
+ Utah
+
+
+
+
+ Vermont
+
+
+
+
+ Virginia
+
+
+
+
+ Washington
+
+
+
+
+ West Virginia
+
+
+
+
+ Wisconsin
+
+
+
+
+ Wyoming
+
+
+
+
+
+
+
+
+
+
+
+ default
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ The value entered is not a valid zip code.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ The value entered is not a valid email address.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ image_file_picker
+
+
+
+
+
+
+
+
+
+
+
+
+
+ full
+
+
+
+
+
+
+
+
+
+
+
+
+
+ search_restricted_file_picker
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ full
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/source/test-resources/xforms/examples/article/article.xsl b/source/test-resources/xforms/examples/article/article.xsl
new file mode 100644
index 0000000000..60e067da27
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/article.xsl
@@ -0,0 +1,136 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ |
+
+
+ /content/article/
+
+
+ |
+
+
+
+
+ ,
+
+ |
+
+
+
+
+
+
+
+
+
+
+ left
+
+
+
+
+
+ |
+
+
+
+
+
+
+
+
+
+
+
+ left
+
+
+ right
+
+
+
+
+
+
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+
+
+
+ —
+
+
+
+
+ |
+
+
+
+
+
+
diff --git a/source/test-resources/xforms/examples/article/news-flash-details.ftl b/source/test-resources/xforms/examples/article/news-flash-details.ftl
new file mode 100644
index 0000000000..201e4785b4
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/news-flash-details.ftl
@@ -0,0 +1,44 @@
+<#ftl ns_prefixes={"D":"http://www.alfresco.org/alfresco/article","xsi":"http://www.w3.org/2001/XMLSchema-instance"}>
+
+
+
+
+ ${news_flash.title}
+
+
+
+
+ ${news_flash.location} ${news_flash.date} - ${news_flash.body}
+
+
+
+
+
diff --git a/source/test-resources/xforms/examples/article/user-profile-details-pdf.ftl b/source/test-resources/xforms/examples/article/user-profile-details-pdf.ftl
new file mode 100644
index 0000000000..0dc121157c
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/user-profile-details-pdf.ftl
@@ -0,0 +1,36 @@
+<#ftl ns_prefixes={"D":"http://www.alfresco.org/alfresco/article","xsi":"http://www.w3.org/2001/XMLSchema-instance","alf":"http://www.alfresco.org"}>
+
+
+
+ <#if user_profile[0]??>
+ <#if user_profile.picture[0]??>
+
+
+ |
+ #if>
+
+
+ ${user_profile.name.prefix}. ${user_profile.name.first} ${user_profile.name.last}
+
+
+ ${user_profile.bio}
+
+
+ <#if user_profile.address[0]??>
+ Address:
+ <#list user_profile.address.street as street>
+ ${street}
+ #list>
+ ${user_profile.address.city}, ${user_profile.address.state} ${user_profile.address.zip}
+ #if>
+
+
+ <#if user_profile.email[0]??>
+ Email: ${user_profile.email}
+ #if>
+
+ |
+ #if>
+
+
+
diff --git a/source/test-resources/xforms/examples/article/user-profile-details.ftl b/source/test-resources/xforms/examples/article/user-profile-details.ftl
new file mode 100644
index 0000000000..9862290087
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/user-profile-details.ftl
@@ -0,0 +1,50 @@
+<#ftl ns_prefixes={"D":"http://www.alfresco.org/alfresco/article","xsi":"http://www.w3.org/2001/XMLSchema-instance"}>
+
+
+
+ <#if user_profile[0]??>
+ <#if user_profile.picture[0]??>
+

+ #if>
+
+ ${user_profile.name.prefix}. ${user_profile.name.first} ${user_profile.name.last}
+
+
+ ${user_profile.bio}
+
+
+ <#if user_profile.address[0]??>
+ Address:
+ <#list user_profile.address.street as street>
+ ${street}
+ #list>
+ ${user_profile.address.city}, ${user_profile.address.state} ${user_profile.address.zip}
+ #if>
+
+
+ <#if user_profile.email[0]??>
+ Email: ${user_profile.email}
+ #if>
+
+ #if>
+
+
diff --git a/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.desc.xml b/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.desc.xml
new file mode 100644
index 0000000000..8781e2ddb9
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.desc.xml
@@ -0,0 +1,8 @@
+
+ WCM Schema for Category Selection
+ Generate part of schema for category selection
+
+ extension
+ user
+ required
+
\ No newline at end of file
diff --git a/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.html.ftl b/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.html.ftl
new file mode 100644
index 0000000000..f24daa986b
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.html.ftl
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+ Press Release
+
+
+
+
+
+
+ Whitepaper
+
+
+
+
+
+
+
diff --git a/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.js b/source/test-resources/xforms/examples/article/webscripts/CategorySelection.get.js
new file mode 100644
index 0000000000..e69de29bb2
diff --git a/source/test-resources/xforms/examples/article/webscripts/ContentList.get.desc.xml b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.desc.xml
new file mode 100644
index 0000000000..f5c18cf607
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.desc.xml
@@ -0,0 +1,8 @@
+
+ WCM Schema for Content Selection
+ Generate part of schema for content selection
+
+ extension
+ user
+ required
+
\ No newline at end of file
diff --git a/source/test-resources/xforms/examples/article/webscripts/ContentList.get.html.ftl b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.html.ftl
new file mode 100644
index 0000000000..e998f6d0ea
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.html.ftl
@@ -0,0 +1,25 @@
+
+<#if results??>
+
+
+
+ <#list results as result>
+ <#if ! result.hasAspect("{http://www.alfresco.org/model/wcmappmodel/1.0}rendition")>
+
+
+
+ ${result.name?substring(0,result.name?index_of(".xml"))}
+
+
+
+ #if>
+ #list>
+
+
+
+ #if>
+
diff --git a/source/test-resources/xforms/examples/article/webscripts/ContentList.get.js b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.js
new file mode 100644
index 0000000000..743e886dff
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.js
@@ -0,0 +1,70 @@
+var contentList = null;
+
+if (args["storeid"] == null) {
+
+ logger.log("ERROR: 'store' argument not specified.");
+
+} else {
+
+ // Get the store id
+ var storeId = args["storeid"];
+
+ var store = avm.lookupStore(storeId);
+
+ if ( store != null ) {
+
+ // Get the form name
+ var formName = args["form"];
+
+ if ( formName != null ) {
+
+
+ var method = (args.method == null) ? "lucene" : args.method;
+
+ if ( method == "lucene" ) {
+
+ // Run the lucene query
+ var results = store.luceneSearch('@\\{http\\://www.alfresco.org/model/wcmappmodel/1.0\\}parentformname:"'+formName+'"');
+
+ contentList = results;
+
+ } else {
+
+ var path = (args.path == null) ? "/ROOT" : args.path;
+
+ var storeRootNode = avm.lookupStoreRoot(storeId);
+
+ // try xpath???
+
+ var results = avm.lookupNode(storeRootNode.path + path);
+
+ var contentList = new Array();
+
+ if ( results.children != null ) {
+
+ for ( var i = 0 ; i < results.children.length ; i ++ ) {
+
+ var item = results.children[i];
+
+ if ( item.properties["{http://www.alfresco.org/model/wcmappmodel/1.0}parentformname"] == formName ) {
+
+ contentList.push(item);
+
+ }
+
+ }
+
+ }
+
+ }
+
+ }
+
+ } else {
+
+
+ }
+
+}
+
+model.results= contentList;
\ No newline at end of file
diff --git a/source/test-resources/xforms/examples/article/webscripts/ContentList.get.xml.ftl b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.xml.ftl
new file mode 100644
index 0000000000..e998f6d0ea
--- /dev/null
+++ b/source/test-resources/xforms/examples/article/webscripts/ContentList.get.xml.ftl
@@ -0,0 +1,25 @@
+
+<#if results??>
+
+
+
+ <#list results as result>
+ <#if ! result.hasAspect("{http://www.alfresco.org/model/wcmappmodel/1.0}rendition")>
+
+
+
+ ${result.name?substring(0,result.name?index_of(".xml"))}
+
+
+
+ #if>
+ #list>
+
+
+
+ #if>
+
diff --git a/source/test-resources/xforms/examples/getting-started-sample/Product-Evaluation-Guide.pdf b/source/test-resources/xforms/examples/getting-started-sample/Product-Evaluation-Guide.pdf
new file mode 100644
index 0000000000..60c46ac589
Binary files /dev/null and b/source/test-resources/xforms/examples/getting-started-sample/Product-Evaluation-Guide.pdf differ
diff --git a/source/test-resources/xforms/examples/getting-started-sample/alfresco-sample-website.war b/source/test-resources/xforms/examples/getting-started-sample/alfresco-sample-website.war
new file mode 100644
index 0000000000..416c8560cb
Binary files /dev/null and b/source/test-resources/xforms/examples/getting-started-sample/alfresco-sample-website.war differ
diff --git a/source/test-resources/xforms/examples/getting-started-sample/company-footer.xsd b/source/test-resources/xforms/examples/getting-started-sample/company-footer.xsd
new file mode 100644
index 0000000000..cadbaa709c
--- /dev/null
+++ b/source/test-resources/xforms/examples/getting-started-sample/company-footer.xsd
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/source/test-resources/xforms/demos/press-release/press-release-plain-text.ftl b/source/test-resources/xforms/examples/getting-started-sample/press-release-plain-text.ftl
similarity index 100%
rename from source/test-resources/xforms/demos/press-release/press-release-plain-text.ftl
rename to source/test-resources/xforms/examples/getting-started-sample/press-release-plain-text.ftl
diff --git a/source/test-resources/xforms/demos/press-release/press-release.xml b/source/test-resources/xforms/examples/getting-started-sample/press-release.xml
similarity index 100%
rename from source/test-resources/xforms/demos/press-release/press-release.xml
rename to source/test-resources/xforms/examples/getting-started-sample/press-release.xml
diff --git a/source/test-resources/xforms/demos/press-release/press-release.xsd b/source/test-resources/xforms/examples/getting-started-sample/press-release.xsd
similarity index 61%
rename from source/test-resources/xforms/demos/press-release/press-release.xsd
rename to source/test-resources/xforms/examples/getting-started-sample/press-release.xsd
index e4b6af7e33..fb3fb74d07 100644
--- a/source/test-resources/xforms/demos/press-release/press-release.xsd
+++ b/source/test-resources/xforms/examples/getting-started-sample/press-release.xsd
@@ -1,19 +1,27 @@
diff --git a/source/test-resources/xforms/demos/press-release/press-release.xsl b/source/test-resources/xforms/examples/getting-started-sample/press-release.xsl
similarity index 81%
rename from source/test-resources/xforms/demos/press-release/press-release.xsl
rename to source/test-resources/xforms/examples/getting-started-sample/press-release.xsl
index b836e5c8b5..9220246d4f 100644
--- a/source/test-resources/xforms/demos/press-release/press-release.xsl
+++ b/source/test-resources/xforms/examples/getting-started-sample/press-release.xsl
@@ -1,19 +1,27 @@
+
+[#list avm.stores as store]
+ ${store.name}
+[/#list]
+
+
+
+