HEX
Server: nginx/1.26.1
System: Linux iZrj9cbdvwu1cot8sjlyzlZ 5.10.134-15.al8.x86_64 #1 SMP Thu Jul 20 00:44:04 CST 2023 x86_64
User: www (1000)
PHP: 7.4.33
Disabled: passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
Upload Files
File: /www/wwwroot/dewenlabels.com11/wp-content/plugins/iks-menu/includes/Widget.php
<?php
/**
 * Iks Menu
 *
 *
 * @package   Iks Menu
 * @author    IksStudio
 * @license   GPL-3.0
 * @link      https://iks-menu.com
 * @copyright 2019 IksStudio
 */

namespace IksStudio\IKSM;

use IksStudio\IKSM_CORE\Plugin;
use IksStudio\IKSM_CORE\render\StylesRenderer;
use IksStudio\IKSM_CORE\utils\PluginPostManager;
use IksStudio\IKSM_CORE\utils\Utils;
use IksStudio\IKSM_CORE\Widget_Base;
use IksStudio\IKSM\render\MenuRenderer;

/**
 * @subpackage Widget
 */
class Widget extends Widget_Base {

	/**
	 * Initialize the widget
	 *
	 * @since 1.0.0
	 */
	public function __construct() {
		parent::__construct( Utils::t( "Accordion menu with terms from any taxonomy or custom menu" ) );
	}


	/**
	 * Main render function of the widget
	 *
	 * @param array $args
	 * @param array $instance
	 */
	public function widget( $args, $instance ) {
		$output  = '';
		$post_id = (int) Utils::get( $instance, "id" );

		/*
		 * Render
		 */

		$post_manager  = new PluginPostManager( $post_id );
		$post_settings = $post_manager->get_settings();
		$renderer      = new MenuRenderer( $post_settings, $post_id );
		$output        .= $renderer->render();

		/*
		 * Styles
		 */
		$settings = Plugin::$SettingsStore->get_settings();
		echo ( new StylesRenderer( $post_settings, $post_id ) )->render( $settings );

		/*
		 * Widget output
		 */
		$this->render_widget_before( $args, $instance );
		echo $output;
		$this->render_widget_after( $args, $instance );
	}

}