mirror of
https://github.com/processwire/processwire.git
synced 2025-08-11 01:04:16 +02:00
Remove site profiles: site-classic, site-default, site-beginner, site-languages, site-regular... leaving just site-blank. The other profiles have been moved to their own repos. Also some small updates to site-blank profile just so the template files are slightly more useful if someone doesn't install another.
This commit is contained in:
@@ -1 +0,0 @@
|
||||
This file is here to ensure Git adds the dir to the repo. You may delete this file.
|
6
site-blank/templates/_init.php
Normal file
6
site-blank/templates/_init.php
Normal file
@@ -0,0 +1,6 @@
|
||||
<?php namespace ProcessWire;
|
||||
|
||||
// Optional initialization file, called before rendering any template file.
|
||||
// This is defined by $config->appendTemplateFile in /site/config.php.
|
||||
// Use this to define shared variables, functions, classes, includes, etc.
|
||||
|
55
site-blank/templates/_main.php
Normal file
55
site-blank/templates/_main.php
Normal file
@@ -0,0 +1,55 @@
|
||||
<?php namespace ProcessWire;
|
||||
|
||||
// Optional main output file, called after rendering page’s template file.
|
||||
// This is defined by $config->appendTemplateFile in /site/config.php, and
|
||||
// is typically used to define and output markup common among most pages.
|
||||
//
|
||||
// When the Markup Regions feature is used, template files can prepend, append,
|
||||
// replace or delete any element defined here that has an "id" attribute.
|
||||
// https://processwire.com/docs/front-end/output/markup-regions/
|
||||
|
||||
/** @var Page $page */
|
||||
/** @var Pages $pages */
|
||||
/** @var Config $config */
|
||||
|
||||
$home = $pages->get('/'); // homepage
|
||||
|
||||
?><!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head id="html-head">
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<title><?php echo $page->title; ?></title>
|
||||
<link rel="stylesheet" type="text/css" href="<?php echo $config->urls->templates; ?>styles/main.css" />
|
||||
<script src="<?php echo $config->urls->templates; ?>scripts/main.js"></script>
|
||||
</head>
|
||||
<body id="html-body">
|
||||
|
||||
<p id="topnav">
|
||||
<?php echo $home->and($home->children)->implode(" / ", "<a href='{url}'>{title}</a>"); ?>
|
||||
</p>
|
||||
|
||||
<hr />
|
||||
|
||||
<h1 id="headline">
|
||||
<?php if($page->parents->count()): // breadcrumbs ?>
|
||||
<?php echo $page->parents->implode(" > ", "<a href='{url}'>{title}</a>"); ?> >
|
||||
<?php endif; ?>
|
||||
<?php echo $page->title; // headline ?>
|
||||
</h1>
|
||||
|
||||
<div id="content">
|
||||
Default content
|
||||
</div>
|
||||
|
||||
<?php if($page->hasChildren): ?>
|
||||
<ul>
|
||||
<?php echo $page->children->each("<li><a href='{url}'>{title}</a></li>"); // subnav ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if($page->editable()): ?>
|
||||
<p><a href='<?php echo $page->editUrl(); ?>'>Edit this page</a></p>
|
||||
<?php endif; ?>
|
||||
|
||||
</body>
|
||||
</html>
|
@@ -10,6 +10,8 @@
|
||||
* Feel free to hook admin-specific functionality from this file,
|
||||
* but remember to leave the require() statement below at the end.
|
||||
*
|
||||
* Note: this template file does not use the _init.php or _main.php
|
||||
*
|
||||
*/
|
||||
|
||||
/** @var Config $config */
|
||||
|
@@ -1,13 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<title><?php echo $page->title; ?></title>
|
||||
<link rel="stylesheet" type="text/css" href="<?php echo $config->urls->templates?>styles/main.css" />
|
||||
</head>
|
||||
<body>
|
||||
<h1><?php echo $page->title; ?></h1>
|
||||
<?php if($page->editable()) echo "<p><a href='$page->editURL'>Edit</a></p>"; ?>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
<?php namespace ProcessWire;
|
||||
|
||||
// Template file for pages using the “basic-page” template
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<div id="content">
|
||||
Basic page content
|
||||
</div>
|
||||
|
||||
|
@@ -1,3 +1,10 @@
|
||||
<?php
|
||||
<?php namespace ProcessWire;
|
||||
|
||||
include("./basic-page.php");
|
||||
// Template file for “home” template used by the homepage
|
||||
|
||||
?>
|
||||
|
||||
<div id="content">
|
||||
Homepage content
|
||||
</div>
|
||||
|
||||
|
@@ -1 +1 @@
|
||||
// Blank
|
||||
// Example JS file
|
||||
|
@@ -1 +1 @@
|
||||
/* blank */
|
||||
/* Example CSS file */
|
||||
|
Reference in New Issue
Block a user