Because we are running the new beta software here, I wanted to restore the Download link we had in previous versions.
This is just a version update. XMB 1.10 uses file-based templates, so I've included our separate templates/download.php file as an example.
In the original download.php file for the root directory, the coding style has changed quite a bit. I've illustrated the use of a custom
namespace, meaning none of the XMB variables or functions are directly accessible. In fact, this version of XMB doesn't expose any variables in
the global namespace.
Two of the XMB shared services, core and template, are retrieved into custom global variables that I named $core and $template for simplicity. All of the logic that we need for the simple
custom page is found in the methods of those two services. When we want to use a template file, we call
Code:
$template->process('filename.php');
We use two methods from the core service to display a navigation breadcrumb and to calculate the page footer statistics.