/**
  * Attribute getter method
  * 
  * @return the title of the component
  */
 function get_title_attr()
 {
     $cat = $this->data[0];
     $name = '';
     if (!empty($cat->cat_name)) {
         $name = $cat->cat_name;
     } else {
         $name = $cat->name;
     }
     return wiziapp_makeShortString($name, 22);
 }
 /**
  * Attribute getter method
  * 
  * @return the description of the component
  */
 function get_description_attr()
 {
     $desc = $this->post->post_excerpt;
     if (empty($this->post->post_excerpt)) {
         // No need for the full processing... can be quite expensive
         //$desc = wiziapp_process_content($this->post->post_content);
         /**wiziapp_removeKnownfilters();
            $desc = apply_filters('the_content', $this->post->post_content);*/
         $desc = preg_replace('/\\[(.*?)\\]/', '', $this->post->post_content);
     }
     return wiziapp_makeShortString(trim(strip_tags($desc)), 45);
 }
function wiziapp_buildAboutScreen()
{
    $actions = array();
    $pages = get_option('wiziapp_pages');
    foreach ($pages['about'] as $aboutPage) {
        $actions[] = array('imageURL' => 'cuts_reg_gold', 'title' => "{$aboutPage}", 'actionURL' => wiziapp_buildBlogPageLink($aboutPage));
    }
    $app_name = WiziappConfig::getInstance()->app_name;
    if (strlen($app_name) > 20) {
        $app_name = wiziapp_makeShortString($app_name, 20);
    }
    $page = array('title' => $app_name, 'version' => __('version') . ' ' . WiziappConfig::getInstance()->version, 'imageURL' => WiziappConfig::getInstance()->getAppIcon(), 'aboutTitle' => __('About', 'wiziapp') . ' ' . $app_name, 'aboutContent' => WiziappConfig::getInstance()->getAppDescription(), 'actions' => array());
    $screen = wiziapp_prepareScreen($page, __(WiziappConfig::getInstance()->getScreenTitle('about'), 'wiziapp'), 'about');
    $screen['screen']['class'] = 'about_screen';
    echo json_encode($screen);
}
/**
* Will echo the li item for the tags of the current post
* No categories - no output
*/
function wiziapp_get_tags_nav()
{
    global $post;
    $tags = get_the_tags($post->ID);
    //    $max_to_show = 2;
    $count = count($tags);
    $html = '';
    if ($tags) {
        if ($count > 1) {
            $link = wiziapp_buildPostTagsLink($post->ID);
            $tag_names = $count . ' ' . __('Tags', 'wiziapp');
        } else {
            $link = wiziapp_buildTagLink($tags[key($tags)]->term_id);
            $tag_names = wiziapp_makeShortString($tags[key($tags)]->name, 18);
        }
        $tag_names = '<span class="names">: ' . $tag_names . '</span>';
        $html .= '<li><a id="wizapp_tags_footer_link" class="wiziapp_footer_links" href="' . $link . '">';
        $html .= '<div class="title-bar"></div><span class="title">' . __('Tags', 'wiziapp') . '</span>';
        /**$names = array();
           foreach($tags as $tag){;
                   $names[] = "{$tag->name}";
           }
           $tag_names = implode(', ', $names);
           $tag_names = wiziapp_makeShortString($tag_names, 30);
           if ( strpos($tag_names, '...') === FALSE ){
               if ( $count > $max_to_show ){
                   $tag_names .= '...';
               }
           }  */
        $html .= $tag_names . '</a></li>';
    }
    echo $html;
}