blob: bcbbed26d29c9f68cff4cfe8dd52aef2db9e7989 [file] [log] [blame]
<?php
/*******************************************************************************
* Copyright (c) 2014 Eclipse Foundation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://eclipse.org/legal/epl-v10.html
*
* Contributors:
* Christopher Guindon (Eclipse Foundation) - Initial implementation
*******************************************************************************/
require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/app.class.php");
require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/nav.class.php");
require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/menu.class.php");
$App = new App();
$Nav = new Nav();
$Menu = new Menu();
include("_projectCommon.php"); # All on the same line to unclutter the user's desktop.
// Homepage specific requirements.
require_once ($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/classes/parser/feedparser.class.php");
require_once ($_SERVER['DOCUMENT_ROOT'] . "/membership/promo/promos.php");
// Begin: page-specific settings. Change these.
$pageTitle = "Eclipse - The Eclipse Foundation open source community website.";
$pageKeywords = "eclipse,project,plug-ins,plugins,java,ide,swt,refactoring,free java ide,tools,platform,open source,development environment,development,ide";
$pageAuthor = "Eclipse Foundation, Inc.";
$ad_number = null;
if(isset($_GET['adNo'])) {
$ad_number = $_GET['adNo'];
}
$promo = chooseRandomPromo($ad_number, TRUE);
// Home-well classes
$home_well_classes = 'b1';
$banner = (isset($_GET['banner'])) ? $_GET['banner'] : 0 ;
if ($banner == 2) {
$home_well_classes = 'b2';
}
elseif ($banner == 3) {
$home_well_classes = 'b3';
}
elseif ($banner == 4) {
$home_well_classes = 'b4';
}
// Place your html content in a file called content/en_pagename.php
ob_start();
include("content/en_" . $App->getScriptName());
$html = ob_get_clean();
// Custom theme variables
$variables = array();
$variables['hide_breadcrumbs'] = TRUE;
$variables['main_container_classes'] = 'container-full';
$App->setThemeVariables($variables);
# Generate the web page
// Date in the past
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// always modified
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
// HTTP/1.1
header("cache-Control: no-store, no-cache, must-revalidate");
header("cache-Control: post-check=0, pre-check=0", false);
// HTTP/1.0
header("Pragma: no-cache");
$App->PageRSS = "//feeds.feedburner.com/eclipse/fnews";
$App->PageRSSTitle = "Eclipse Foundation News";
//$html = mb_convert_encoding($html, "HTML-ENTITIES", 'auto');
$App->generatePage($theme, $Menu, NULL, $pageAuthor, $pageKeywords, $pageTitle, $html);
?>