Installing Adobe Experience Manager

To install an AEM instance for developing your website, follow the instructions for setting up a deployment environment with author and publish instances, or perform a generic installation. The generic installation involves downloading the AEM Quickstart JAR file, placing the license.properties file in the same directory as the JAR file, and double-clicking the JAR file.

After you have installed AEM, access the CRXDE Lite development environment by clicking the CRXDE Lite link on the Welcome page:

chlimage_1-25

NOTE
The URL of CRXDE Lite for an AEM authoring instance that is installed locally using the default port is https://localhost:4502/crx/de/.

Setting up the project structure in CRXDE Lite

Use CRXDE Lite to create the mywebsite application structure in the repository:

  1. In the tree on the left side of CRXDE Lite, right-click the /apps folder and click Create > Create Folder. In the Create Folder dialog, type mywebsite as the folder name and click OK.

  2. Right-click the /apps/mywebsite folder and click Create > Create Folder. In the Create Folder dialog, type components as the folder name and click OK.

  3. Right-click the /apps/mywebsite folder and click Create > Create Folder. In the Create Folder dialog, type templates as the folder name and click OK.

    The structure in the tree should now look something like this:

    chlimage_1-26

  4. Click Save All.

Setting up the Design

In this section, you create the design for your application using the Designer tool. The design provides CSS and image resources for your web site.

NOTE
Click the following link to download mywebsite.zip. The archive contains the static.css and image files for your design.

Sample static.css file and images

Get File

  1. On the AEM Welcome page, click Tools. (https://localhost:4502/libs/cq/core/content/welcome.html)

    chlimage_1-27

  2. In the folder tree, select the Designs folder and then click New > New Page. Type mywebsite as the title and click Create.

  3. If the mywebsite item does not appear in the table, refresh the tree or the table.

  4. Using WebDAV access to the URL at https://localhost:4502, copy the sample static.css file and images folder from the downloaded mywebsite.zip file into the /etc/designs/mywebsite folder.

    chlimage_1-28

Creating the Contentpage Template, Component and Script

In this section, you create the following:

  • The contentpage template that is used to create content pages in the example website.
  • The contentpage component that is used to render pages of content.
  • The contentpage script.

Creating the Contentpage Template

Create a template to use as the basis of the web pages of your site.

A template defines the default content of a new page. Complex websites may use several templates for creating the different types of pages in the site. In this exercise, all pages are based on one simple template.

  1. In the folder tree of CRXDE Lite, right-click /apps/mywebsite/templates and click Create > Create Template.

  2. In the Create Template dialog, type the following values and then click Next:

    • Label: contentpage
    • Title: My Website Content Page Template
    • Description: This is my Website Content Page Template
    • Resource Type: mywebsite/components/contentpage

    Use the default value for the Ranking property.

    chlimage_1-29

    The resource type identifies the component that renders the page. In this case, all pages created using the contentpage template are rendered by the mywebsite/components/contentpage component.

  3. To specify the paths of the pages that can use this template, click the plus button and type /content(/.*)? in the text box that appears. Then, click Next.

    chlimage_1-30

    The value of the allowed path property is a regular expression. Pages that have a path that matches the expression can use the template. In this is case, the regular expression matches the path of the /content folder and all subpages.

    When an author creates a page below /content, the contentpage template appears in a list of available templates to use.

  4. Click Next in the Allowed Parents and Allowed Children panels and click OK. In CRXDE Lite, click Save All.

    chlimage_1-31