[Scummvm-devel] [RFC] ScummVM website re-write

vEX vex at niechift.com
Sun Jun 29 14:04:36 CEST 2008


Max Horn wrote:
> Hi [vEX],
>
> thanks for putting all this work into a website rewrite. First time I
> hear about this ongoing work. I will take a closer look at it later. Two
> quick comments already now:
>
> #1: I disagree with the statement that using mod_rewrite is "not really
> necessary" -- to the contrary, I feel it is mandatory. Breaking all
> existing bookmarks to subpages of a site is IMO nothing that should be
> done lightly and without good reason.
>
> #2: I can't test your website code right now, this line in your
> index.php causes it to error out:
>  require_once(dirname(__FILE__) . '/include/config.inc');
> -> there is no config.inc in your tarball.
>
> Bye,
> Max
>
>

Hi Max,

Thanks for your reply. The reason to why it's so unknown is that I've only 
talked about it a bit on IRC.


#1: You have a point there, using mod_rewrite rules to be backwards compatible 
with the old links as well as allowing for the new style is certainly doable. So 
the question then is, do SourceForge support mod_rewrite? Otherwise I could make 
some "fake" PHP-files with the old filenames that just forward you to the new 
page. Though the mod_rewrite solution would be much nicer.


#2: I can't believe I managed to miss out the config.inc file in the tarball.

Get the updated tarball here 
http://web.telia.com/~u85920559/RFC-ScummVM_website_rewrite.tar.bz2 or paste the 
code below to 'include/config.inc'.



<?php

/* Current version */
$config['release'] = '0.11.1';
$config['release_tag'] = 'release-0-11-1';

/* News items on the front page */
$config['news_items'] = 4;

/* Base URL to the website */
$config['baseurl'] = "http://{$_SERVER['SERVER_NAME']}{$_SERVER['REQUEST_URI']}";

/* Paths */
$config['base_dir'] = '.';
/* These are calculated from the base_path */
$config['lib_dir'] = 'include';
$config['data_dir'] = 'data';
$config['docs_dir'] = 'docs';
$config['images_dir'] = 'images';
$config['media_dir'] = 'data/media';
$config['news_dir'] = 'data/news';
$config['compatibility_dir'] = 'data/compatibility';
$config['screenshots_dir'] = 'data/screenshots';
$config['downloads_dir'] = 'downloads';

/**
  * Smarty configuration. The Smarty team does not recommend putting any of the
  * directories used under the web server root. 'smarty_template_c_dir' and
  * 'smarty_cache_dir' must be writable by the web server.
  */
$config['smarty_dir'] = $config['lib_dir'] . '/smarty';
$config['smarty']['template_dir'] = 'templates';
$config['smarty']['compile_dir'] = $config['smarty_dir'] . '/template_c';
$config['smarty']['cache_dir'] = $config['smarty_dir'] . '/cache';
$config['smarty']['config_dir'] = $config['smarty_dir'] . '/config';
$config['smarty']['request_use_auto_globals'] = false;
/**
  * Smarty caching options, makes it possible to cache the generated HTML to
  * speed things up. More information is available at [1].
  *
  * [1] http://www.smarty.net/manual/en/caching.php
  */
$config['smarty']['caching'] = 0;
$config['smarty']['cache_lifetime'] = (60 * 60);
$config['smarty']['compile_check'] = true; /* used when developing */
$config['smarty']['force_recheck'] = true; /* used when developing */

/* These need to get handled too */
/**
  * FIXME: The templates don't have access to these atm since none of the
  *        *Page.php files gives access to them via global.
  *
$isOpera = strpos($_SERVER['HTTP_USER_AGENT'], 'Opera');
$isKHTML = strpos($_SERVER['HTTP_USER_AGENT'], 'KHTML');
  */
?>





More information about the Scummvm-devel mailing list