do not show default in scheme selection dropdown. default.php and default.css should be symlinks. adjust doco accordingly.

This commit is contained in:
Mario Vavti 2015-06-21 17:53:44 +02:00
parent e1caf77480
commit c1e0987b88
5 changed files with 8 additions and 3 deletions

View File

@ -30,6 +30,7 @@ If no personal options are set, and no schema is selected, we will first try to
with the file name "default.php". This file should never be included with a theme. If it with the file name "default.php". This file should never be included with a theme. If it
is, merge conflicts will occur as people update their code. Rather, this should be defined is, merge conflicts will occur as people update their code. Rather, this should be defined
by administrators on a site by site basis. by administrators on a site by site basis.
default.php and default.css MUST be symlinks to existing scheme files.
You schema does not need to - and should not - contain all of these values. Only the values You schema does not need to - and should not - contain all of these values. Only the values
that differ from the defaults should be listed. This gives you some very powerful options that differ from the defaults should be listed. This gives you some very powerful options

View File

@ -28,6 +28,7 @@ If no personal options are set, and no schema is selected, we will first try to
with the file name "default.php". This file should never be included with a theme. If it with the file name "default.php". This file should never be included with a theme. If it
is, merge conflicts will occur as people update their code. Rather, this should be defined is, merge conflicts will occur as people update their code. Rather, this should be defined
by administrators on a site by site basis. by administrators on a site by site basis.
default.php and default.css MUST be symlinks to existing scheme files.
You schema does not need to - and should not - contain all of these values. Only the values You schema does not need to - and should not - contain all of these values. Only the values
that differ from the defaults should be listed. This gives you some very powerful options that differ from the defaults should be listed. This gives you some very powerful options

View File

@ -84,8 +84,10 @@ function redbasic_form(&$a, $arr) {
if($files) { if($files) {
foreach($files as $file) { foreach($files as $file) {
$f = basename($file, ".php"); $f = basename($file, ".php");
$scheme_name = $f; if($f != 'default') {
$scheme_choices[$f] = $scheme_name; $scheme_name = $f;
$scheme_choices[$f] = $scheme_name;
}
} }
} }

View File

@ -70,6 +70,7 @@ if (($schema) && ($schema != '---')) {
// If we haven't got a schema, load the default. We shouldn't touch this - we // If we haven't got a schema, load the default. We shouldn't touch this - we
// should leave it for admins to define for themselves. // should leave it for admins to define for themselves.
// default.php and default.css MUST be symlinks to existing schema files.
if (! $schema) { if (! $schema) {
if(file_exists('view/theme/redbasic/schema/default.php')) { if(file_exists('view/theme/redbasic/schema/default.php')) {

View File

@ -1,4 +1,4 @@
<div id="photo-upload-form" class="generic-content-wrapper"> <div id="photo-upload-form">
<div class="section-content-tools-wrapper"> <div class="section-content-tools-wrapper">
<form action="photos/{{$nickname}}" enctype="multipart/form-data" method="post" name="photos-upload-form" id="photos-upload-form"> <form action="photos/{{$nickname}}" enctype="multipart/form-data" method="post" name="photos-upload-form" id="photos-upload-form">
<input type="hidden" id="photos-upload-source" name="source" value="photos" /> <input type="hidden" id="photos-upload-source" name="source" value="photos" />