From Social Networking Software - Online Social Network Software
(Difference between revisions)
Jump to: navigation, search
(Theme Structure)
(Theme Structure)
Line 22: Line 22:
For a minimal theme you will require two files:
For a minimal theme you will require two files:
-
*text.htm - Which is responsible for basic layout of the homepage. E.g. banner and menu layout, footer layout and number of columns in between them.
+
*text.htm - Which is responsible for basic layout of the homepage. It determines where elements like banner, menu, footer and other elements of homepage will be placed and arranged which in turns makes clear structural layout of homepage.
-
*main_home.php - Which is responsible for layout of different components inside homepage. E.g. login form, signup form, welcome text and featured content.
+
*main_home.php - This file paints what will reside inside other elements of homepage like login form, signup form, welcome text and featured content.
So the homepage is rendered at two levels.
So the homepage is rendered at two levels.

Revision as of 06:45, 19 July 2011

Theme Development

Note: This is a technical document. It discusses technical aspects of theme module and developing a custom theme which requires a good knowledge of advanced PHP, HTML, CSS and Javascript and is not meant for non-technical users. Know more about themes: What are themes? | Using Themes.

Contents


Nature of themes

Themes are neither solid, liquid or gas. They are collection of PHP scripts, HTML/CSS files and images, living under themes folder at root with folder name same as theme name. For Example: Theme Demo will be at ROOT/themes/demo. Theme files are interlinked and hooked together to form the actual website.

Why develop themes

These are the reasons why should you learn theme development of Social Network Software.

  • Complete control over layout, presentation and various design elements.
  • Tweaking already existing themes according to your and your community taste.
  • When your requirements are too unique and specific to be found in our theme gallery.
  • Migrating from a non-Social-Network-Software powered website to a Social-Network-Software powered one.
  • You wish to frame out of box ideas inside Social Network Software.

Theme Structure

For a minimal theme you will require two files:

  • text.htm - Which is responsible for basic layout of the homepage. It determines where elements like banner, menu, footer and other elements of homepage will be placed and arranged which in turns makes clear structural layout of homepage.
  • main_home.php - This file paints what will reside inside other elements of homepage like login form, signup form, welcome text and featured content.

So the homepage is rendered at two levels.

First level structure

Which is controlled by text.htm.

File:First Level Structure.gif


Second level structure

Which is controlled by main_home.php.

File:Second Level Structure.gif

Main Page
About SNS
Developer Documentation
Personal tools