AnonSec Shell
Server IP : 46.105.57.169  /  Your IP : 216.73.216.144
Web Server : Apache
System : Linux webd003.cluster120.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User : maitricfuz ( 93378)
PHP Version : 8.4.10
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/maitricfuz/www/saint-martin-lg/plugins/sliderck/joomgallery/elements/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/maitricfuz/www/saint-martin-lg/plugins/sliderck/joomgallery/elements/joomcategory.php
<?php
// $HeadURL: https://joomgallery.org/svn/joomgallery/JG-3/JG/trunk/administrator/components/com_joomgallery/models/fields/joomcategory.php $
// $Id: joomcategory.php 4381 2014-05-04 09:30:44Z erftralle $
/****************************************************************************************\
**   JoomGallery 3                                                                      **
**   By: JoomGallery::ProjectTeam                                                       **
**   Copyright (C) 2008 - 2013  JoomGallery::ProjectTeam                                **
**   Based on: JoomGallery 1.0.0 by JoomGallery::ProjectTeam                            **
**   Released under GNU GPL Public License                                              **
**   License: http://www.gnu.org/copyleft/gpl.html or have a look                       **
**   at administrator/components/com_joomgallery/LICENSE.TXT                            **
\****************************************************************************************/

defined('_JEXEC') or die('Direct Access to this location is not allowed.');

/**
 * Renders a category select box form field
 *
 * @package     JoomGallery
 * @since       2.0
 */
class JFormFieldJoomCategory extends \Joomla\CMS\Form\FormField
{
  /**
   * The form field type.
   *
   * @var     string
   * @since   2.0
   */
  protected $type = 'JoomCategory';

  /**
   * Returns the HTML for a category select box form field.
   *
   * @return  object    The category select box form field.
   * @since   2.0
   */
  protected function getInput()
  {
    include_once JPATH_ADMINISTRATOR.'/components/com_joomgallery/includes/defines.php';
    JLoader::register('JoomExtensions', JPATH_ADMINISTRATOR.'/components/'._JOOM_OPTION.'/helpers/extensions.php');
    JLoader::register('JoomHelper', JPATH_BASE.'/components/'._JOOM_OPTION.'/helpers/helper.php');
    JLoader::register('JoomConfig', JPATH_BASE.'/components/'._JOOM_OPTION.'/helpers/config.php');
    JLoader::register('JoomAmbit', JPATH_BASE.'/components/'._JOOM_OPTION.'/helpers/ambit.php');
    \Joomla\CMS\Table\Table::addIncludePath(JPATH_ADMINISTRATOR.'/components/'._JOOM_OPTION.'/tables');
    \Joomla\CMS\HTML\HTMLHelper::addIncludePath(JPATH_BASE.'/components/'._JOOM_OPTION.'/helpers/html');

    $class = $this->element['class'] ? (string) $this->element['class'] : '';
    if($this->element['included'] && $this->element['included'] == true && strpos($class, 'included') === false)
    {
      if(!empty($class))
      {
        $class .= ' ';
      }
      $class .= 'included';
    }
    if($this->element['validate'] && (string) $this->element['validate'] == 'joompositivenumeric')
    {
      $doc = \Sliderck\CKFof::getDocument();

      // Add a validation script for form validation
      $js_validate = "
        jQuery(document).ready(function() {
          document.formvalidator.setHandler('joompositivenumeric', function(value) {
            regex=/^[1-9]+[0-9]*$/;
            return regex.test(value);
          })
        });";
      $doc->addScriptDeclaration($js_validate);
      // Element class needs attribute validate-...
      if(!empty($class))
      {
        $class .= ' ';
      }
      $class .= 'validate-'.(string) $this->element['validate'];

      // Add some style to make the slect box red bordered when invalid
      $css = '
        select.invalid {
          border: 1px solid red;
        }';
      $doc->addStyleDeclaration($css);
    }

    $attr    = '';
    $attr   .= !empty($class) ? ' class="'.$class.'"' : '';
    $attr   .= ((string) $this->element['disabled'] == 'true') ? ' disabled="disabled"' : '';
    $attr   .= $this->element['size'] ? ' size="'.(int) $this->element['size'].'"' : '';
    $attr   .= $this->element['onchange'] ? ' onchange="'.(string) $this->element['onchange'].'"' : '';
    $action  = $this->element['action'] ? (string) $this->element['action'] : 'core.create';
    $exclude = $this->element['exclude'] ? (int) $this->element['exclude'] : null;
    $task    = $this->element['task'] ? (int) $this->element['task'] : null;

    $html = \Joomla\CMS\HTML\HTMLHelper::_('joomselect.categorylist', $this->value, $this->name, $attr, $exclude, '- ', $task, $action, $this->id);

    return $html;
  }
}

Anon7 - 2022
AnonSec Team