Location: PHPKode > projects > Atom PhotoBlog > atomPhotoBlog.php
   Atom PhotoBlog - PHP5 based photo-blogger
   Copyright (C) 2007 by Sascha Tayefeh

   This program is free software; you can redistribute it and/or
   modify it under the terms of the GNU General Public License
   as published by the Free Software Foundation; either version 2
   of the License, or (at your option) any later version.

   This program is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   GNU General Public License for more details.

   You should have received a copy of the GNU General Public License
   along with this program; if not, write to the Free Software
   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.

/*! \brief Sample template main-page.

	This is the main-page of AtomPhotoBlog that serves as a starting-point
	for your own creativity. Please, carefully read the comments, so you
	can understand what they do and what you need to adapt in order to
	design this blog to your needs.

require_once './apbData/vars.php'; // All custom vars are stored here.
require_once './apbClasses/AtomPhotoBlog.class.php'; // The only class you need to stream as user.
// Create an instance of AtomPhotoBlog::
$blog = new AtomPhotoBlog($apbPara); // There MUST NOT be any html-code before this line!!!
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	 Prints all header elements. This is a container method, that calls following methods:

	 AtomPhotoBlog::printJavaScriptLink("./js/apb.js"); // Print a link to a java-script
	 AtomPhotoBlog::printTitle(); // Print header-<title> derived from blog-title
	 AtomPhotoBlog::printEncoding(); // Charset encoding
	 AtomPhotoBlog::printCss(); // The css-stylesheet (no argument, yet)
	 AtomPhotoBlog::printFeedsHeader();  // Atom/Rss feed-tag for the header. ALWAYS use this!

	 For fine-tuning, you can call this methods seperatly, since all of them are public.

	 <!-- Please, replace these keywords by your own favs -->
	 <meta name="keywords" content="PhotoBlog, Atom PhotoBlog, Script, PHP, PHP5,
	 PhotoBlogger, Fotoblog, Atom, RSS, Atom 1.0, Rss 2.0, Feed" />

	 <!-- Please, replace this description with your own description -->
	 <meta name="description" content="Atom PhotoBlog - The object-oriented, 
	 very fast PhotoBlogger Script." />


	 <!-- The main workarea. This is supposed to be replaced by a div of your own -->
	 <div id="workbench"> 

	 <!-- All non-image objects (=> all objects but the index/archive and the largeImage)
	 should be placed here.	-->
	 <div id="apbContainerUtils" class="apb container utils">

      Before calling the AtomPhotoBlog::printMenu(ASSOC_ARRAY), which creates a <div> and an <ul>
      for all menu items, we want to fill an assoc array with additionalm menu-items.
      Just use the key for the items' name, and the value for their link. Give the
      array as the only argument to the method AtomPhotoBlog::printMenu(ASSOC_ARRAY);
      "Atom 1.0" => "./blog/atom.xml",
      "Rss 2.0" => "./blog/rss.xml"
   </div> <!-- end container UTILS> -->

   <div id="apbContainerImage" class="apb container image">
	 This is the hardest working method of the class AtomPhotoBlog. It coordinates
	 all requests from/by the script/user/browser analysing GET/POST/SESSION-variables
	 and subsequently navigating to the single modules of the script (e.g. index, large image,
	 login, logout, comment, settings-form, upload-form etc...)
	 Always put this somewhere in the body.


   </div><!-- end container Image> -->

	  Print the taglist. The only bool argument, if TRUE, makes this method connect
	  and disconnect to the mysql-server. This is necessary, if you have not established
	  a mysql-connection before, e.g. in a case like this, where the method is called
	  from outside the object of AtomPhotoBlog. So, as a user, you MUST set this argument
	  to TRUE, since its default value is FALSE.

	   Print some links to CSS/HTML/ATOM/RSS-Validators.

</div> <!-- end div workbench -->
Return current item: Atom PhotoBlog