Add a new page to Alfresco Share with link in Share Header | Code Factory

Reference Link : Link

Following steps are needed to add a Surf Page:

  • Add a Surf Page definition file (XML)
  • Add a Template Instance file (XML)
  • Add a physical Template file (FTL)
  • Add a properties file (.properties) — Optional but good practice
  • Add Web Script(s) that fetches content to display (if you have page scoped regions and use an existing template)

File : ( )

<?xml version='1.0' encoding='UTF-8'?>
<title>Hello World Home</title>
<description>Hello World Home Description</description>

File : ( )

<?xml version='1.0' encoding='UTF-8'?>

File : ( )

This is just a test page. Hello World!

File : ( )

page.helloworldhome.title=Hello World 
page.helloworldhome.description=Hello World Home Description

File : Rename the to ( )
Then define the following bean:

<bean id="org.alfresco.demo.resources" class="">
<property name="resourceBundles">

Note : After completing these steps Restart Server… and go

To add share header and footer modify file : ( )

<#include "/org/alfresco/include/alfresco-template.ftl" />
<@markup id="alf-hd">
<div id="alf-hd">
<@region scope="global" id="share-header" chromeless="true"/>
<@markup id="bd">
<div id="bd">
This is just a test page. Hello World!</h1>
<@markup id="alf-ft">
<div id="alf-ft">
<@region id="footer" scope="global" />

Link this page (helloworldhome) in share header
File : ( )
Go to at function and add this code.

name: "alfresco/menus/AlfMenuBarItem",
config: {
label: "My Menu",
targetUrl: "helloworldhome"