| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869 |
- <?php
- /**
- * Shortcode functionality of the plugin.
- *
- * @package QDR_Temporary_Shared_Storage
- * @since 1.0.0
- */
- class QDR_TSS_Shortcode {
- /**
- * The ID of this plugin.
- *
- * @since 1.0.0
- * @access private
- * @var string $plugin_name The ID of this plugin.
- */
- private $plugin_name;
- /**
- * The version of this plugin.
- *
- * @since 1.0.0
- * @access private
- * @var string $version The current version of this plugin.
- */
- private $version;
- /**
- * The download handler instance.
- *
- * @since 1.0.0
- * @access private
- * @var QDR_TSS_Download $download The download handler instance.
- */
- private $download;
- /**
- * Initialize the class and set its properties.
- *
- * @since 1.0.0
- * @param string $plugin_name The name of this plugin.
- * @param string $version The version of this plugin.
- */
- public function __construct($plugin_name, $version) {
- $this->plugin_name = $plugin_name;
- $this->version = $version;
- $this->download = new QDR_TSS_Download($plugin_name, $version);
- }
- /**
- * Register shortcodes.
- *
- * @since 1.0.0
- */
- public function register_shortcodes() {
- add_shortcode('qdr_tss_download', array($this, 'download_shortcode'));
- }
- /**
- * Download shortcode.
- *
- * @since 1.0.0
- * @param array $atts Shortcode attributes.
- * @return string Shortcode output.
- */
- public function download_shortcode($atts) {
- return $this->download->process_download_request($atts);
- }
- }
|