!C99Shell v. 2.1 [PHP 8 Update] [02.02.2022]!

Software: Apache/2.4.53 (Unix) OpenSSL/1.1.1o PHP/7.4.29 mod_perl/2.0.12 Perl/v5.34.1. PHP/7.4.29 

uname -a: Linux vps-2738122-x 4.15.0-213-generic #224-Ubuntu SMP Mon Jun 19 13:30:12 UTC 2023 x86_64 

uid=1(daemon) gid=1(daemon) grupos=1(daemon) 

Safe-mode: OFF (not secure)

/opt/apex_tdfonline/php/nucleo/lib/   drwxr-xr-x
Free 14.92 GB of 61.93 GB (24.09%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     toba_gadget.php (5.15 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/**
 * Clase abstracta para manejo de un gadget.
 * @package Centrales 
 */

abstract class toba_gadget
{
    protected 
$_id_gadget;
    protected 
$_datos = array();
    
    function 
__construct($id null)
    {
            
//No hago obligatorio el ID por si algun dia se agregan gadgets en runtime sin que esten en la base de toba.
            
if (! is_null($id)) {
                
$this->_id_gadget $id;
            }
    }
        
    
//----------------------------------------------------------------------------------------- MANIPULACION DE PROPIEDADES --------------------------------------------------------------------------------
    
function get_titulo()
    {
        
$result = (isset($this->_datos['titulo'])) ? $this->_datos['titulo'] : '';
        return 
$result;
    }

    function 
get_descripcion()
    {
        
$result = (isset($this->_datos['descripcion'])) ? $this->_datos['descripcion'] : '';
        return 
$result;
    }
    
    function 
get_gadget_url()
    {
        
$result = (isset($this->_datos['gadget_url'])) ? $this->_datos['gadget_url'] : '';
        return 
$result;
    }

    function 
get_tipo()
    {
        return 
apex_tipo_gadget_interno;
    }

    function 
get_clase()
    {
        
//Busco las dos claves que me sirven, van ambas juntas o nada.
        
$result array_intersect_keys($this->_datos, array('subclase' => '1''subclase_archivo'  => '1'));
        if (
count($result) < 2) {
            throw 
toba_error_def('La definición de subclase para el gadget esta incompleta');
        }
        return 
$result;
    }

    function 
get_orden()
    {
        
$result = (isset($this->_datos['orden'])) ? $this->_datos['orden'] : '1';
        return 
$result;
    }

    function 
es_eliminable()
    {
        return (isset(
$this->_datos['eliminable']) && ($this->_datos['eliminable'] == 'S'));
    }
    
//-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    
function set_titulo($titulo)
    {
        
$this->_datos['titulo'] = $titulo;
    }

    function 
set_descripcion($descripcion)
    {
        
$this->_datos['descripcion'] = $descripcion;
    }

    function 
set_gadget_url($url)
    {
        
$this->_datos['gadget_url'] = $url;
    }

    function 
set_clase($subclase$subclase_archivo)
    {
        
$this->_datos['subclase']  = $subclase;
        
$this->_datos['subclase_archivo'] = $subclase_archivo;
    }

    function 
set_orden($orden)
    {
        
$this->_datos['orden'] = $orden;
    }

    function 
set_eliminable($eliminable)
    {
        
$this->_datos['eliminable'] = $eliminable;
    }

    
//--------------------------------------------------------------------------------------------------------------- SALIDA DEL GADGET -----------------------------------------------------------------------------------------
    
function generar_html()
    {
    }    
}
?>

<?php
// -------------------------------------------------------------------    ESTO QUEDA AQUI A MODO DE RECORDATORIO PARA REVISAR EL BUG DEL SERVICIO generar_html ----------------------------------------------------------------------
/*
    static function generar_gadget_interno($gadget) {
        toba::logger()->seccion('== Inicio de gadget interno '.$gadget['titulo'].' ==','toba');
        $solicitud = toba_constructor::get_runtime(array('proyecto'=>$gadget['proyecto'],'componente'=>$gadget['item']), 'toba_item');
        echo "<div id='gadget-chrome-{$gadget['orden']}' class='gadgets-gadget-chrome'>";
        echo "<div id='gadgets-gadget-title-bar-{$gadget['orden']}' class='gadgets-gadget-title-bar'>";
        echo "<span class='gadgets-gadget-title' id='remote_iframe_{$gadget['orden']}_title'>{$gadget['titulo']}</span> | ";
        echo "<span class='gadgets-gadget-title-button-bar' onclick='var c=document.getElementById(\"gadget-content-{$gadget['orden']}\");if(c.style.display==\"none\") {c.style.display=\"block\"} else {c.style.display=\"none\"}' style='text-decoration: underline; cursor:pointer'>toggle</span>";
        if ($gadget['eliminable']=='S') {
        echo "<img style='float:right; margin-right: 5px; margin-left: 5px; margin-top: 1px; margin-bottom: 1px; width: 15px; height: 15px' onClick='this.parentNode.parentNode.parentNode.removeChild(this.parentNode.parentNode)' src='".toba_recurso::imagen_toba('finalizar_sesion.gif',false)."'/>";
        }
        echo "</div>\n";
        echo "<div id='gadget-content-{$gadget['orden']}' class='gadgets-gadget-content'>";
        echo "<div style='background:none; width: 250px; padding: 3px;'>";
        if($solicitud->get_datos_item('tipo_pagina_clase') == 'toba_tipo_pagina') {
            /*
             * bug en la linea 231, de la función servicio__generar_html de toba_solicitud_web
             * aunque se le indique que el componente no tiene salida (clase 'toba_tipo_pagina') en toba editor,
             * lo mismoincluye el cierre de dos divs (barra superior y encabezado) aunque no hayan sido creados.
             *
             *  Se debería chequear el tipo de página.
             */
        /*    echo "<div style='display: none'><div>";
        }
        $solicitud->procesar();
        echo "</div>\n";
        echo "</div>\n";
        echo "</div>\n";
        toba::logger()->seccion('== Fin de gadget interno '.$gadget['titulo'].' ==','toba');
    }*/
// -------------------------------------------------------------------    ESTO QUEDA AQUI A MODO DE RECORDATORIO PARA REVISAR EL BUG DEL SERVICIO generar_html ----------------------------------------------------------------------
?>

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.1 [PHP 8 Update] [02.02.2022] maintained byC99Shell Github | Generation time: 0.2964 ]--