<a href="<?php 
        echo $remove_link;
        ?>
" style="float:right; margin-top:1.3em;" class="button button-small"><?php 
        echo __('Remove', 'wpla');
        ?>
</a>
									<?php 
    }
    ?>

									<?php 
    echo $template->title == 'Offer' ? 'Listing Loader' : $template->title;
    ?>
									(<?php 
    echo WPLA_AmazonMarket::getMarketCode($template->site_id);
    ?>
)<br>
									<small>Version <?php 
    echo $template->version;
    ?>
</small> <br>

									<?php 
    if ($profile_count) {
        ?>
										<small>Currently used in <?php 
        echo $profile_count;
        ?>
 profile(s)</small>
									<?php 
 public function ajax_get_amazon_categories_tree()
 {
     $path = $_POST["dir"];
     // example: /0/20081/37903/ - /0/ means root
     $parent_node_id = basename($path);
     $categories = $this->getChildrenOfCategory($parent_node_id);
     // echo "<pre>";print_r($categories);echo"</pre>";#die();
     // $categories = apply_filters( 'wpla_get_amazon_categories_node', $categories, $parent_node_id, $path );
     $show_node_ids = get_option('wpla_show_browse_node_ids');
     if (count($categories) > 0) {
         echo "<ul class=\"jqueryFileTree\" style=\"display: none;\">" . "\n";
         // first show all folders
         foreach ($categories as $cat) {
             if ($cat['leaf'] == '0') {
                 $node_id = $cat['node_id'];
                 $node_label = $cat['node_name'];
                 $node_slug = $_POST['dir'] . $cat['node_id'];
                 $keyword = $cat['keyword'];
                 if ($path == '/0/') {
                     $node_label .= ' (' . WPLA_AmazonMarket::getMarketCode($cat['site_id']) . ')';
                 } elseif ($show_node_ids) {
                     $node_label .= ' (' . $cat['node_id'] . ')';
                     if ($keyword) {
                         $node_label .= ' (' . $keyword . ')';
                     }
                 }
                 echo '<li class="directory collapsed"><a href="#" id="wpla_node_id_' . $node_id . '" rel="' . $node_slug . '/" data-keyword="' . $keyword . '" >' . $node_label . '</a></li>' . "\n";
             }
         }
         // then show all leaf nodes
         foreach ($categories as $cat) {
             if ($cat['leaf'] == '1') {
                 $node_id = $cat['node_id'];
                 $node_label = $cat['node_name'];
                 // $node_slug  = $_POST['dir'] . $cat['keyword'];
                 $node_slug = $cat['node_id'] ? $_POST['dir'] . $cat['node_id'] : $_POST['dir'] . $cat['keyword'];
                 $keyword = $cat['keyword'];
                 if ($show_node_ids) {
                     $node_label .= ' (' . $cat['node_id'] . ')';
                     if ($keyword) {
                         $node_label .= ' (' . $keyword . ')';
                     }
                 }
                 echo '<li class="file ext_txt"><a href="#" id="wpla_node_id_' . $node_id . '" rel="' . $node_slug . '" data-keyword="' . $keyword . '" >' . $node_label . '</a></li>' . "\n";
             }
         }
         echo "</ul>";
     }
     exit;
 }