function show_theme_update_notise()
 {
     if ($this->theme_update_notise) {
         echo '<div class="updated"><p>' . rf__($this->theme_update_notise) . '</p></div>';
     }
 }
			<th class="check-column">
				<input type="checkbox" name="ext_chk[]" value="<?php 
            echo $ext;
            ?>
" />
			</th>
			<td class="plugin-title">
				<strong><?php 
            rf_e($ext_info['Name']);
            ?>
</strong>
			</td>
			<td class="column-description desc">
				<?php 
            // Item description
            $description = '<div class="plugin-description"><p>' . rf__($ext_info['Description']) . '</p></div>';
            // Item info
            $class = $ext_cnt ? 'inactive' : 'active';
            $version = $ext_info['Version'] ? __('Version', 'framework') . ': ' . $ext_info['Version'] : '';
            if ($ext_info['Author']) {
                $author = ' | By ' . $ext_info['Author'];
                if ($ext_info['AuthorURI']) {
                    $author = ' | By <a href="' . $ext_info['AuthorURI'] . '" title="' . __('Visit author homepage', 'framework') . '">' . $ext_info['Author'] . '</a>';
                }
            } else {
                $author = ' | By Unknown';
            }
            $plugin_link = $ext_info['ExtensionURI'] ? ' | <a href="' . $ext_info['ExtensionURI'] . '" title="' . __('Visit plugin site', 'framework') . '">' . __('Visit plugin site', 'framework') . '</a>' : '';
            $info = '<div class="' . $class . ' second plugin-version-author-uri">' . $version . $author . $plugin_link . '</div>';
            // Print details
            echo $description;
