<div class="panel-body"> <?php foreach ($this->topicss as $topic) { ?> <div class="col-md-3 col-sm-6 col-xs-12"> <ul class="list-unstyled" style="line-height:30px;"> <li><a href="<?php echo get_url($this->database, "topic", $topic['topic_id'], $topic['topic_slug']); ?> "><?php echo $topic['topic_name']; ?> (<?php echo get_topic_poems($this->database, $topic['topic_id'], array("ONLYCOUNT" => true)); ?> )</a></li> </ul> </div> <?php } ?> </div> <?php } else { ?> <div class="alert-message alert-message-danger" style="margin-right: 10px; margin-left: 10px;">
$topic_poems_info = array(); //get poems information for each poem received foreach ($get_topic_poems['data'] as $poem_id) { if (check_poem($database, $poem_id)) { $topic_poems_info[] = get_poem($database, $poem_id); } } } $tpl->topic_poems_info = $topic_poems_info; //--get all topics and count poem of topic--// $get_sidebar_topics = all_topic($database); //--count sidebar topics poems--// if (!empty($get_sidebar_topics)) { foreach ($get_sidebar_topics as $key => $sidebar_topic) { $sidebar_topic_id = $sidebar_topic['topic_id']; $get_sidebar_topics[$key]['poems_count'] = get_topic_poems($database, $sidebar_topic_id, array("ONLYCOUNT" => TRUE)); } } $tpl->sidebar_topics = $get_sidebar_topics; // Send SEO Data if (!$get_topic_info['seo_title']) { $tpl->page_title = $get_topic_info['topic_name']; } else { $tpl->page_title = $get_topic_info['seo_title']; } if (!$get_topic_info['seo_description']) { $tpl->page_description = site_seo_description; } else { $tpl->page_description = $get_topic_info['seo_description']; } if (!$get_topic_info['seo_keywords']) {