- GRAYBYTE UNDETECTABLE CODES -

403Webshell
Server IP : 184.154.167.98  /  Your IP : 3.144.84.31
Web Server : Apache
System : Linux pink.dnsnetservice.com 4.18.0-553.22.1.lve.1.el8.x86_64 #1 SMP Tue Oct 8 15:52:54 UTC 2024 x86_64
User : puertode ( 1767)
PHP Version : 8.2.26
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/puertode/public_html/oficios/sis/core/app/view/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/puertode/public_html/oficios/sis/core/app/view/submenu-view.php
<?php 

//$user= ItemData::getById($_SESSION["user_id"]);
// si el id  del usuario no existe.

if(isset($_GET["opt"]) && $_GET["opt"]=="all"):
$item = ItemData::getById($_GET["id"]);
  ?>
<section class="container">
<div class="row">
	<div class="col-md-12">
		<h1>Modificar Sub Menu</h1>
    <h3>ELEMENTO: <?php echo $item->label; ?></h3>
	<a href="index.php?view=submenu&opt=new&id=<?php echo $_GET["id"];?>" class="btn btn-default"><i class='glyphicon glyphicon-plus'></i> Nuevo</a>
<br><br>
		<?php
		$users = ItemData::getAllBy("item_id",$_GET["id"]);
		if(count($users)>0){
			?>
			<div class="box box-primary">
			<table class="table table-bordered datatable table-hover">
			<thead>
        <th></th>
			<th>Etiqueta</th>
			<th>Link</th>
      <th>Posicion</th>
			<th></th>
			</thead>
			<?php
			foreach($users as $user){
				?>
				<tr>
          <td style="width: 30px; ">
<!--            <a href="./?view=submenu&opt=subitems&id=<?php echo $user->id; ?>" class="btn btn-default btn-xs"><i class="glyphicon glyphicon-chevron-right"></i></a> -->
          </td>
				<td><?php echo $user->label; ?></td>
				<td><?php echo $user->link; ?></td>
        <td><?php echo $user->position; ?></td>
				<td style="width:120px;">
				<a href="index.php?view=submenu&opt=edit&id=<?php echo $user->id;?>" class="btn btn-warning btn-xs">Editar</a>
				<a href="index.php?action=submenu&opt=del&id=<?php echo $user->id;?>" class="btn btn-danger btn-xs">Eliminar</a>
				</td>
				</tr>
				<?php

			}
 echo "</table></div>";

		}else{
			?>
			<p class="alert alert-warning">No hay Elementos.</p>
			<?php
		}

		?>

	</div>
</div>
</section>
<?php elseif(isset($_GET["opt"]) && $_GET["opt"]=="new"):?>

<section class="container">
<div class="row">
	<div class="col-md-12">
	<h1>Agregar Elemento</h1>
	<br>
<form class="form-horizontal" method="post" id="addproduct" action="index.php?action=submenu&opt=add" role="form">
  <input type="hidden" name="item_id" value="<?php echo $_GET["id"]; ?>">
  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Etiqueta*</label>
    <div class="col-md-6">
      <input type="text" name="label" class="form-control" id="label" placeholder="Etiqueta">
    </div>
  </div>
  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Link*</label>
    <div class="col-md-6">
      <input type="text" name="link" required class="form-control" id="link" placeholder="Link">
    </div>
  </div>
  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Target (_self, _blank)</label>
    <div class="col-md-6">
      <input type="text" name="target" class="form-control"  id="target" placeholder="Target (_self, _blank)">
    </div>
  </div>
  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Position*</label>
    <div class="col-md-6">
      <input type="text" name="position" class="form-control" id="position" placeholder="Position">
    </div>
  </div>

  <div class="form-group">
    <div class="col-lg-offset-2 col-lg-10">
      <button type="submit" class="btn btn-primary">Agregar Elemento</button>
    </div>
  </div>
</form>
	</div>
</div>
</section>

<?php elseif(isset($_GET["opt"]) && $_GET["opt"]=="edit"):?>
<div class="container">
<?php $user = ItemData::getById($_GET["id"]);?>
<div class="row">
	<div class="col-md-12">
	<h1>Editar Elemento</h1>
	<br>
		<form class="form-horizontal" method="post" id="addproduct" action="index.php?action=submenu&opt=upd" role="form">


  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Etiqueta*</label>
    <div class="col-md-6">
      <input type="text" name="label" value="<?php echo $user->label;?>" class="form-control" id="label" placeholder="Etiqueta">
    </div>
  </div>
  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Link*</label>
    <div class="col-md-6">
      <input type="text" name="link" value="<?php echo $user->link;?>" required class="form-control" id="link" placeholder="Link">
    </div>
  </div>
  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Target*</label>
    <div class="col-md-6">
      <input type="text" name="target" value="<?php echo $user->target;?>" class="form-control" required id="target" placeholder="Target">
    </div>
  </div>
  <div class="form-group">
    <label for="inputEmail1" class="col-lg-2 control-label">Posicion*</label>
    <div class="col-md-6">
      <input type="text" name="position" value="<?php echo $user->position;?>" class="form-control" id="position" placeholder="Posicion">
    </div>
  </div>



  <div class="form-group">
    <div class="col-lg-offset-2 col-lg-10">
    <input type="hidden" name="user_id" value="<?php echo $user->id;?>">
      <button type="submit" class="btn btn-success">Actualizar Elemento</button>
    </div>
  </div>
</form>
	</div>
</div>
</div>
<?php endif; ?>

Youez - 2016 - github.com/yon3zu
LinuXploit