function add() { $input = array('username' => clear_all($_POST['username']), 'content' => clear_all($_POST['content']), 'pro_id' => intval($_GET['id'])); $this->db->insert_record($this->table, $input); $this->db->alert(COMMENT_SUCCESS); header_redirect(change_url(full_url())); }
function lists($where = '') { if ($where != '') { $where = ' && ' . $where; } $where = 'lang = ' . $_SESSION['lang'] . $where; $result = $this->db->lists($this->table, '', $where, 'position,ordering'); $i = 0; $target = ''; while ($row = $this->db->fetch_assoc($result)) { $list[$i]->menu_id = $row[$this->key]; $list[$i]->name = $row['name']; if ($row['target'] != '') { $target = 'target =' . $row['target']; } if (strpos($row['link'], '&id=') == true || strpos($row['link'], '&cha=') == true || strpos($row['link'], '&cat=') == true) { $alias = '&alias=' . seourl($row['name']); } else { $alias = ''; } $list[$i]->link = change_url($row['link'] . $alias); $list[$i]->position = $row['position']; $list[$i]->ordering = $row['ordering']; $list[$i]->alow = $row['alow']; $list[$i]->child = $row['child']; $list[$i]->target = $target; $i++; } $this->db->free_result($result); return $list; }
<td>Perks </td> <td><?php echo $card['Perks']; ?> </td> <td></td> <td></td> </tr> </table> <div class="applyOnline"> <a target="_blank" href="<?php echo $sitelink; ?> /<?php echo change_url('index.php?module=request&id=' . $card['tbl_id'] . '&alias=' . $alias); ?> " style="font-weight:bold;"> Apply online for the <?php echo $card['OfferName']; ?> </a> </div> <?php if ($card['footer_text']) { ?> <div class="border-text-footer-khongbiet">
<?php if (!defined('INCLUDED')) { die("Access Denied"); } $row = $faq->detail(); echo $template->title_content('Hỏi đáp'); ?> <div style="margin: 10px 0 10px 10px;"><span style="color: red; font-weight: bold; ">Câu hỏi:</span> <?php echo $row['question']; ?> (<?php echo $row['email']; ?> )</div> <div style="margin: 10px 0 10px 10px;"> <span style="color: blue; font-weight: bold; ">Trả lời:</span> <?php echo $row['answer']; ?> </div> <div style="color: #060299; font-weight: bold; margin: 10px 0 10px 10px;"><a href="javascript:history.back()">Quay lại</a></div> <div style="width: 100%; text-align: center;"><a class="xanhlacay" style="font-weight: bold;" href="<?php echo change_url('index.php?module=faq'); ?> ">Gửi câu hỏi khác</a></div>
?> </a> <div class="product_name"><a href="<?php echo change_url('index.php?module=' . $product->module . '&id=' . $row->pro_id . '&alias=' . $row->alias); ?> "><?php echo $row->name; ?> </a></div> <div class="product_description"> <?php echo $row->description; ?> </div> <a href="<?php echo change_url('index.php?module=' . $product->module . '&id=' . $row->pro_id . '&alias=' . $row->alias); ?> "><?php echo $template->show_detail($row->pro_id); ?> </a> </td> <?php if ($i % 3 == 0) { echo '</tr><tr>'; } $i++; } } ?> </tr>
echo $alias; ?> " > <img src="<?php echo $img; ?> " title="<?php echo $card['OfferName']; ?> " alt="<?php echo $card['OfferName']; ?> " style="border-width: 0px; width: 180px;" /></a> <a target="_blank" href="<?php echo $sitelink . "/" . change_url('index.php?module=request&id=' . $card->tbl_id . '&alias=' . $alias); ?> "> <button class="applybtn"><span>Apply Now</span> <img class="img-arrow" src="<?php echo $sitelink; ?> /images/arrowbtn.png"></button> </a> </div> <div class="details-card-text-rigth"> <span style="margin-left: -14px;font-family: Lato-Bol;">Key Feature</span> <?php
?> <tr> <td colspan="2"> <b>Danh sách câu hỏi:</b> </td> </tr> <tr> <td width="2%"> <b><?php echo $i; ?> .</b> </td> <td> <a class="faq_question" href="<?php echo change_url('index.php?module=faq&id=' . $row->faq_id . '&alias=' . seourl($row->question)); ?> "><?php echo $row->question; ?> </a> </td> </tr> <?php $i++; } echo '</table>'; } ?>
?> "><?php echo $row_news->name; ?> </a> </div> <span style="color: #747474"><?php echo substr($row_news->description, '0', '130'); ?> ...</span> <div class="dot"></div> <?php } if ($i > 4) { ?> <div class="other">- <a href="<?php echo change_url('index.php?module=' . $news->module . '&id=' . $row_news->news_id . '&alias=' . $row_news->alias); ?> "><?php echo $row_news->name; ?> </a></div> <?php } $i++; } } $j++; } echo '</td></tr></table>'; }
function count_cart() { if ($_SESSION['add_cart']) { $cart = '<a href="' . change_url('index.php?module=' . $this->module) . '">' . CART_COUNT . '<font color ="red"><b>'; $cart .= count(explode(',', $_SESSION['add_cart'])) - 1; $cart .= ' ' . PRODUCT_CART . '</b></font></a>'; return $cart; } }
$blogs = new blog(); ?> <div class="content-menu" style="min-height: 0px;"> <?php foreach ($category as $category) { $count = $blogs->lists('title', 'category_id = ' . $category->id); $n = count($count); ?> <div class="link-menu"> <div class="link-menu-img"><img src="<?php echo $sitelink; ?> /images/icon-menu-type.gif"/></div> <div class="link-menu-text"> <a href="<?php echo change_url('index.php?module=blog&type=' . $category->id . '&alias=' . $category->name); ?> "><?php echo $category->name . ' (' . $n . ')'; ?> </a> </div> </div> <?php } ?> </div>
</span></td> <td align="center"> <b><?php echo $row_config['currency1']; ?> </b> </td> </tr> <tr> <td colspan="8" align="center"> <input type="submit" value="<?php echo CART_UPDATE; ?> " /> <input type="button" onclick="window.location.href='<?php echo change_url('index.php?module=' . $order->module . '&view=payment'); ?> '" value="<?php echo CART_SEND_INFOR; ?> " /> <input type="button" onclick="window.location.href='index.php?option=logout'" value="<?php echo CART_DELETE; ?> "> <input type="hidden" name="update_quatity" value="update"> </td> </tr> <?php } else {
foreach ($blogss as $blog) { $n = 0; $row_blog_date = $blogs->lists('blog_id, publishdate', ' month(b.publishdate) = ' . $blog->month . ' and year(b.publishdate) = ' . $blog->year); $n = count($row_blog_date); ?> <div class="link-menu"> <div class="link-menu-img"><img src="<?php echo $sitelink; ?> /images/icon-menu-type.gif"/></div> <div class="link-menu-text"> <a title="<?php echo $bank->name; ?> " href="<?php echo change_url('index.php?module=blog&date=' . $blog->month . '&year=' . $blog->year . '&alias=blog-by-date'); ?> "><?php echo change_month($blog->month) . ' ' . $blog->year . ' (' . $n . ') '; ?> </a> </div> </div> <?php } ?> </div>
foreach ($blogss as $blog) { $n = 0; $row_blog_date = $blogs->lists('blog_id, publishdate', ' month(b.publishdate) = ' . $blog->month . ' and year(b.publishdate) = ' . $blog->year); $n = count($row_blog_date); ?> <div class="link-menu"> <div class="link-menu-img"><img src="<?php echo $sitelink; ?> /images/icon-menu-type.gif"/></div> <div class="link-menu-text"> <a title="<?php echo $bank->name; ?> " href="<?php echo change_url('index.php?module=advice-center&date=' . $blog->month . '&year=' . $blog->year . '&alias=advice-by-date'); ?> "><?php echo change_month($blog->month) . ' ' . $blog->year . ' (' . $n . ') '; ?> </a> </div> </div> <?php } ?> </div>
foreach ($cards as $card) { $holdcard = ""; $details = $credit_cards->detail2('OfferName,RedirectLink,alias,BigCreative,TextDetails', $card); if ($details['OfferName'] != '') { $mycount++; $img_id = $details['BigCreative']; if (intval($img_id) != 0) { $image = intval($details['BigCreative']); $row_img = $advertise->detail1($image); $img = "upload/adv/resize/" . $row_img['image']; } else { $img = $details['BigCreative']; } $holdcard .= "<div class='text_detail' style='list-style: none;text-align:center;'>"; $holdcard .= '<img src="' . $img . '" style="border-width: 0px;margin: 5px;" >'; $holdcard .= "<div class=\"text-title-Content-card-top1\"><a href=\"{$details['alias']}\" target=\"_blank\">{$details['OfferName']}</a></div> \n \n <div style=\"margin-left:6px;margin-bottom:3px;list-style: none;\">" . $details['TextDetails'] . "</div>\n \n <div style=\"margin-left: 26px;margin-bottom: -5px;\"><a title=\"Apply Now\" href=\"" . change_url('index.php?module=request&id=' . $card . '&alias=' . seourl($details['OfferName'])) . "\" target=\"_blank\"><img src=\"images/applynowdetails.gif\" width=\"140px\" height=\"40px\"/></a></div>"; } $holdcards .= $holdcards ? "</div><br><hr width='100%' style='margin-left:-0px;'>{$holdcard}" : "{$holdcard}"; } echo $holdcards ? $holdcards . "<br>" : $holdcards; ?> </div> <?php } else { ?> <div class="content-apply-text2"> <div class="detail_news"> <?php if ($row['description'] != '') { echo "<p>";
<a href="<?php echo change_url('index.php?module=' . $product->module . '&id=' . $row['pro_id'] . '&alias=' . $row['alias']); ?> "><div id="tab_1" onmousemove="change_tab(1)" id="tab_1" class="nomal"><?php echo PRODUCT_DETAIL; ?> </div></a> <!--<a href="<?php echo change_url('index.php?module=' . $product->module . '&id=' . $row['pro_id'] . '&alias=' . $row['alias']); ?> &tab=2"><div onmousemove="change_tab(2)" id="tab_2" class="nomal"><?php echo COMMENT; ?> </div></a>--> <a href="<?php echo change_url('index.php?module=' . $product->module . '&id=' . $row['pro_id'] . '&alias=' . $row['alias']); ?> &tab=3"><div onmousemove="change_tab(3)" id="tab_3" class="nomal"><?php echo PRODUCT_OTHER; ?> </div></a> </div> <div id="tab_detail"> <?php if ($_GET['tab']) { $tab = intval($_GET['tab']); } else { $tab = 1; } if ($tab == 2) { include_once 'module/comment/product.php';
?> </div> <div class="body"><?php echo $row->body; ?> </div> <div class="add_view_comment"> <img src="images/comments_icon.gif"/> <a href="<?php echo change_url('index.php?module=blog&id=' . $row->blog_id . '&alias= blog'); ?> ">Add comment (<?php echo $n; ?> )</a> <a href="<?php echo change_url('index.php?module=blog&id=' . $row->blog_id . '&alias= blog'); ?> ">View comment</a> </div> </div> </div> <div class="border-content-card-bottom <?php echo $extraie3; ?> "></div> </div> </div> <?php