Skip to content

Commit

Permalink
Can't be that simple...?
Browse files Browse the repository at this point in the history
  • Loading branch information
causefx committed May 6, 2016
1 parent 43fd71c commit fe5c474
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
2 changes: 1 addition & 1 deletion js/tabs.min.js

Large diffs are not rendered by default.

20 changes: 13 additions & 7 deletions settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ function write_ini_file($content, $path) {
<body>

<form action="?action=write" method="post" name="adminForm" class="form-inline">
<?
<?php
foreach ($config as $keyname => $section) {
if(($keyname == "general")) {
echo "<div class=\"form-group clearfix\">";
Expand All @@ -161,25 +161,31 @@ function write_ini_file($content, $path) {

<div id="tagsForm" class="sortable">

<?$i = 0;
<?php
$i = 0;
foreach ($config as $keyname => $section) {

if(($keyname !== "general")) {?>
if(($keyname !== "general")) {
?>

<div class="form-group clearfix">
<span class="btn btn-default move" type="button"><span class="fa fa-arrows"></span></span>
<input type="text" name="category-<?=$i;?>" class="form-control" value="<?=$keyname;?>">
<input type="text" name="url-<?=$i;?>" class="form-control" placeholder="url" value="<?=$section['url']?>">
<button data-placement="left" data-cols="5" data-rows="5" class="btn btn-default" name="icon-<?=$i;?>" role="iconpicker" data-iconset="fontawesome" data-icon="<?=$section['icon']?>"></button>
<?if($section['enabled'] == "true"){echo '<input type="checkbox" name="enabled-' . $i .'" id="enabled-' . $keyname . '" class="css-checkbox" checked>';}else {echo '<input type="checkbox" name="enabled-' . $i .'" id="enabled-' . $keyname . '" class="css-checkbox">';}?>
<?php
if($section['enabled'] == "true"){echo '<input type="checkbox" name="enabled-' . $i .'" id="enabled-' . $keyname . '" class="css-checkbox" checked>';}else {echo '<input type="checkbox" name="enabled-' . $i .'" id="enabled-' . $keyname . '" class="css-checkbox">';}?>
<label for="enabled-<?=$keyname;?>" class="css-label">Enabled</label>
<?if($section['guest'] == "true"){echo '<input type="checkbox" name="guest-' . $i .'" id="guest-' . $keyname . '" class="css-checkbox" checked>';}else {echo '<input type="checkbox" name="guest-' . $i .'" id="guest-' . $keyname . '" class="css-checkbox">';}?>
<?php
if($section['guest'] == "true"){echo '<input type="checkbox" name="guest-' . $i .'" id="guest-' . $keyname . '" class="css-checkbox" checked>';}else {echo '<input type="checkbox" name="guest-' . $i .'" id="guest-' . $keyname . '" class="css-checkbox">';}?>
<label for="guest-<?=$keyname;?>" class="css-label">Guest</label> <button class="btn btn-danger deleteGroup" id="remScnt" type="button"><span class="fa fa-trash"></span></button>
</div>

<?}
<?php
}
$i++;
}?>
}
?>

</div>

Expand Down

0 comments on commit fe5c474

Please sign in to comment.