Skip to content
This repository has been archived by the owner on Apr 18, 2020. It is now read-only.

Commit

Permalink
Multiple files from the same theme can now be loaded with `theme_file…
Browse files Browse the repository at this point in the history
…s=more,files`.
  • Loading branch information
nirix committed Apr 24, 2013
1 parent 17e3d19 commit 9f97fc2
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions css.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,16 @@
}
}

// Theme css files
// Set `theme_files` to `default` if it's
// not set in the URI.
if (!isset($_REQUEST['theme_files'])) {
$_REQUEST['theme_files'] = 'default';
}

// Theme CSS files
if (isset($_REQUEST['theme'])) {
$theme = htmlspecialchars($_REQUEST['theme']);
foreach (explode(',', $_REQUEST['theme']) as $file) {
foreach (explode(',', $_REQUEST['theme_files']) as $file) {
// Check if the file exists...
if (file_exists(__DIR__ . "/vendor/traq/views/{$theme}/css/{$file}.css")) {
// Add it to the output array.
Expand Down

0 comments on commit 9f97fc2

Please sign in to comment.