Example #3
0
    $extension_zip_file_name = $directory->downloads_dir . $item . '.zip';
    $zipPath = isset($this->extensions_Paid[0]->Path) ? '&zip=' . $this->extensions_Paid[0]->Path : '';
    $extension_zip = $wp_filesystem->get_contents($directory->extensions_server_url . "download_extension&item={$item}" . $zipPath);
    if (strlen($extension_zip) !== 0) {
        //	$extension_zip = base64_decode( $extension_zip );
        $extension_zip = runway_base_decode($extension_zip, true);
        $wp_filesystem->put_contents($extension_zip_file_name, $extension_zip, FS_CHMOD_FILE);
        $permissions = substr(sprintf('%o', fileperms($extension_zip_file_name)), -4);
        if ($permissions < '0755') {
            chmod($extension_zip_file_name, 0755);
        }
        echo $extm->load_new_extension($extension_zip_file_name);
    } else {
        if (!empty($response_json)) {
            $ext_name = empty($this->extensions_Paid) ? $extm->extensions_List[$item . '/load.php']['Name'] : $response_pre->extensions->{$item}->Name;
            echo '<div id="message" class="error"><p>' . rf__('The error upon an attempt to install ' . $ext_name . ' extension') . '</p></div>';
        }
    }
}
// Load the content
switch ($tab) {
    default:
        $response_exts = $response_pre->extensions;
        $response = $response_pre;
        unset($response->extensions);
        if (isset($response_exts)) {
            foreach ($response_exts as $key => $resp_ext) {
                if (isset($this->extensions_Paid) && !empty($this->extensions_Paid)) {
                    foreach ($this->extensions_Paid as $exts) {
                        // Overwrite if also exists as product entery.
                        $response->extensions[$key] = $resp_ext;
<?php

$ext_err_name = isset($this->extensions_addons->{$item}->Name) && !empty($this->extensions_addons->{$item}->Name) ? $this->extensions_addons->{$item}->Name : __('Unknown', 'framework');
$error_msg = isset($body['error_message']) && !empty($body['error_message']) ? rf__('There was an error while attempting to install the ' . $ext_err_name . ' extension: ') . $body['error_message'] : rf__('There was an error while attempting to install the ' . $ext_err_name . ' extension');
echo '<div id="message" class="error"><p>' . $error_msg . '</p></div>';
function theme_show_box_content_options()
{
    global $post;
    $meta_box_content_options = theme_portfolio_meta_box_content_options();
    // Use nonce for verification
    echo '<input type="hidden" name="theme_meta_box_nonce" value="', wp_create_nonce(basename(__FILE__)), '" />';
    wp_nonce_field('theme_meta_box_nonce', 'theme_meta_box_nonce_post');
    $increment = 0;
    foreach ($meta_box_content_options['fields'] as $field) {
        // some styling
        $style = $increment && !in_array($field['id'], array('header', 'optional_label', 'layout', 'footer')) ? 'border-top: 1px solid #dfdfdf;' : '';
        // get current post meta data
        $meta = $field['id'] == 'optional_label' ? $field['selected'] : get_post_meta($post->ID, $field['id'], true);
        if ($meta === null || $meta === false || $meta === '') {
            $post_parents = get_post_ancestors($post->ID);
            foreach ($post_parents as $post_parent_key => $post_parent) {
                $tmp_meta = $field['id'] == 'optional_label' ? $field['selected'] : get_post_meta($post_parent, $field['id'], true);
                if ($tmp_meta !== null && $tmp_meta !== false && $tmp_meta !== '') {
                    $meta = $tmp_meta;
                    break;
                }
            }
        }
        $data = isset($field['data']) ? 'data-index="' . $field['data'] . '"' : '';
        switch ($field['type']) {
            // Select box
            case 'select':
                $style_select = in_array($field['id'], array('header', 'footer', 'layout', 'optional_label')) ? 'style="width:100%;"' : '';
                echo '<div class="metaField_field_wrapper metaField_field_' . $field['id'] . '" style="' . $style . '">', '<p><label for="' . $field['id'] . '"><strong>' . rf__($field['name']) . '</strong></label></p>', '<select class="metaField_select" id="' . $field['id'] . '"  name="' . $field['id'] . '" ' . $style_select . ' ' . $data . '>';
                $count = 0;
                foreach ($field['options'] as $key => $label) {
                    $selected = $meta == $key || !$meta && !$count ? 'selected="selected"' : '';
                    echo '<option value="' . $key . '" ' . $selected . '>' . $label . '</option>';
                    $count++;
                }
                echo '</select>';
                if ($field['desc']) {
                    echo '<p class="metaField_caption" style="color:#999">' . rf__($field['desc']) . '</p>';
                }
                echo '</div>';
                break;
                // Radio group
            // Radio group
            case 'radio':
                echo '<div class="metaField_field_wrapper metaField_field_' . $field['id'] . '" style="' . $style . '">', '<p><label for="' . $field['id'] . '"><strong>' . rf__($field['name']) . '</strong></label></p>';
                $count = 0;
                foreach ($field['options'] as $key => $label) {
                    $checked = $meta == $key || !$meta && !$count ? 'checked="checked"' : '';
                    echo '<label class="metaField_radio" style="display: block; padding: 2px 0;"><input class="metaField_radio" type="radio" name="' . $field['id'] . '" value="' . $key . '" ' . $checked . '> ' . $label . '</label>';
                    $count++;
                }
                echo '<p class="metaField_caption" style="color:#999">' . rf__($field['desc']) . '</p>', '</div>';
                break;
                // Checkbox
            // Checkbox
            case 'checkbox':
                $checked = $meta ? 'checked="checked"' : '';
                echo '<div class="metaField_field_wrapper metaField_field_' . $field['id'] . '" style="' . $style . '">', '<p>', '<label for="' . $field['id'] . '"><input class="metaField_checkbox" type="checkbox" id="' . $field['id'] . '" name="' . $field['id'] . '" value="1" ' . $checked . '> ' . rf__($field['name']) . '</label></p>', '<p class="metaField_caption" style="color:#999">' . rf__($field['desc']) . '</p>', '</div>';
                break;
        }
        $increment++;
    }
}
"><?php 
echo __('Plugins', 'framework');
?>
</a></li>
		<li class="add-ons-item-hidden"><a href="#" data-sort="fields">Fields</a></li>
	</ul>
	<div class="search-form">
		<?php 
$url = 'admin.php?page=directory&addons=' . $addons_type;
?>
		<form id="search-plugins" method="post" action="<?php 
echo admin_url($url);
?>
">
			<input placeholder="<?php 
echo __('Search ', 'framework') . strtolower(rf__($addons_type)) . '...';
?>
" type="search" name="s" id="wp-filter-search-rf-input" value="<?php 
echo isset($_REQUEST['s']) ? esc_attr($_REQUEST['s']) : '';
?>
" class="wp-filter-search-rf">
			<input class="button button-primary" type="submit" name="plugin-search-input" id="plugin-search-input" value="Search">
		</form>		
	</div>
</div>


<div class="theme-browser content-filterable rendered">
	<?php 
foreach ($extensions_addons_search as $key => $item_addons) {
    $item_name = isset($item_addons->Files[0]->name) ? str_replace('-', '_', sanitize_key($item_addons->Files[0]->name)) : '';
 }
 echo '<a name="' . sanitize_title($elements->{$container}->title) . '"></a>';
 if ($elements->{$container}->type == 'invisible') {
     echo '<h3 class="container-title">' . rf__($elements->{$container}->title) . '</h3>';
 }
 if ($elements->{$container}->type == 'visible') {
     echo '<div class="meta-box-not-sortables metabox-holder">';
     echo '<div class="postbox">';
     echo '<h3 class="no-move"><span>' . rf__($elements->{$container}->title) . '</span></h3>';
     echo '<div class="inside">';
 }
 if ($elements->{$container}->type == 'show-hide') {
     // echo '<a name="'. $elements->$container->title .'"></a>';
     echo '<div class="meta-box-sortables metabox-holder">';
     echo '<div class="postbox">';
     echo '<div class="handlediv" title="' . __('Click to toggle', 'framework') . '"><br></div><h3 class="hndle"><span>' . rf__($elements->{$container}->title) . '</span></h3>';
     echo '<div class="inside" style="display: none;">';
 }
 echo '<table class="form-table">';
 // Output the Fields
 // ------------------------------------------
 if (!empty($fields)) {
     // out($options_object);
     foreach ($fields as $field) {
         // temporary fix for '[none] => none' values showing up in JSON files.
         if ($container == 'none' || $field == 'none') {
             continue;
         }
         $title = stripslashes(__(htmlspecialchars_decode($elements->{$field}->title), 'framework'));
         $titleCaption = isset($elements->{$field}->titleCaption) ? stripslashes($options_object->html->format_comment(__(htmlspecialchars_decode($elements->{$field}->titleCaption), 'framework'))) : '';
         $fieldCaption = isset($elements->{$field}->fieldCaption) ? stripslashes($options_object->html->format_comment(__(htmlspecialchars_decode($elements->{$field}->fieldCaption), 'framework'))) : '';
<form method="post" action="<?php 
echo $action_url_yes;
?>
" style="display:inline;">
	<p>
		<?php 
echo __('You are about to remove the following', 'framework') . ' ' . rf__($item_confirm) . ':';
?>
		<ul class="ul-disc">
			<li><?php 
rf_e($item_title);
?>
</li>
		</ul>
		<?php 
echo __('Are you sure you want to delete this', 'framework') . ' ' . rf__($item_confirm) . '?';
?>
	</p>
	<?php 
submit_button(__('Yes, Delete this', 'framework') . ' ' . rf__($item_confirm), 'button', 'submit', false);
?>
</form>
<form method="post" action="<?php 
echo $action_url_no;
?>
" style="display:inline;">
	<?php 
submit_button(__('No, Return me to the', 'framework') . ' ' . rf__($item_confirm) . ' ' . __('list', 'framework'), 'button', 'submit', false);
?>
</form>
 /**
  * Outputs the footer strings and necessary JS after each plugin installation.
  *
  * Checks for any errors and outputs them if they exist, else output
  * success strings.
  *
  * @since 2.2.0
  */
 public function after($title = '')
 {
     /** Close install strings */
     echo '</p></div>';
     /** Output error strings if an error has occurred */
     if ($this->error || !$this->result) {
         if ($this->error) {
             echo '<div class="error"><p>' . sprintf(rf__($this->upgrader->strings['skin_update_failed_error']), $this->plugin_names[$this->i], $this->error) . '</p></div>';
         } else {
             echo '<div class="error"><p>' . sprintf(rf__($this->upgrader->strings['skin_update_failed']), $this->plugin_names[$this->i]) . '</p></div>';
         }
         echo '<script type="text/javascript">jQuery(\'#progress-' . esc_js($this->upgrader->update_current) . '\').show();</script>';
     }
     /** If the result is set and there are no errors, success! */
     if (!empty($this->result) && !is_wp_error($this->result)) {
         echo '<div class="updated"><p>' . sprintf(rf__($this->upgrader->strings['skin_update_successful']), $this->plugin_names[$this->i], 'jQuery(\'#progress-' . esc_js($this->upgrader->update_current) . '\').toggle();jQuery(\'span\', this).toggle(); return false;') . '</p></div>';
         echo '<script type="text/javascript">jQuery(\'.waiting-' . esc_js($this->upgrader->update_current) . '\').hide();</script>';
     }
     /** Set in_loop and error to false and flush footer output buffer */
     $this->reset();
     $this->after_flush_output();
 }