MyBB Community Forums

Full Version: Make a new page with same HTML and CSS
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
(2015-06-20, 04:27 AM).m. Wrote: [ -> ]you can use OUGC Pages plugin

Come on, stop using plugins for every little new thing you want to add. That's uneccessary.

OP, create a new file called NAME.php:

<?php 
define('IN_MYBB', 1); 

require "./global.php";
add_breadcrumb("NAME", "NAME.php"); 

	
eval("\$html = \"".$templates->get("NAME")."\";"); 
output_page($html);
?>

Go to AdminCP > Templates & Style > Templates > Add New Template and name it like the file above (just without .php):

<html>
<head>
<title>{$mybb->settings['bbname']} - NAME</title>
{$headerinclude}
</head>
<body>
{$header}

Your content here

{$footer}
</body>
</html>
Pages: 1 2