<?php

define('RENDER_MODE', 'catalyz');
ob_start();

use_helper('Form');

use_stylesheet('catalyz/smoothness/jquery-ui-1.7.custom.css');
use_javascript('catalyz/jquery-1.3.2.min.js');
use_javascript('catalyz/jquery-ui-1.7.custom.min.js');

use_stylesheet('catalyz/catalyz.css');
if (sfConfig::get('app_catalyz_customize_css')) {
    use_stylesheet('catalyz-content.css');
}

?>

<h1><?php echo __('Page Not Found', array(), 'catalyz') ?></h1>
<p><?php echo __('The server returned a 404 response.', array(), 'catalyz') ?></p>

<ul>
	<li>
		<b><?php echo __('Did you type the URL?', array(), 'catalyz') ?></b>
		<p style="margin-top: 5px"><?php echo __('You may have typed the address (URL) incorrectly. Check it to make sure you\'ve got the exact right spelling, capitalization, etc.', array(), 'catalyz') ?></p>
	</li>
	<li>
		<b><?php echo __('Did you follow a link from somewhere else at this site?', array(), 'catalyz') ?></b>
		<p style="margin-top: 5px"><?php echo __('If you reached this page from another part of this site, please email us at %email% so we can correct our mistake.', array('%email%' => mail_to('support@waterproof.fr', 'support@waterproof.fr', array('encode' => true))), 'catalyz') ?></p>
	</li>
	<li>
		<b><?php echo __('Did you follow a link from another site?', array(), 'catalyz') ?></b>
		<p style="margin-top: 5px"><?php echo __('Links from other sites can sometimes be outdated or misspelled. Email us at %email% where you came from and we can try to contact the other site in order to fix the problem.', array('%email%' => mail_to('support@waterproof.fr', 'support@waterproof.fr', array('encode' => true))), 'catalyz') ?></p>
	</li>
	<li>
		<b><?php echo __('What\'s next', array(), 'catalyz') ?></b>
		<p style="margin-top: 5px"><a href="javascript:history.go(-1)"><?php echo __('Back to previous page', array(), 'catalyz') ?></a> <?php echo __('or', array(), 'catalyz') ?> <a href="<?php echo $ContentTree->getRoot()->getUrl() ?>"><?php echo __('go to the homepage', array(), 'catalyz') ?></a></p>
	</li>
</ul>

<?php

$content = ob_get_contents();

ob_end_clean();

use_helper('Catalyz');
$layout = LayoutManager::instance()->getCatalyzTemplate($ContentTree->getCurrentNode()->getCurrentLayoutNameForAction());
$properties['layout_family'] = $layout[0];
$properties['layout_name'] = $layout[1];
$properties['ContentTree'] = $ContentTree;
$properties['page'] = $ContentTree->getCurrentNode()->getPage();

embed_with_layout($content, $layout, $properties);

?>