attributes = $attributes; $this->content = $content; } /** * put your comment there... * */ public function __toString() { // Initialize. $attributes =& $this->attributes; // Default Class. if (!isset($attributes['class'])) { $shortcodeClass = 'block'; } // Get Shortcode class file, check existance! $shortcodeClassFile = cssJSToolbox::resolvePath('controllers:coupling:shortcode:block:block.php'); if (!file_exists($shortcodeClassFile)) { throw new Exception('Shortcode Type is not supported!! Only (block) type is currently available!!!'); } // Import shortcodee handler file. require_once $shortcodeClassFile; // Import class. $className = "CJT_Controllers_Coupling_Shortcode_{$shortcodeClass}"; // Load shortcode 'CLASS' handler. $shortcode = new $className($this->attributes, $this->content); // Return Shortcode replacements. return ((string) $shortcode); } } // End class // Hookable! CJT_Controllers_Coupling_Shortcode::define('CJT_Controllers_Coupling_Shortcode');