Commits

Alain O'Dea  committed 07d1c05

Add examples skeleton site

The examples skeleton site will be used to document Zotonic through examples
of templates, tags, dispatch rules etc.

  • Participants
  • Parent commits bdfc9f8

Comments (0)

Files changed (10)

File priv/skel/examples/SITE.erl

+%% @author %%FULLNAME%%
+%% @copyright %%YEAR%% %%FULLNAME%%
+%% Generated on %%DATE%%
+%% @doc This site was based on the 'empty' skeleton.
+
+%% Licensed under the Apache License, Version 2.0 (the "License");
+%% you may not use this file except in compliance with the License.
+%% You may obtain a copy of the License at
+%% 
+%%     http://www.apache.org/licenses/LICENSE-2.0
+%% 
+%% Unless required by applicable law or agreed to in writing, software
+%% distributed under the License is distributed on an "AS IS" BASIS,
+%% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+%% See the License for the specific language governing permissions and
+%% limitations under the License.
+
+-module(%%SITE%%).
+-author("%%FULLNAME%%").
+
+-mod_title("%%SITE%% zotonic site").
+-mod_description("A Zotonic site full of example templates and dispatch rules to learn from.").
+-mod_prio(10).
+
+-include_lib("zotonic.hrl").
+
+
+%%====================================================================
+%% support functions go here
+%%====================================================================
+

File priv/skel/examples/config.in

+% Zotonic site configuration for %%SITE%%.
+[
+    % This site is enabled or not.
+    {enabled, true},
+
+    % Atomic hostname, MUST be equal to the directory name of this site.
+    {host, %%SITE%%},
+
+    % Hostname on which this site runs
+    {hostname, "%%SITE%%:8000"},
+
+    % Aliases which should redirect to the primary hostname
+    %{hostalias, "www.example.com"},
+    %{hostalias, "example.com"},
+
+    % PostgreSQL database connection
+    {dbhost, "%%DBHOST%%"},
+    {dbport, %%DBPORT%%},
+    {dbuser, "%%DBUSER%%"},
+    {dbpassword, "%%DBPASSWORD%%"},
+    {dbdatabase, "%%DBDATABASE%%"},
+    {dbschema, "%%DBSCHEMA%%"},
+
+    % Password for the 'admin' user.
+    {admin_password, "%%ADMINPASSWORD%%"},
+
+    % What skeleton site this site is based on; for installing the initial data.
+    {skeleton, %%SKEL%%}
+].

File priv/skel/examples/dispatch/dispatch

+%% Put your dispatch rules here.
+
+[
+%    {home,      [],	resource_template,  	[ {template, "home.tpl"} ]}
+].
+

File priv/skel/examples/files/archive/.empty

+

File priv/skel/examples/files/dropbox/.empty

+

File priv/skel/examples/files/preview/.empty

+

File priv/skel/examples/files/processing/.empty

+

File priv/skel/examples/files/unhandled/.empty

+

File priv/skel/examples/lib/css/.empty

Empty file added.

File priv/skel/examples/lib/images/.empty

Empty file added.