<thead> <tr> <th>#</th> <th >Name</th> <th width="50%">Comment</th> <th>Action</th> </tr> </thead> <tbody> <?php if ($reviews != null) { $ind = 1; foreach ($reviews as $review) { $extras = new Extras(); $deleteUrl = $extras->encryptQuery2(KEY_SALT, 'review_id', $review->store_id, 'photo_id', $review->review_id, 'store_reviews_view.php'); $user = $controllerUser->getUserByUserId($review->user_id); echo "<tr>"; echo "<td>{$ind}</td>"; echo "<td>{$user->full_name}</td>"; echo "<td>{$review->review}</td>"; echo "<td>\n <button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#modal_{$review->review_id}'><span class='glyphicon glyphicon-remove'></span></button>\n \n </td>"; echo "</tr>"; //<!-- Modal --> echo "<div class='modal fade' id='modal_{$review->review_id}' tabindex='-1' role='dialog' aria-labelledby='myModalLabel' aria-hidden='true'>\n\n <div class='modal-dialog'>\n <div class='modal-content'>\n <div class='modal-header'>\n <button type='button' class='close' data-dismiss='modal' aria-hidden='true'>×</button>\n <h4 class='modal-title' id='myModalLabel'>Deleting Review</h4>\n </div>\n <div class='modal-body'>\n <p>Deleting this is not irreversible. Do you wish to continue?\n </div>\n <div class='modal-footer'>\n <button type='button' class='btn btn-default' data-dismiss='modal'>Close</button>\n <a type='button' class='btn btn-primary' href='{$deleteUrl}'>Delete</a>\n </div>\n </div>\n </div>\n </div>"; ++$ind; } } ?> </tbody>
<tr> <th>#</th> <th>Name</th> <th>Registered Via:</th> <th>Access Role</th> </tr> </thead> <tbody> <?php if ($users != null) { $ind = 1; foreach ($users as $user) { $extras = new Extras(); $featuredUrl = $extras->encryptQuery2(KEY_SALT, 'user_id', $user->user_id, 'user_id', $user->deny_access, 'users.php'); echo "<tr>"; echo "<td>{$ind}</td>"; echo "<td>{$user->full_name}</td>"; $registered_via = @"Web"; if ($user->facebook_id > 0) { $registered_via = @"Facebook"; } if ($user->twitter_id > 0) { $registered_via = @"Twitter"; } echo "<td>{$registered_via}</td>"; if ($user->deny_access == 1) { echo "<td><a href='{$featuredUrl}'>Allow</a></td>"; } else { echo "<td><a href='{$featuredUrl}'>Deny</a></td>";
</form> </div> </div> <div class="panel-body"> <div class="row"> <?php if ($photos_store != null) { $ind = 1; $count = count($photos_store); foreach ($photos_store as $photo_store) { $extras = new Extras(); $updateUrl = $extras->encryptQuery1(KEY_SALT, 'photo_id', $photo_store->photo_id, 'photo_store_update.php'); $deleteUrl = $extras->encryptQuery2(KEY_SALT, 'store_id', $photo_store->store_id, 'photo_id', $photo_store->photo_id, 'photo_store_view.php'); echo "<div class='col-sm-6 col-md-4'>"; echo "<div class='thumbnail'>"; echo "<img src='{$photo_store->thumb_url}' alt='...' style = 'display:block; height:150px; margin-left:auto; margin-right:auto; max-width:100%;'>"; echo "<div class='caption'>"; echo "<p>"; echo "<a href='{$updateUrl}' class='btn btn-primary btn-xs' role='button'>Edit</a> "; echo "<button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#modal_{$photo_store->photo_id}'>Large Image</button> "; echo "<button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#delete_modal_{$photo_store->photo_id}'>Delete</button>"; echo "</p>"; echo "</div>"; echo "</div>"; echo "</div>"; //<!-- Modal --> echo "<div class='modal fade' id='modal_{$photo_store->photo_id}' tabindex='-1' role='dialog' aria-labelledby='myModalLabel' aria-hidden='true'>"; echo "<div class='modal-dialog'>";
</thead> <tbody> <?php if ($stores != null) { $ind = $begin + 1; foreach ($stores as $store) { $featured = "no"; if ($store->featured == 1) { $featured = "yes"; } $no_of_photos = $controllerPhoto->getNoOfPhotosByStoreId($store->store_id); $rating = $controllerRating->getRatingByStoreId($store->store_id); $extras = new Extras(); $updateUrl = $extras->encryptQuery1(KEY_SALT, 'store_id', $store->store_id, 'store_update.php'); $deleteUrl = $extras->encryptQuery1(KEY_SALT, 'store_id', $store->store_id, 'stores.php'); $featuredUrl = $extras->encryptQuery2(KEY_SALT, 'store_id', $store->store_id, 'featured', $featured, 'stores.php'); $viewUrl = $extras->encryptQuery1(KEY_SALT, 'store_id', $store->store_id, 'photo_store_view.php'); $photoUrl = $extras->encryptQuery1(KEY_SALT, 'store_id', $store->store_id, 'photo_store_insert.php'); $reviewUrl = $extras->encryptQuery1(KEY_SALT, 'store_id', $store->store_id, 'store_reviews_view.php'); echo "<tr>"; echo "<td>{$ind}</td>"; echo "<td>{$store->store_name}</td>"; echo "<td>{$store->store_address}</td>"; echo "<td>{$no_of_photos} Foto(s)</td>"; echo "<td>{$rating}</td>"; if ($store->featured == 1) { echo "<td><a href='{$featuredUrl}'>No</a></td>"; } else { echo "<td><a href='{$featuredUrl}'>Yes</a></td>"; } echo "<td>\n <a class='btn btn-primary btn-xs' href='{$updateUrl}'><span class='glyphicon glyphicon-pencil'></span></a>\n <button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#modal_{$store->store_id}'><span class='glyphicon glyphicon-remove'></span></button>\n <a class='btn btn-primary btn-xs' href='{$viewUrl}'><span class='glyphicon glyphicon-th'></span></a>\n <a class='btn btn-primary btn-xs' href='{$reviewUrl}'><span>Comments</span></a>\n \n </td>";
<tr> <th>#</th> <th>Name</th> <th>Username</th> <th>Access Role</th> <th>Action</th> </tr> </thead> <tbody> <?php if ($users != null) { $ind = 1; foreach ($users as $user) { $extras = new Extras(); $featuredUrl = $extras->encryptQuery2(KEY_SALT, 'authentication_id', $user->authentication_id, 'authentication_id', $user->deny_access, 'admin_access.php'); $updateUrl = $extras->encryptQuery1(KEY_SALT, 'authentication_id', $user->authentication_id, 'access_user_update.php'); $deleteUrl = $extras->encryptQuery1(KEY_SALT, 'authentication_id', $user->authentication_id, 'admin_access.php'); $deleteUrl = $extras->encryptQuery2(KEY_SALT, 'authentication_id', $user->authentication_id, 'deleted', "deleted", 'admin_access.php'); echo "<tr>"; echo "<td>{$ind}</td>"; echo "<td>{$user->name}</td>"; echo "<td>{$user->username}</td>"; if ($user->deny_access == 1) { echo "<td><a href='{$featuredUrl}'>Allow</a></td>"; } else { echo "<td><a href='{$featuredUrl}'>Deny</a></td>"; } echo "<td>\n <a class='btn btn-primary btn-xs' href='{$updateUrl}'><span class='glyphicon glyphicon-pencil'></span></a>\n <button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#modal_{$user->authentication_id}'><span class='glyphicon glyphicon-remove'></span></button>\n </td>"; echo "</tr>"; //<!-- Modal -->
</thead> <tbody> <?php if ($realestates != null) { $ind = 1; foreach ($realestates as $realestate) { $featured = "no"; if ($realestate->featured == 1) { $featured = "yes"; } $no_of_photos = $controllerPhoto->getNoOfPhotosByRealEstateId($realestate->realestate_id); $extras = new Extras(); $updateUrl = $extras->encryptQuery1(KEY_SALT, 'realestate_id', $realestate->realestate_id, 'realestate_update.php'); $deleteUrl = $extras->encryptQuery1(KEY_SALT, 'realestate_id', $realestate->realestate_id, 'realestates.php'); $featuredUrl = $extras->encryptQuery2(KEY_SALT, 'realestate_id', $realestate->realestate_id, 'featured', $featured, 'realestates.php'); $viewUrl = $extras->encryptQuery1(KEY_SALT, 'realestate_id', $realestate->realestate_id, 'photo_realestate_view.php'); $photoUrl = $extras->encryptQuery1(KEY_SALT, 'realestate_id', $realestate->realestate_id, 'photo_realestate_insert.php'); echo "<tr>"; echo "<td>{$realestate->realestate_id}</td>"; echo "<td>{$realestate->price}</td>"; echo "<td>{$realestate->address}</td>"; echo "<td>{$no_of_photos} Photo(s)</td>"; if ($realestate->featured == 1) { echo "<td><a href='{$featuredUrl}'>No</a></td>"; } else { echo "<td><a href='{$featuredUrl}'>Yes</a></td>"; } echo "<td>\n <a class='btn btn-primary btn-xs' href='{$updateUrl}'><span class='glyphicon glyphicon-pencil'></span></a>\n <button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#modal_{$realestate->realestate_id}'><span class='glyphicon glyphicon-remove'></span></button>\n <a class='btn btn-primary btn-xs' href='{$viewUrl}'><span class='glyphicon glyphicon-th'></span></a>\n \n </td>"; echo "</tr>"; //<!-- Modal -->
</form> </div> </div> <div class="panel-body"> <div class="row"> <?php if ($photos_realestate != null) { $ind = 1; $count = count($photos_realestate); foreach ($photos_realestate as $photo_realestate) { $extras = new Extras(); $updateUrl = $extras->encryptQuery1(KEY_SALT, 'photo_id', $photo_realestate->photo_id, 'photo_realestate_update.php'); $deleteUrl = $extras->encryptQuery2(KEY_SALT, 'realestate_id', $photo_realestate->realestate_id, 'photo_id', $photo_realestate->photo_id, 'photo_realestate_view.php'); echo "<div class='col-sm-6 col-md-4'>"; echo "<div class='thumbnail'>"; echo "<img src='{$photo_realestate->thumb_url}' alt='...' style = 'display:block; height:150px; margin-left:auto; margin-right:auto; max-width:100%;'>"; echo "<div class='caption'>"; echo "<p>"; echo "<a href='{$updateUrl}' class='btn btn-primary btn-xs' role='button'>Edit</a> "; echo "<button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#modal_{$photo_realestate->photo_id}'>Large Photo</button> "; echo "<button class='btn btn-primary btn-xs' data-toggle='modal' data-target='#delete_modal_{$photo_realestate->photo_id}'>Delete</button>"; echo "</p>"; echo "</div>"; echo "</div>"; echo "</div>"; //<!-- Modal --> echo "<div class='modal fade' id='modal_{$photo_realestate->photo_id}' tabindex='-1' role='dialog' aria-labelledby='myModalLabel' aria-hidden='true'>"; echo "<div class='modal-dialog'>";