Example #1
0
						    <input type="file" name="bg_file" id="bg_file"  />
					      </div>
						  
						  <div class="form-group">
							  <label for="text">Vertical Image:</label>
						    <input type="file" name="file" id="file"  />
					      </div>
  						
						
						<div class="form-group">
						  <label for="text">Category:</label>
					       <select class="selectpicker" id="cat_id" name="cat_id" data-style="btn-primary">

  							<?php 
$p = new Projects('member', BASE_DOMAIN);
$cats = $p->get_categories();
for ($x = 0; $x < count($cats); $x++) {
    $cats_name = $cats[$x]['name'];
    $cats_uid = $cats[$x]['id'];
    ?>

    
  							       <option value="<?php 
    echo $cats_uid;
    ?>
"><?php 
    echo $cats_name;
    ?>
</option>

  								<?php 
Example #2
0
                <th>Category Name</th>
				 <th>Slug</th>
                <th>Icon</th>
				<th>Delete</th>
            </tr>
        </thead>
		
	    <tbody>
	         

	<?php 
require_once "../config.inc.php";
$db = Database::obtain(DB_SERVER, DB_USER, DB_PASS, DB_DATABASE);
$db->connect();
$r = new Projects('unknown', BASE_DOMAIN);
$categories = $r->get_categories();
//print_r($projects);
for ($i = 0; $i < count($categories); $i++) {
    $id = $categories[$i]['id'];
    $name = $categories[$i]['name'];
    $icon = $categories[$i]['icon'];
    $slug = $categories[$i]['slug'];
    echo "<tr id=\"cat_" . $id . "\">";
    // next field client_id
    //not editable
    echo "<td>";
    echo $id;
    echo "</td>";
    //next field name
    echo "<td>";
    echo "<style>\n                 #name_" . $id . ":hover { background: #fffbe1; }\n             </style>";