exit; } return array(CONTROLLER_STATUS_OK, fn_url()); } if ($mode == 'delete_post' && defined('AJAX_REQUEST')) { db_query("DELETE FROM ?:discussion_messages WHERE post_id = ?i", $_REQUEST['post_id']); db_query("DELETE FROM ?:discussion_rating WHERE post_id = ?i", $_REQUEST['post_id']); db_query("DELETE FROM ?:discussion_posts WHERE post_id = ?i", $_REQUEST['post_id']); return array(CONTROLLER_STATUS_OK, fn_url()); } return; } // No action for vendor at the index if (Registry::get('runtime.company_id') && fn_allowed_for('MULTIVENDOR')) { return; } $latest_posts = db_get_array("SELECT a.post_id, a.ip_address, a.status, a.timestamp, b.object_id, b.object_type as object_type, b.type as type, a.name, c.message, d.rating_value " . "FROM ?:discussion_posts as a INNER JOIN ?:discussion as b ON a.thread_id = b.thread_id ?p " . "LEFT JOIN ?:discussion_messages as c ON a.post_id = c.post_id LEFT JOIN ?:discussion_rating as d ON a.post_id = d.post_id " . "ORDER BY a.timestamp DESC LIMIT 5", fn_get_discussion_company_condition('b.company_id')); if (!empty($latest_posts)) { foreach ($latest_posts as $k => $v) { $latest_posts[$k]['ip_address'] = fn_ip_from_db($v['ip_address']); $latest_posts[$k]['object_data'] = fn_get_discussion_object_data($v['object_id'], $v['object_type'], DESCR_SL); $latest_posts[$k]['rating'] = fn_get_discussion_rating($v['rating_value']); } } Registry::get('view')->assign('discussion_objects', fn_get_discussion_objects()); Registry::get('view')->assign('latest_posts', $latest_posts); if ($mode == 'delete_post' && defined('AJAX_REQUEST')) { // FIXME - bad style Registry::get('view')->display('addons/discussion/views/index/components/dashboard.tpl'); exit; }
function content_55ccec9fd41274_29204611($_smarty_tpl) { if (!is_callable('smarty_function_cycle')) { include '/home/coriolan/public_html/lead/app/lib/other/smarty/plugins/function.cycle.php'; } if (!is_callable('smarty_modifier_date_format')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/modifier.date_format.php'; } if (!is_callable('smarty_function_set_id')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/function.set_id.php'; } fn_preload_lang_vars(array('write_your_review', 'write_your_review')); if ($_smarty_tpl->tpl_vars['runtime']->value['customization_mode']['design'] == "Y" && @constant('AREA') == "C") { $_smarty_tpl->_capture_stack[0][] = array("template_content", null, null); ob_start(); if ($_smarty_tpl->tpl_vars['_REQUEST']->value['dispatch'] == 'products.view') { ?> <?php $_smarty_tpl->tpl_vars["discussion"] = new Smarty_variable(fn_get_discussion($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value, true, $_REQUEST), null, 0); ?> <?php $_smarty_tpl->tpl_vars["posts"] = new Smarty_variable($_smarty_tpl->tpl_vars['discussion']->value['posts'], null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value && $_smarty_tpl->tpl_vars['discussion']->value['type'] != "D") { ?> <style> div.review_post_images{ display: block; } div.review_post_image{ display: inline-block; padding: 5px; } div.review_post_image > img{ max-width: 150px; } </style> <div id="content_review_attributes"> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <p> </p> <?php $_smarty_tpl->_capture_stack[0][] = array("content", null, null); ob_start(); ?> <?php echo $_smarty_tpl->getSubTemplate("common/subheader.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('title' => $_smarty_tpl->tpl_vars['title']->value), 0); ?> <?php } else { ?> <h2 class="reviews-title"><?php echo $_smarty_tpl->__('customer_reviews'); ?> </h2> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['object_type'] == 'E') { ?> <?php $_smarty_tpl->tpl_vars["posts"] = new Smarty_variable(fn_get_likes(fn_get_review_posts(0, $_REQUEST['page'])), null, 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["posts"] = new Smarty_variable(fn_get_likes(fn_get_review_posts($_smarty_tpl->tpl_vars['discussion']->value['thread_id'], $_REQUEST['page'])), null, 0); ?> <?php } ?> <?php $_smarty_tpl->tpl_vars["attributes"] = new Smarty_variable(fn_get_review_attributes_work($_smarty_tpl->tpl_vars['object_id']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['object_type']->value == 'P' && $_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['discussion']->value['thread_id']), null, 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['discussion']->value['thread_id'], true), null, 0); ?> <?php } ?> <?php if (!$_smarty_tpl->tpl_vars['ratings']->value || $_smarty_tpl->tpl_vars['ratings']->value['average'] == 0.0 && !$_smarty_tpl->tpl_vars['ratings']->value['rating']) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['discussion']->value['thread_id'], true), null, 0); ?> <?php } ?> <?php $_smarty_tpl->tpl_vars["posts_count"] = new Smarty_variable(fn_get_review_posts_count($_smarty_tpl->tpl_vars['discussion']->value['thread_id']), null, 0); ?> <?php if (($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") && $_smarty_tpl->tpl_vars['ratings']->value) { ?> <div> <div class="global-average-rating"> <h3><?php echo $_smarty_tpl->__('average_rating'); ?> </h3> <p><?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average']), 'mode' => 'big'), 0); ?> </p> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ratings']->value['count'], ENT_QUOTES, 'UTF-8'); ?> <?php echo $_smarty_tpl->__('reviews'); ?> </div> <div class="global-attribute-rating"> <table cellpadding="0" cellspacing="0" class="ga-rating"> <?php $_smarty_tpl->tpl_vars["attribute"] = new Smarty_Variable(); $_smarty_tpl->tpl_vars["attribute"]->_loop = false; $_from = $_smarty_tpl->tpl_vars['attributes']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars["attribute"]->key => $_smarty_tpl->tpl_vars["attribute"]->value) { $_smarty_tpl->tpl_vars["attribute"]->_loop = true; ?> <tr> <td class="right"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['attribute']->value['attr_name'], ENT_QUOTES, 'UTF-8'); ?> = </td> <td class="left"> <?php $_smarty_tpl->tpl_vars["attr_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['attribute']->value['attr_id'], null, 0); ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_attr'][$_smarty_tpl->tpl_vars['attr_id']->value]['value'])), 0); ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ratings']->value['average_by_attr'][$_smarty_tpl->tpl_vars['attr_id']->value]['percent'], ENT_QUOTES, 'UTF-8'); ?> </td> </tr> <?php } ?> </table> </div> </div> <?php } ?> <div class="clearfix" style="padding-top: 20px;"></div> <?php if (strpos("CRB", $_smarty_tpl->tpl_vars['discussion']->value['type']) !== false) { ?> <div class="buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => __("write_your_review"), 'but_role' => "submit", 'but_target_id' => "new_extended_post_dialog", 'but_meta' => "ty-btn__secondary ty-btn cm-dialog-opener cm-dialog-auto-size", 'data_ca_view_id' => time()), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } ?> <div class="sort-review-block"> <label for="sort_review" class="sort-review-label"><?php echo $_smarty_tpl->__('sort_by'); ?> </label> <select id="sort_review" name="sort_review" onchange="$.ceAjax('request', fn_url(this.value), <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> result_ids: 'content_review_attributes,attributes_head'<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> );"> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=MH&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'MH' || !$_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review']) { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('most_helpful_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=HR&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'HR') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('highest_rating_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=LR&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'LR') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('lowest_rating_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=NW&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'NW') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('newest_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=OD&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'OD') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('oldest_first'); ?> </option> </select> </div> <?php if ($_smarty_tpl->tpl_vars['posts']->value) { ?> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value), 0); ?> <?php $_smarty_tpl->tpl_vars["escaped_current_url"] = new Smarty_variable(rawurlencode($_smarty_tpl->tpl_vars['config']->value['current_url']), null, 0); ?> <table cellpadding="0" cellspacing="0" class="posts-table"> <?php $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['posts']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <tr class="posts<?php echo smarty_function_cycle(array('values' => ", manage-post"), $_smarty_tpl); ?> clear-both" id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <td class="r-legend"> <p class="r-author"><?php echo htmlspecialchars(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8', true), ENT_QUOTES, 'UTF-8'); ?> </p> <p class="r-date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format'] . ", " . (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['time_format']), ENT_QUOTES, 'UTF-8'); ?> </p> <p class="r-user-age"> <?php echo $_smarty_tpl->__('age_group'); ?> : <?php if ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 1) { echo $_smarty_tpl->__('24&under'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 2) { echo $_smarty_tpl->__('between25and34'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 3) { echo $_smarty_tpl->__('between35and44'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 4) { echo $_smarty_tpl->__('between45and54'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 5) { echo $_smarty_tpl->__('between55and64'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 6) { echo $_smarty_tpl->__('65andafter'); ?> <?php } ?> </p> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <table cellpadding="0" cellspacing="0" class="ga-rating"> <?php $_smarty_tpl->tpl_vars["post_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['post']->value['post_id'], null, 0); ?> <?php $_smarty_tpl->tpl_vars["attribute"] = new Smarty_Variable(); $_smarty_tpl->tpl_vars["attribute"]->_loop = false; $_from = $_smarty_tpl->tpl_vars['attributes']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars["attribute"]->key => $_smarty_tpl->tpl_vars["attribute"]->value) { $_smarty_tpl->tpl_vars["attribute"]->_loop = true; ?> <tr> <td class="right"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['attribute']->value['attr_name'], ENT_QUOTES, 'UTF-8'); ?> = </td> <td class="left" style="margin-top: 2px;"> <?php $_smarty_tpl->tpl_vars["attr_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['attribute']->value['attr_id'], null, 0); ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['rating'][$_smarty_tpl->tpl_vars['post_id']->value][$_smarty_tpl->tpl_vars['attr_id']->value])), 0); ?> </td> </tr> <?php } ?> </table> <?php } ?> <?php } ?> </td> <td class="r-message"> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] != "C") { ?> <div class="r-subject"> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["rates"] = new Smarty_variable(fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value]), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['FULL']['index']] != 0 || $_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['PART']['index']] != 0) { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value])), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message_title'], ENT_QUOTES, 'UTF-8'); ?> </div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php echo nl2br(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message'], ENT_QUOTES, 'UTF-8', true)); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['post']->value['image1'] || $_smarty_tpl->tpl_vars['post']->value['image2']) { ?> <div class="review_post_images"> <?php if ($_smarty_tpl->tpl_vars['post']->value['image1']) { ?> <div class="review_post_image"><img class="img_review_post_image" src="/images/review_img/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['image1'], ENT_QUOTES, 'UTF-8'); ?> " alt="img" border="0"></div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['post']->value['image1']) { ?> <div class="review_post_image"><img class="img_review_post_image" src="/images/review_img/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['image2'], ENT_QUOTES, 'UTF-8'); ?> " alt="img" border="0"></div> <?php } ?> </div> <?php } ?> <div class="r-likes"> <div class="is-useful float-left"><?php echo $_smarty_tpl->__('found_useful'); ?> : <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['yes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['yes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong> <?php echo $_smarty_tpl->__('out_of'); ?> <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['votes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['votes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong></div> <?php echo $_smarty_tpl->__('was_helpful'); ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=1&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=0&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php } ?> </div> </td> </tr> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['object_type']->value == "E" && $_smarty_tpl->tpl_vars['current_post_id']->value) { ?> <script type="text/javascript"> //<![CDATA[ $(document).ready(function()<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> if ($('#post_' + <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['current_post_id']->value, ENT_QUOTES, 'UTF-8'); ?> ).length) <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> jQuery.scrollToElm($('#post_' + <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['current_post_id']->value, ENT_QUOTES, 'UTF-8'); ?> )); <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> ); //]]> </script> <?php } ?> </table> <script type="text/javascript"> //<![CDATA[ $(document).ready(function()<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> var userCheckForReview = true; var user_product_ordered = 1; $('a#opener_new_post').click(function(){ var checkout_est_url = fn_url('review_attributes.check_user&object_id=<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['object_id']->value, ENT_QUOTES, 'UTF-8'); ?> &is_ajax=1'); var ajax_exectute = $.ajax({ url: checkout_est_url, dataType:'html', async:false, cache: false, beforeSend: function(xhr) { xhr.withCredentials = true; }, }); ajax_exectute.done(function(data) { if(typeof data ==="string" ){ data = JSON.parse(data); } if(data.text=='notordered'){ user_product_ordered = 0; }else if(data.text=='logedout'){ window.location.href = fn_url('auth.login_form&return_url=<?php echo htmlspecialchars(fn_url((string) $_smarty_tpl->tpl_vars['config']->value['current_url']), ENT_QUOTES, 'UTF-8'); ?> '); userCheckForReview = false; }else if(data.text=='allchecked'){ user_product_ordered = 1; userCheckForReview = true; }else { user_product_ordered = 1; userCheckForReview = true; } }); $('form#add_extended_post_form').trigger('reset'); $('div.ls_review_image_container2').remove(); $('img#ls_uploadPreview').attr("src","/images/review_img/review_no_image.jpg"); $('input#user_product_ordered').val(user_product_ordered); return userCheckForReview; }); <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> ); //]]> </script> <div class="div_show_more_posts_action" style="text-align:center"> <input type="hidden" value="2" id="input_show_more_posts_action" /> <input type="hidden" value="<?php if ($_REQUEST['sort_review']) { echo htmlspecialchars($_REQUEST['sort_review'], ENT_QUOTES, 'UTF-8'); } else { ?> MH<?php } ?> " id="input_sort_review" /> <?php if ($_smarty_tpl->tpl_vars['posts_count']->value > count($_smarty_tpl->tpl_vars['posts']->value)) { ?> <a onclick="ls_show_more_posts(<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['object_id']->value, ENT_QUOTES, 'UTF-8'); ?> ,'<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['object_type']->value, ENT_QUOTES, 'UTF-8'); ?> ');return false;" id="show_more_posts"><?php echo $_smarty_tpl->__('show_more_posts'); ?> </a> <?php } ?> </div> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value), 0); ?> <?php } else { ?> <p class="no-items ty-no-items"><?php echo $_smarty_tpl->__('no_posts_found'); ?> </p> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php echo $_smarty_tpl->getSubTemplate("common/group.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('content' => Smarty::$_smarty_vars['capture']['content']), 0); ?> <?php } else { ?> <?php $_smarty_tpl->_capture_stack[0][] = array("mainbox_title", null, null); ob_start(); echo htmlspecialchars($_smarty_tpl->tpl_vars['title']->value, ENT_QUOTES, 'UTF-8'); list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php } ?> <!--content_review_attributes--></div> <?php } } list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } if (trim(Smarty::$_smarty_vars['capture']['template_content'])) { if ($_smarty_tpl->tpl_vars['auth']->value['area'] == "A") { ?> <span class="cm-template-box template-box" data-ca-te-template="addons/altteam_review_attributes/views/discussion/view.tpl" id="<?php echo smarty_function_set_id(array('name' => "addons/altteam_review_attributes/views/discussion/view.tpl"), $_smarty_tpl); ?> "><div class="cm-template-icon icon-edit ty-icon-edit hidden"></div><?php echo Smarty::$_smarty_vars['capture']['template_content']; ?> <!--[/tpl_id]--></span><?php } else { echo Smarty::$_smarty_vars['capture']['template_content']; } } } else { if ($_smarty_tpl->tpl_vars['_REQUEST']->value['dispatch'] == 'products.view') { ?> <?php $_smarty_tpl->tpl_vars["discussion"] = new Smarty_variable(fn_get_discussion($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value, true, $_REQUEST), null, 0); ?> <?php $_smarty_tpl->tpl_vars["posts"] = new Smarty_variable($_smarty_tpl->tpl_vars['discussion']->value['posts'], null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value && $_smarty_tpl->tpl_vars['discussion']->value['type'] != "D") { ?> <style> div.review_post_images{ display: block; } div.review_post_image{ display: inline-block; padding: 5px; } div.review_post_image > img{ max-width: 150px; } </style> <div id="content_review_attributes"> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <p> </p> <?php $_smarty_tpl->_capture_stack[0][] = array("content", null, null); ob_start(); ?> <?php echo $_smarty_tpl->getSubTemplate("common/subheader.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('title' => $_smarty_tpl->tpl_vars['title']->value), 0); ?> <?php } else { ?> <h2 class="reviews-title"><?php echo $_smarty_tpl->__('customer_reviews'); ?> </h2> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['object_type'] == 'E') { ?> <?php $_smarty_tpl->tpl_vars["posts"] = new Smarty_variable(fn_get_likes(fn_get_review_posts(0, $_REQUEST['page'])), null, 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["posts"] = new Smarty_variable(fn_get_likes(fn_get_review_posts($_smarty_tpl->tpl_vars['discussion']->value['thread_id'], $_REQUEST['page'])), null, 0); ?> <?php } ?> <?php $_smarty_tpl->tpl_vars["attributes"] = new Smarty_variable(fn_get_review_attributes_work($_smarty_tpl->tpl_vars['object_id']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['object_type']->value == 'P' && $_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['discussion']->value['thread_id']), null, 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['discussion']->value['thread_id'], true), null, 0); ?> <?php } ?> <?php if (!$_smarty_tpl->tpl_vars['ratings']->value || $_smarty_tpl->tpl_vars['ratings']->value['average'] == 0.0 && !$_smarty_tpl->tpl_vars['ratings']->value['rating']) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['discussion']->value['thread_id'], true), null, 0); ?> <?php } ?> <?php $_smarty_tpl->tpl_vars["posts_count"] = new Smarty_variable(fn_get_review_posts_count($_smarty_tpl->tpl_vars['discussion']->value['thread_id']), null, 0); ?> <?php if (($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") && $_smarty_tpl->tpl_vars['ratings']->value) { ?> <div> <div class="global-average-rating"> <h3><?php echo $_smarty_tpl->__('average_rating'); ?> </h3> <p><?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average']), 'mode' => 'big'), 0); ?> </p> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ratings']->value['count'], ENT_QUOTES, 'UTF-8'); ?> <?php echo $_smarty_tpl->__('reviews'); ?> </div> <div class="global-attribute-rating"> <table cellpadding="0" cellspacing="0" class="ga-rating"> <?php $_smarty_tpl->tpl_vars["attribute"] = new Smarty_Variable(); $_smarty_tpl->tpl_vars["attribute"]->_loop = false; $_from = $_smarty_tpl->tpl_vars['attributes']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars["attribute"]->key => $_smarty_tpl->tpl_vars["attribute"]->value) { $_smarty_tpl->tpl_vars["attribute"]->_loop = true; ?> <tr> <td class="right"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['attribute']->value['attr_name'], ENT_QUOTES, 'UTF-8'); ?> = </td> <td class="left"> <?php $_smarty_tpl->tpl_vars["attr_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['attribute']->value['attr_id'], null, 0); ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_attr'][$_smarty_tpl->tpl_vars['attr_id']->value]['value'])), 0); ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ratings']->value['average_by_attr'][$_smarty_tpl->tpl_vars['attr_id']->value]['percent'], ENT_QUOTES, 'UTF-8'); ?> </td> </tr> <?php } ?> </table> </div> </div> <?php } ?> <div class="clearfix" style="padding-top: 20px;"></div> <?php if (strpos("CRB", $_smarty_tpl->tpl_vars['discussion']->value['type']) !== false) { ?> <div class="buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => __("write_your_review"), 'but_role' => "submit", 'but_target_id' => "new_extended_post_dialog", 'but_meta' => "ty-btn__secondary ty-btn cm-dialog-opener cm-dialog-auto-size", 'data_ca_view_id' => time()), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } ?> <div class="sort-review-block"> <label for="sort_review" class="sort-review-label"><?php echo $_smarty_tpl->__('sort_by'); ?> </label> <select id="sort_review" name="sort_review" onchange="$.ceAjax('request', fn_url(this.value), <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> result_ids: 'content_review_attributes,attributes_head'<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> );"> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=MH&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'MH' || !$_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review']) { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('most_helpful_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=HR&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'HR') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('highest_rating_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=LR&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'LR') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('lowest_rating_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=NW&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'NW') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('newest_first'); ?> </option> <option value="<?php echo htmlspecialchars(fn_url("products.view&product_id=" . (string) $_smarty_tpl->tpl_vars['object_id']->value . "&sort_review=OD&selected_section=review_attributes"), ENT_QUOTES, 'UTF-8'); ?> " <?php if ($_smarty_tpl->tpl_vars['_REQUEST']->value['sort_review'] == 'OD') { ?> selected="selected"<?php } ?> ><?php echo $_smarty_tpl->__('oldest_first'); ?> </option> </select> </div> <?php if ($_smarty_tpl->tpl_vars['posts']->value) { ?> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value), 0); ?> <?php $_smarty_tpl->tpl_vars["escaped_current_url"] = new Smarty_variable(rawurlencode($_smarty_tpl->tpl_vars['config']->value['current_url']), null, 0); ?> <table cellpadding="0" cellspacing="0" class="posts-table"> <?php $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['posts']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <tr class="posts<?php echo smarty_function_cycle(array('values' => ", manage-post"), $_smarty_tpl); ?> clear-both" id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <td class="r-legend"> <p class="r-author"><?php echo htmlspecialchars(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8', true), ENT_QUOTES, 'UTF-8'); ?> </p> <p class="r-date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format'] . ", " . (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['time_format']), ENT_QUOTES, 'UTF-8'); ?> </p> <p class="r-user-age"> <?php echo $_smarty_tpl->__('age_group'); ?> : <?php if ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 1) { echo $_smarty_tpl->__('24&under'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 2) { echo $_smarty_tpl->__('between25and34'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 3) { echo $_smarty_tpl->__('between35and44'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 4) { echo $_smarty_tpl->__('between45and54'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 5) { echo $_smarty_tpl->__('between55and64'); ?> <?php } elseif ($_smarty_tpl->tpl_vars['post']->value['user_age'] == 6) { echo $_smarty_tpl->__('65andafter'); ?> <?php } ?> </p> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <table cellpadding="0" cellspacing="0" class="ga-rating"> <?php $_smarty_tpl->tpl_vars["post_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['post']->value['post_id'], null, 0); ?> <?php $_smarty_tpl->tpl_vars["attribute"] = new Smarty_Variable(); $_smarty_tpl->tpl_vars["attribute"]->_loop = false; $_from = $_smarty_tpl->tpl_vars['attributes']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars["attribute"]->key => $_smarty_tpl->tpl_vars["attribute"]->value) { $_smarty_tpl->tpl_vars["attribute"]->_loop = true; ?> <tr> <td class="right"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['attribute']->value['attr_name'], ENT_QUOTES, 'UTF-8'); ?> = </td> <td class="left" style="margin-top: 2px;"> <?php $_smarty_tpl->tpl_vars["attr_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['attribute']->value['attr_id'], null, 0); ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['rating'][$_smarty_tpl->tpl_vars['post_id']->value][$_smarty_tpl->tpl_vars['attr_id']->value])), 0); ?> </td> </tr> <?php } ?> </table> <?php } ?> <?php } ?> </td> <td class="r-message"> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] != "C") { ?> <div class="r-subject"> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["rates"] = new Smarty_variable(fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value]), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['FULL']['index']] != 0 || $_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['PART']['index']] != 0) { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value])), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message_title'], ENT_QUOTES, 'UTF-8'); ?> </div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php echo nl2br(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message'], ENT_QUOTES, 'UTF-8', true)); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['post']->value['image1'] || $_smarty_tpl->tpl_vars['post']->value['image2']) { ?> <div class="review_post_images"> <?php if ($_smarty_tpl->tpl_vars['post']->value['image1']) { ?> <div class="review_post_image"><img class="img_review_post_image" src="/images/review_img/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['image1'], ENT_QUOTES, 'UTF-8'); ?> " alt="img" border="0"></div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['post']->value['image1']) { ?> <div class="review_post_image"><img class="img_review_post_image" src="/images/review_img/<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['image2'], ENT_QUOTES, 'UTF-8'); ?> " alt="img" border="0"></div> <?php } ?> </div> <?php } ?> <div class="r-likes"> <div class="is-useful float-left"><?php echo $_smarty_tpl->__('found_useful'); ?> : <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['yes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['yes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong> <?php echo $_smarty_tpl->__('out_of'); ?> <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['votes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['votes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong></div> <?php echo $_smarty_tpl->__('was_helpful'); ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=1&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=0&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php } ?> </div> </td> </tr> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['object_type']->value == "E" && $_smarty_tpl->tpl_vars['current_post_id']->value) { ?> <script type="text/javascript"> //<![CDATA[ $(document).ready(function()<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> if ($('#post_' + <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['current_post_id']->value, ENT_QUOTES, 'UTF-8'); ?> ).length) <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> jQuery.scrollToElm($('#post_' + <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['current_post_id']->value, ENT_QUOTES, 'UTF-8'); ?> )); <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> ); //]]> </script> <?php } ?> </table> <script type="text/javascript"> //<![CDATA[ $(document).ready(function()<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['ldelim']->value, ENT_QUOTES, 'UTF-8'); ?> var userCheckForReview = true; var user_product_ordered = 1; $('a#opener_new_post').click(function(){ var checkout_est_url = fn_url('review_attributes.check_user&object_id=<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['object_id']->value, ENT_QUOTES, 'UTF-8'); ?> &is_ajax=1'); var ajax_exectute = $.ajax({ url: checkout_est_url, dataType:'html', async:false, cache: false, beforeSend: function(xhr) { xhr.withCredentials = true; }, }); ajax_exectute.done(function(data) { if(typeof data ==="string" ){ data = JSON.parse(data); } if(data.text=='notordered'){ user_product_ordered = 0; }else if(data.text=='logedout'){ window.location.href = fn_url('auth.login_form&return_url=<?php echo htmlspecialchars(fn_url((string) $_smarty_tpl->tpl_vars['config']->value['current_url']), ENT_QUOTES, 'UTF-8'); ?> '); userCheckForReview = false; }else if(data.text=='allchecked'){ user_product_ordered = 1; userCheckForReview = true; }else { user_product_ordered = 1; userCheckForReview = true; } }); $('form#add_extended_post_form').trigger('reset'); $('div.ls_review_image_container2').remove(); $('img#ls_uploadPreview').attr("src","/images/review_img/review_no_image.jpg"); $('input#user_product_ordered').val(user_product_ordered); return userCheckForReview; }); <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['rdelim']->value, ENT_QUOTES, 'UTF-8'); ?> ); //]]> </script> <div class="div_show_more_posts_action" style="text-align:center"> <input type="hidden" value="2" id="input_show_more_posts_action" /> <input type="hidden" value="<?php if ($_REQUEST['sort_review']) { echo htmlspecialchars($_REQUEST['sort_review'], ENT_QUOTES, 'UTF-8'); } else { ?> MH<?php } ?> " id="input_sort_review" /> <?php if ($_smarty_tpl->tpl_vars['posts_count']->value > count($_smarty_tpl->tpl_vars['posts']->value)) { ?> <a onclick="ls_show_more_posts(<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['object_id']->value, ENT_QUOTES, 'UTF-8'); ?> ,'<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['object_type']->value, ENT_QUOTES, 'UTF-8'); ?> ');return false;" id="show_more_posts"><?php echo $_smarty_tpl->__('show_more_posts'); ?> </a> <?php } ?> </div> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value), 0); ?> <?php } else { ?> <p class="no-items ty-no-items"><?php echo $_smarty_tpl->__('no_posts_found'); ?> </p> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php echo $_smarty_tpl->getSubTemplate("common/group.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('content' => Smarty::$_smarty_vars['capture']['content']), 0); ?> <?php } else { ?> <?php $_smarty_tpl->_capture_stack[0][] = array("mainbox_title", null, null); ob_start(); echo htmlspecialchars($_smarty_tpl->tpl_vars['title']->value, ENT_QUOTES, 'UTF-8'); list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php } ?> <!--content_review_attributes--></div> <?php } } } }
function content_55e61dcc9a2ac0_81934437($_smarty_tpl) { if (!is_callable('smarty_block_hook')) { include '/var/www/html/market/app/functions/smarty_plugins/block.hook.php'; } if (!is_callable('smarty_function_cycle')) { include '/var/www/html/market/app/lib/vendor/smarty/smarty/libs/plugins/function.cycle.php'; } if (!is_callable('smarty_modifier_truncate')) { include '/var/www/html/market/app/functions/smarty_plugins/modifier.truncate.php'; } if (!is_callable('smarty_modifier_date_format')) { include '/var/www/html/market/app/functions/smarty_plugins/modifier.date_format.php'; } if (!is_callable('smarty_function_set_id')) { include '/var/www/html/market/app/functions/smarty_plugins/function.set_id.php'; } if ($_smarty_tpl->tpl_vars['runtime']->value['customization_mode']['design'] == "Y" && @constant('AREA') == "C") { $_smarty_tpl->_capture_stack[0][] = array("template_content", null, null); ob_start(); ?> <?php $_smarty_tpl->tpl_vars["discussion"] = new Smarty_variable(fn_get_discussion(0, "E", true, $_smarty_tpl->tpl_vars['block']->value['properties']), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value && $_smarty_tpl->tpl_vars['discussion']->value['type'] != "D" && $_smarty_tpl->tpl_vars['discussion']->value['posts']) { ?> <?php $_smarty_tpl->tpl_vars["obj_prefix"] = new Smarty_variable((string) $_smarty_tpl->tpl_vars['block']->value['block_id'] . "000", null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['block']->value['properties']['outside_navigation'] == "Y") { ?> <div class="owl-theme ty-owl-controls"> <div class="owl-controls clickable owl-controls-outside" id="owl_outside_nav_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['block_id'], ENT_QUOTES, 'UTF-8'); ?> "> <div class="owl-buttons"> <div id="owl_prev_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['obj_prefix']->value, ENT_QUOTES, 'UTF-8'); ?> " class="owl-prev"><i class="ty-icon-left-open-thin"></i></div> <div id="owl_next_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['obj_prefix']->value, ENT_QUOTES, 'UTF-8'); ?> " class="owl-next"><i class="ty-icon-right-open-thin"></i></div> </div> </div> </div> <?php } ?> <div class="ty-mb-l"> <div class="ty-scroller-discussion-list"> <div id="scroll_list_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['block_id'], ENT_QUOTES, 'UTF-8'); ?> " class="owl-carousel ty-scroller-list"> <?php $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['discussion']->value['posts']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <div class="ty-discussion-post__content ty-scroller-discussion-list__item"> <?php $_smarty_tpl->smarty->_tag_stack[] = array('hook', array('name' => "discussion:items_list_row")); $_block_repeat = true; echo smarty_block_hook(array('name' => "discussion:items_list_row"), null, $_smarty_tpl, $_block_repeat); while ($_block_repeat) { ob_start(); ?> <a href="<?php echo htmlspecialchars(fn_url("discussion.view?thread_id=" . (string) $_smarty_tpl->tpl_vars['discussion']->value['thread_id'] . "&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), ENT_QUOTES, 'UTF-8'); ?> #post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <div class="ty-discussion-post <?php echo smarty_function_cycle(array('values' => ", ty-discussion-post_even"), $_smarty_tpl); ?> " id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <div class="ty-discussion-post__message"><?php echo nl2br(smarty_modifier_truncate($_smarty_tpl->tpl_vars['post']->value['message'], 100)); ?> </div> <?php } ?> <span class="ty-caret-bottom"><span class="ty-caret-outer"></span><span class="ty-caret-inner"></span></span> </div> </a> <span class="ty-discussion-post__author"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8'); ?> </span> <span class="ty-discussion-post__date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format']), ENT_QUOTES, 'UTF-8'); ?> </span> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B" && $_smarty_tpl->tpl_vars['post']->value['rating_value'] > 0) { ?> <div class="clearfix ty-discussion-post__rating"> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> </div> <?php } ?> <?php $_block_content = ob_get_clean(); $_block_repeat = false; echo smarty_block_hook(array('name' => "discussion:items_list_row"), $_block_content, $_smarty_tpl, $_block_repeat); } array_pop($_smarty_tpl->smarty->_tag_stack); ?> </div> <?php } ?> </div> </div> </div> <?php echo $_smarty_tpl->getSubTemplate("common/scroller_init_with_quantity.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('prev_selector' => "#owl_prev_" . (string) $_smarty_tpl->tpl_vars['obj_prefix']->value, 'next_selector' => "#owl_next_" . (string) $_smarty_tpl->tpl_vars['obj_prefix']->value), 0); ?> <?php } list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } if (trim(Smarty::$_smarty_vars['capture']['template_content'])) { if ($_smarty_tpl->tpl_vars['auth']->value['area'] == "A") { ?> <span class="cm-template-box template-box" data-ca-te-template="addons/discussion/blocks/testimonials.tpl" id="<?php echo smarty_function_set_id(array('name' => "addons/discussion/blocks/testimonials.tpl"), $_smarty_tpl); ?> "><div class="cm-template-icon icon-edit ty-icon-edit hidden"></div><?php echo Smarty::$_smarty_vars['capture']['template_content']; ?> <!--[/tpl_id]--></span><?php } else { echo Smarty::$_smarty_vars['capture']['template_content']; } } } else { ?> <?php $_smarty_tpl->tpl_vars["discussion"] = new Smarty_variable(fn_get_discussion(0, "E", true, $_smarty_tpl->tpl_vars['block']->value['properties']), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value && $_smarty_tpl->tpl_vars['discussion']->value['type'] != "D" && $_smarty_tpl->tpl_vars['discussion']->value['posts']) { ?> <?php $_smarty_tpl->tpl_vars["obj_prefix"] = new Smarty_variable((string) $_smarty_tpl->tpl_vars['block']->value['block_id'] . "000", null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['block']->value['properties']['outside_navigation'] == "Y") { ?> <div class="owl-theme ty-owl-controls"> <div class="owl-controls clickable owl-controls-outside" id="owl_outside_nav_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['block_id'], ENT_QUOTES, 'UTF-8'); ?> "> <div class="owl-buttons"> <div id="owl_prev_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['obj_prefix']->value, ENT_QUOTES, 'UTF-8'); ?> " class="owl-prev"><i class="ty-icon-left-open-thin"></i></div> <div id="owl_next_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['obj_prefix']->value, ENT_QUOTES, 'UTF-8'); ?> " class="owl-next"><i class="ty-icon-right-open-thin"></i></div> </div> </div> </div> <?php } ?> <div class="ty-mb-l"> <div class="ty-scroller-discussion-list"> <div id="scroll_list_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['block_id'], ENT_QUOTES, 'UTF-8'); ?> " class="owl-carousel ty-scroller-list"> <?php $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['discussion']->value['posts']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <div class="ty-discussion-post__content ty-scroller-discussion-list__item"> <?php $_smarty_tpl->smarty->_tag_stack[] = array('hook', array('name' => "discussion:items_list_row")); $_block_repeat = true; echo smarty_block_hook(array('name' => "discussion:items_list_row"), null, $_smarty_tpl, $_block_repeat); while ($_block_repeat) { ob_start(); ?> <a href="<?php echo htmlspecialchars(fn_url("discussion.view?thread_id=" . (string) $_smarty_tpl->tpl_vars['discussion']->value['thread_id'] . "&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), ENT_QUOTES, 'UTF-8'); ?> #post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <div class="ty-discussion-post <?php echo smarty_function_cycle(array('values' => ", ty-discussion-post_even"), $_smarty_tpl); ?> " id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <div class="ty-discussion-post__message"><?php echo nl2br(smarty_modifier_truncate($_smarty_tpl->tpl_vars['post']->value['message'], 100)); ?> </div> <?php } ?> <span class="ty-caret-bottom"><span class="ty-caret-outer"></span><span class="ty-caret-inner"></span></span> </div> </a> <span class="ty-discussion-post__author"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8'); ?> </span> <span class="ty-discussion-post__date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format']), ENT_QUOTES, 'UTF-8'); ?> </span> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B" && $_smarty_tpl->tpl_vars['post']->value['rating_value'] > 0) { ?> <div class="clearfix ty-discussion-post__rating"> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> </div> <?php } ?> <?php $_block_content = ob_get_clean(); $_block_repeat = false; echo smarty_block_hook(array('name' => "discussion:items_list_row"), $_block_content, $_smarty_tpl, $_block_repeat); } array_pop($_smarty_tpl->smarty->_tag_stack); ?> </div> <?php } ?> </div> </div> </div> <?php echo $_smarty_tpl->getSubTemplate("common/scroller_init_with_quantity.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('prev_selector' => "#owl_prev_" . (string) $_smarty_tpl->tpl_vars['obj_prefix']->value, 'next_selector' => "#owl_next_" . (string) $_smarty_tpl->tpl_vars['obj_prefix']->value), 0); ?> <?php } } }
function content_55ccec9f7b1266_22892671($_smarty_tpl) { if (!is_callable('smarty_function_set_id')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/function.set_id.php'; } if ($_smarty_tpl->tpl_vars['runtime']->value['customization_mode']['design'] == "Y" && @constant('AREA') == "C") { $_smarty_tpl->_capture_stack[0][] = array("template_content", null, null); ob_start(); $_smarty_tpl->tpl_vars["object_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['product_id'], null, 0); $_smarty_tpl->tpl_vars["object_type"] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['discussion']['object_type'], null, 0); $_smarty_tpl->tpl_vars["attributes"] = new Smarty_variable(fn_get_review_attributes_work($_smarty_tpl->tpl_vars['object_id']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <div id="attributes_head"> <?php $_smarty_tpl->tpl_vars["rev_count"] = new Smarty_variable(fn_get_review_count($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value, $_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id']), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['product']->value['product_id'] && $_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id']), null, 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id'], true), null, 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value && !$_smarty_tpl->tpl_vars['ratings']->value || $_smarty_tpl->tpl_vars['ratings']->value['average'] == 0.0 && !$_smarty_tpl->tpl_vars['ratings']->value['rating']) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id'], true), null, 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['ratings']->value['average']) { ?> <?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> <a style="text-decoration: none;" onclick="$('#review_attributes').click(); $.scrollToElm($('#review_attributes')); return false;"><?php } echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average'])), 0); if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> </a><?php } ?> <?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> <a style="text-decoration: none;" onclick="$('#review_attributes').click(); $.scrollToElm($('#review_attributes')); return false;"><?php } echo htmlspecialchars($_smarty_tpl->tpl_vars['rev_count']->value, ENT_QUOTES, 'UTF-8'); ?> <?php echo $_smarty_tpl->__('reviews'); if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> </a><?php } ?> <?php } ?> <!--attributes_head--></div> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["average_rating"] = new Smarty_variable(fn_get_average_rating($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['average_rating']->value) { ?> <?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> <a onclick="$('#review_attributes').click(); return false;"><?php } echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['average_rating']->value), 'mode' => 'big'), 0); if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> </a><?php } ?> <?php } ?> <?php } list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } if (trim(Smarty::$_smarty_vars['capture']['template_content'])) { if ($_smarty_tpl->tpl_vars['auth']->value['area'] == "A") { ?> <span class="cm-template-box template-box" data-ca-te-template="addons/altteam_review_attributes/hooks/products/main_info_title.post.tpl" id="<?php echo smarty_function_set_id(array('name' => "addons/altteam_review_attributes/hooks/products/main_info_title.post.tpl"), $_smarty_tpl); ?> "><div class="cm-template-icon icon-edit ty-icon-edit hidden"></div><?php echo Smarty::$_smarty_vars['capture']['template_content']; ?> <!--[/tpl_id]--></span><?php } else { echo Smarty::$_smarty_vars['capture']['template_content']; } } } else { $_smarty_tpl->tpl_vars["object_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['product_id'], null, 0); $_smarty_tpl->tpl_vars["object_type"] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['discussion']['object_type'], null, 0); $_smarty_tpl->tpl_vars["attributes"] = new Smarty_variable(fn_get_review_attributes_work($_smarty_tpl->tpl_vars['object_id']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <div id="attributes_head"> <?php $_smarty_tpl->tpl_vars["rev_count"] = new Smarty_variable(fn_get_review_count($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value, $_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id']), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['product']->value['product_id'] && $_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id']), null, 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id'], true), null, 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value && !$_smarty_tpl->tpl_vars['ratings']->value || $_smarty_tpl->tpl_vars['ratings']->value['average'] == 0.0 && !$_smarty_tpl->tpl_vars['ratings']->value['rating']) { ?> <?php $_smarty_tpl->tpl_vars["ratings"] = new Smarty_variable(fn_get_review_ratings($_smarty_tpl->tpl_vars['product']->value['discussion']['thread_id'], true), null, 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['ratings']->value['average']) { ?> <?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> <a style="text-decoration: none;" onclick="$('#review_attributes').click(); $.scrollToElm($('#review_attributes')); return false;"><?php } echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average'])), 0); if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> </a><?php } ?> <?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> <a style="text-decoration: none;" onclick="$('#review_attributes').click(); $.scrollToElm($('#review_attributes')); return false;"><?php } echo htmlspecialchars($_smarty_tpl->tpl_vars['rev_count']->value, ENT_QUOTES, 'UTF-8'); ?> <?php echo $_smarty_tpl->__('reviews'); if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> </a><?php } ?> <?php } ?> <!--attributes_head--></div> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["average_rating"] = new Smarty_variable(fn_get_average_rating($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['average_rating']->value) { ?> <?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> <a onclick="$('#review_attributes').click(); return false;"><?php } echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['average_rating']->value), 'mode' => 'big'), 0); if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "products" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "view") { ?> </a><?php } ?> <?php } ?> <?php } } }
function content_55ccec9e5f0959_48220432($_smarty_tpl) { if (!is_callable('smarty_function_set_id')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/function.set_id.php'; } if ($_smarty_tpl->tpl_vars['runtime']->value['customization_mode']['design'] == "Y" && @constant('AREA') == "C") { $_smarty_tpl->_capture_stack[0][] = array("template_content", null, null); ob_start(); if ($_smarty_tpl->tpl_vars['show_rating']->value) { ?> <?php if ($_smarty_tpl->tpl_vars['product']->value['average_rating']) { ?> <?php $_smarty_tpl->tpl_vars['average_rating'] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['average_rating'], null, 0); } elseif ($_smarty_tpl->tpl_vars['product']->value['discussion']['average_rating']) { ?> <?php $_smarty_tpl->tpl_vars['average_rating'] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['discussion']['average_rating'], null, 0); } ?> <?php if ($_smarty_tpl->tpl_vars['average_rating']->value) { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['average_rating']->value), 'is_link' => true), 0); ?> <?php } ?> <?php } list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } if (trim(Smarty::$_smarty_vars['capture']['template_content'])) { if ($_smarty_tpl->tpl_vars['auth']->value['area'] == "A") { ?> <span class="cm-template-box template-box" data-ca-te-template="addons/discussion/hooks/products/data_block.pre.tpl" id="<?php echo smarty_function_set_id(array('name' => "addons/discussion/hooks/products/data_block.pre.tpl"), $_smarty_tpl); ?> "><div class="cm-template-icon icon-edit ty-icon-edit hidden"></div><?php echo Smarty::$_smarty_vars['capture']['template_content']; ?> <!--[/tpl_id]--></span><?php } else { echo Smarty::$_smarty_vars['capture']['template_content']; } } } else { if ($_smarty_tpl->tpl_vars['show_rating']->value) { ?> <?php if ($_smarty_tpl->tpl_vars['product']->value['average_rating']) { ?> <?php $_smarty_tpl->tpl_vars['average_rating'] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['average_rating'], null, 0); } elseif ($_smarty_tpl->tpl_vars['product']->value['discussion']['average_rating']) { ?> <?php $_smarty_tpl->tpl_vars['average_rating'] = new Smarty_variable($_smarty_tpl->tpl_vars['product']->value['discussion']['average_rating'], null, 0); } ?> <?php if ($_smarty_tpl->tpl_vars['average_rating']->value) { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['average_rating']->value), 'is_link' => true), 0); ?> <?php } ?> <?php } } }
function content_55d59ee424ee07_94490558($_smarty_tpl) { if (!is_callable('smarty_function_cycle')) { include '/home/coriolan/public_html/lead/app/lib/other/smarty/plugins/function.cycle.php'; } if (!is_callable('smarty_modifier_date_format')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/modifier.date_format.php'; } if (!is_callable('smarty_function_set_id')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/function.set_id.php'; } if ($_smarty_tpl->tpl_vars['runtime']->value['customization_mode']['design'] == "Y" && @constant('AREA') == "C") { $_smarty_tpl->_capture_stack[0][] = array("template_content", null, null); ob_start(); $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['posts']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <tr class="posts<?php echo smarty_function_cycle(array('values' => ", manage-post"), $_smarty_tpl); ?> clear-both" id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <td class="r-legend"> <p class="r-author"><?php echo htmlspecialchars(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8', true), ENT_QUOTES, 'UTF-8'); ?> </p> <p class="r-date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format'] . ", " . (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['time_format']), ENT_QUOTES, 'UTF-8'); ?> </p> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <table cellpadding="0" cellspacing="0" class="ga-rating"> <?php $_smarty_tpl->tpl_vars["post_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['post']->value['post_id'], null, 0); ?> <?php $_smarty_tpl->tpl_vars["attribute"] = new Smarty_Variable(); $_smarty_tpl->tpl_vars["attribute"]->_loop = false; $_from = $_smarty_tpl->tpl_vars['attributes']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars["attribute"]->key => $_smarty_tpl->tpl_vars["attribute"]->value) { $_smarty_tpl->tpl_vars["attribute"]->_loop = true; ?> <tr> <td class="right"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['attribute']->value['attr_name'], ENT_QUOTES, 'UTF-8'); ?> = </td> <td class="left" style="margin-top: 2px;"> <?php $_smarty_tpl->tpl_vars["attr_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['attribute']->value['attr_id'], null, 0); ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['rating'][$_smarty_tpl->tpl_vars['post_id']->value][$_smarty_tpl->tpl_vars['attr_id']->value])), 0); ?> </td> </tr> <?php } ?> </table> <?php } ?> <?php } ?> </td> <td class="r-message"> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] != "C") { ?> <div class="r-subject"> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["rates"] = new Smarty_variable(fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value]), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['FULL']['index']] != 0 || $_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['PART']['index']] != 0) { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value])), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message_title'], ENT_QUOTES, 'UTF-8'); ?> </div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php echo nl2br(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message'], ENT_QUOTES, 'UTF-8', true)); ?> <?php } ?> <div class="r-likes"> <div class="is-useful float-left"><?php echo $_smarty_tpl->__('found_useful'); ?> : <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['yes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['yes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong> <?php echo $_smarty_tpl->__('out_of'); ?> <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['votes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['votes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong></div> <?php echo $_smarty_tpl->__('was_helpful'); ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=1&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=0&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php } ?> </div> </td> </tr> <?php } list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } if (trim(Smarty::$_smarty_vars['capture']['template_content'])) { if ($_smarty_tpl->tpl_vars['auth']->value['area'] == "A") { ?> <span class="cm-template-box template-box" data-ca-te-template="addons/altteam_review_attributes/views/view_posts.tpl" id="<?php echo smarty_function_set_id(array('name' => "addons/altteam_review_attributes/views/view_posts.tpl"), $_smarty_tpl); ?> "><div class="cm-template-icon icon-edit ty-icon-edit hidden"></div><?php echo Smarty::$_smarty_vars['capture']['template_content']; ?> <!--[/tpl_id]--></span><?php } else { echo Smarty::$_smarty_vars['capture']['template_content']; } } } else { $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['posts']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <tr class="posts<?php echo smarty_function_cycle(array('values' => ", manage-post"), $_smarty_tpl); ?> clear-both" id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <td class="r-legend"> <p class="r-author"><?php echo htmlspecialchars(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8', true), ENT_QUOTES, 'UTF-8'); ?> </p> <p class="r-date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format'] . ", " . (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['time_format']), ENT_QUOTES, 'UTF-8'); ?> </p> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <table cellpadding="0" cellspacing="0" class="ga-rating"> <?php $_smarty_tpl->tpl_vars["post_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['post']->value['post_id'], null, 0); ?> <?php $_smarty_tpl->tpl_vars["attribute"] = new Smarty_Variable(); $_smarty_tpl->tpl_vars["attribute"]->_loop = false; $_from = $_smarty_tpl->tpl_vars['attributes']->value; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars["attribute"]->key => $_smarty_tpl->tpl_vars["attribute"]->value) { $_smarty_tpl->tpl_vars["attribute"]->_loop = true; ?> <tr> <td class="right"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['attribute']->value['attr_name'], ENT_QUOTES, 'UTF-8'); ?> = </td> <td class="left" style="margin-top: 2px;"> <?php $_smarty_tpl->tpl_vars["attr_id"] = new Smarty_variable($_smarty_tpl->tpl_vars['attribute']->value['attr_id'], null, 0); ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['rating'][$_smarty_tpl->tpl_vars['post_id']->value][$_smarty_tpl->tpl_vars['attr_id']->value])), 0); ?> </td> </tr> <?php } ?> </table> <?php } ?> <?php } ?> </td> <td class="r-message"> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] != "C") { ?> <div class="r-subject"> <?php if ($_smarty_tpl->tpl_vars['attributes']->value) { ?> <?php $_smarty_tpl->tpl_vars["rates"] = new Smarty_variable(fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value]), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['FULL']['index']] != 0 || $_smarty_tpl->tpl_vars['rates']->value[$_smarty_tpl->getVariable('smarty')->value['section']['PART']['index']] != 0) { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['ratings']->value['average_by_post'][$_smarty_tpl->tpl_vars['post_id']->value])), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("addons/altteam_review_attributes/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> <?php } ?> <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message_title'], ENT_QUOTES, 'UTF-8'); ?> </div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <?php echo nl2br(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message'], ENT_QUOTES, 'UTF-8', true)); ?> <?php } ?> <div class="r-likes"> <div class="is-useful float-left"><?php echo $_smarty_tpl->__('found_useful'); ?> : <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['yes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['yes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong> <?php echo $_smarty_tpl->__('out_of'); ?> <strong><?php if ($_smarty_tpl->tpl_vars['post']->value['likes']['votes']) { echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['likes']['votes'], ENT_QUOTES, 'UTF-8'); } else { ?> 0<?php } ?> </strong></div> <?php echo $_smarty_tpl->__('was_helpful'); ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=1&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_meta' => "cm-ajax", 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=review_attributes.likes&like=0&post_id=" . (string) $_smarty_tpl->tpl_vars['post']->value['post_id']), 0); ?> <?php } else { ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_yes'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_role' => '', 'but_text' => __('review_attributes_no'), 'but_href' => (string) $_smarty_tpl->tpl_vars['index_script']->value . "?dispatch=auth.login_form&return_url=" . (string) $_smarty_tpl->tpl_vars['escaped_current_url']->value), 0); ?> <?php } ?> </div> </td> </tr> <?php } } }
function content_55d7320b9467b7_31111710($_smarty_tpl) { if (!is_callable('smarty_block_hook')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/block.hook.php'; } if (!is_callable('smarty_modifier_date_format')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/modifier.date_format.php'; } if (!is_callable('smarty_function_cycle')) { include '/home/coriolan/public_html/lead/app/lib/other/smarty/plugins/function.cycle.php'; } if (!is_callable('smarty_modifier_replace')) { include '/home/coriolan/public_html/lead/app/lib/other/smarty/plugins/modifier.replace.php'; } if (!is_callable('smarty_function_set_id')) { include '/home/coriolan/public_html/lead/app/functions/smarty_plugins/function.set_id.php'; } fn_preload_lang_vars(array('write_review', 'new_post', 'no_posts_found', 'sign_in', 'purchase_to_review', 'sign_in_and_purchase_to_review', 'sign_in', 'sign_in', 'sign_in_to_review', 'sign_in', 'write_review', 'new_post', 'no_posts_found', 'sign_in', 'purchase_to_review', 'sign_in_and_purchase_to_review', 'sign_in', 'sign_in', 'sign_in_to_review', 'sign_in')); if ($_smarty_tpl->tpl_vars['runtime']->value['customization_mode']['design'] == "Y" && @constant('AREA') == "C") { $_smarty_tpl->_capture_stack[0][] = array("template_content", null, null); ob_start(); $_smarty_tpl->tpl_vars["discussion"] = new Smarty_variable(fn_get_discussion($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value, true, $_REQUEST), null, 0); if ($_smarty_tpl->tpl_vars['object_type']->value == "P") { ?> <?php $_smarty_tpl->tpl_vars['new_post_title'] = new Smarty_variable($_smarty_tpl->__("write_review"), null, 0); } else { ?> <?php $_smarty_tpl->tpl_vars['new_post_title'] = new Smarty_variable($_smarty_tpl->__("new_post"), null, 0); } if ($_smarty_tpl->tpl_vars['discussion']->value && $_smarty_tpl->tpl_vars['discussion']->value['type'] != "D") { ?> <div class="discussion-block" id="<?php if ($_smarty_tpl->tpl_vars['container_id']->value) { echo htmlspecialchars($_smarty_tpl->tpl_vars['container_id']->value, ENT_QUOTES, 'UTF-8'); } else { ?> content_discussion<?php } ?> "> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <?php $_smarty_tpl->_capture_stack[0][] = array("content", null, null); ob_start(); ?> <?php echo $_smarty_tpl->getSubTemplate("common/subheader.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('title' => $_smarty_tpl->tpl_vars['title']->value), 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['subheader']->value) { ?> <h4><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['subheader']->value, ENT_QUOTES, 'UTF-8'); ?> </h4> <?php } ?> <div id="posts_list"> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['posts']) { ?> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value, 'extra_url' => "&selected_section=discussion", 'search' => $_smarty_tpl->tpl_vars['discussion']->value['search']), 0); ?> <?php $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['discussion']->value['posts']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <div class="ty-discussion-post__content"> <?php $_smarty_tpl->smarty->_tag_stack[] = array('hook', array('name' => "discussion:items_list_row")); $_block_repeat = true; echo smarty_block_hook(array('name' => "discussion:items_list_row"), null, $_smarty_tpl, $_block_repeat); while ($_block_repeat) { ob_start(); ?> <span class="ty-discussion-post__author"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8'); ?> </span> <span class="ty-discussion-post__date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format'] . ", " . (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['time_format']), ENT_QUOTES, 'UTF-8'); ?> </span> <div class="ty-discussion-post <?php echo smarty_function_cycle(array('values' => ", ty-discussion-post_even"), $_smarty_tpl); ?> " id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <span class="ty-caret"> <span class="ty-caret-outer"></span> <span class="ty-caret-inner"></span></span> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B" && $_smarty_tpl->tpl_vars['post']->value['rating_value'] > 0) { ?> <div class="clearfix ty-discussion-post__rating"> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> </div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <div class="ty-discussion-post__message"><?php echo nl2br(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message'], ENT_QUOTES, 'UTF-8', true)); ?> </div> <?php } ?> </div> <?php $_block_content = ob_get_clean(); $_block_repeat = false; echo smarty_block_hook(array('name' => "discussion:items_list_row"), $_block_content, $_smarty_tpl, $_block_repeat); } array_pop($_smarty_tpl->smarty->_tag_stack); ?> </div> <?php } ?> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value, 'extra_url' => "&selected_section=discussion", 'search' => $_smarty_tpl->tpl_vars['discussion']->value['search']), 0); ?> <?php } else { ?> <p class="ty-no-items"><?php echo $_smarty_tpl->__("no_posts_found"); ?> </p> <?php } ?> <!--posts_list--></div> <?php if (strpos("CRB", $_smarty_tpl->tpl_vars['discussion']->value['type']) !== false && !$_smarty_tpl->tpl_vars['discussion']->value['disable_adding']) { ?> <?php if ($_smarty_tpl->tpl_vars['object_type']->value == 'P' && $_smarty_tpl->tpl_vars['addons']->value['cscr_purchase_to_review']['review_setup'] == 'purchase_to_review') { ?> <?php $_smarty_tpl->tpl_vars["is_purchased"] = new Smarty_variable(fn_check_customer_purchase($_smarty_tpl->tpl_vars['auth']->value['user_id'], $_smarty_tpl->tpl_vars['object_id']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['is_purchased']->value == 'Y') { ?> <div class="ty-discussion-post__buttons buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => $_smarty_tpl->tpl_vars['new_post_title']->value, 'but_role' => "submit", 'but_target_id' => "new_post_dialog_" . (string) $_smarty_tpl->tpl_vars['obj_id']->value, 'but_meta' => "cm-dialog-opener cm-dialog-auto-size ty-btn__primary", 'but_rel' => "nofollow"), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["return_current_url"] = new Smarty_variable(rawurlencode($_smarty_tpl->tpl_vars['config']->value['current_url']), null, 0); ?> <?php $_smarty_tpl->_capture_stack[0][] = array("cscr_sign_in", null, null); ob_start(); ?> <a href="<?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "auth" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "login_form") { echo htmlspecialchars(fn_url($_smarty_tpl->tpl_vars['config']->value['current_url']), ENT_QUOTES, 'UTF-8'); } else { echo htmlspecialchars(fn_url("auth.login_form?return_url=" . (string) $_smarty_tpl->tpl_vars['return_current_url']->value), ENT_QUOTES, 'UTF-8'); } ?> " <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> data-ca-target-id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="cm-dialog-opener cm-dialog-auto-size ty-btn ty-btn__primary"<?php } else { ?> class="ty-btn ty-btn__primary"<?php } ?> rel="nofollow"><?php echo $_smarty_tpl->__("sign_in"); ?> </a> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { echo $_smarty_tpl->__("purchase_to_review"); } else { echo smarty_modifier_replace($_smarty_tpl->__("sign_in_and_purchase_to_review"), "[sign_in]", Smarty::$_smarty_vars['capture']['cscr_sign_in']); } ?> <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> <div id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="hidden" title="<?php echo $_smarty_tpl->__("sign_in"); ?> "> <div class="ty-login-popup"> <?php echo $_smarty_tpl->getSubTemplate("views/auth/login_form.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('style' => "popup", 'id' => "popup" . (string) $_smarty_tpl->tpl_vars['block']->value['snapping_id']), 0); ?> </div> </div> <?php } ?> <?php } ?> <?php } elseif ($_smarty_tpl->tpl_vars['object_type']->value != 'P' && $_smarty_tpl->tpl_vars['addons']->value['cscr_purchase_to_review']['review_setup'] == 'purchase_to_review') { ?> <div class="ty-discussion-post__buttons buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => $_smarty_tpl->tpl_vars['new_post_title']->value, 'but_role' => "submit", 'but_target_id' => "new_post_dialog_" . (string) $_smarty_tpl->tpl_vars['obj_id']->value, 'but_meta' => "cm-dialog-opener cm-dialog-auto-size ty-btn__primary", 'but_rel' => "nofollow"), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['addons']->value['cscr_purchase_to_review']['review_setup'] == 'sign_in_to_review') { ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { ?> <div class="ty-discussion-post__buttons buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => $_smarty_tpl->tpl_vars['new_post_title']->value, 'but_role' => "submit", 'but_target_id' => "new_post_dialog_" . (string) $_smarty_tpl->tpl_vars['obj_id']->value, 'but_meta' => "cm-dialog-opener cm-dialog-auto-size ty-btn__primary", 'but_rel' => "nofollow"), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["return_current_url"] = new Smarty_variable(rawurlencode($_smarty_tpl->tpl_vars['config']->value['current_url']), null, 0); ?> <?php $_smarty_tpl->_capture_stack[0][] = array("cscr_sign_in", null, null); ob_start(); ?> <a href="<?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "auth" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "login_form") { echo htmlspecialchars(fn_url($_smarty_tpl->tpl_vars['config']->value['current_url']), ENT_QUOTES, 'UTF-8'); } else { echo htmlspecialchars(fn_url("auth.login_form?return_url=" . (string) $_smarty_tpl->tpl_vars['return_current_url']->value), ENT_QUOTES, 'UTF-8'); } ?> " <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> data-ca-target-id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="cm-dialog-opener cm-dialog-auto-size ty-btn ty-btn__primary"<?php } else { ?> class="ty-btn ty-btn__primary"<?php } ?> rel="nofollow"><?php echo $_smarty_tpl->__("sign_in"); ?> </a> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php echo smarty_modifier_replace($_smarty_tpl->__("sign_in_to_review"), "[sign_in]", Smarty::$_smarty_vars['capture']['cscr_sign_in']); ?> <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> <div id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="hidden" title="<?php echo $_smarty_tpl->__("sign_in"); ?> "> <div class="ty-login-popup"> <?php echo $_smarty_tpl->getSubTemplate("views/auth/login_form.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('style' => "popup", 'id' => "popup" . (string) $_smarty_tpl->tpl_vars['block']->value['snapping_id']), 0); ?> </div> </div> <?php } ?> <?php } ?> <?php } ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php echo Smarty::$_smarty_vars['capture']['content']; ?> <?php } else { ?> <?php $_smarty_tpl->_capture_stack[0][] = array("mainbox_title", null, null); ob_start(); echo htmlspecialchars($_smarty_tpl->tpl_vars['title']->value, ENT_QUOTES, 'UTF-8'); list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php } ?> </div> <?php } list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } if (trim(Smarty::$_smarty_vars['capture']['template_content'])) { if ($_smarty_tpl->tpl_vars['auth']->value['area'] == "A") { ?> <span class="cm-template-box template-box" data-ca-te-template="addons/cscr_purchase_to_review/overrides/addons/discussion/views/discussion/view.tpl" id="<?php echo smarty_function_set_id(array('name' => "addons/cscr_purchase_to_review/overrides/addons/discussion/views/discussion/view.tpl"), $_smarty_tpl); ?> "><div class="cm-template-icon icon-edit ty-icon-edit hidden"></div><?php echo Smarty::$_smarty_vars['capture']['template_content']; ?> <!--[/tpl_id]--></span><?php } else { echo Smarty::$_smarty_vars['capture']['template_content']; } } } else { $_smarty_tpl->tpl_vars["discussion"] = new Smarty_variable(fn_get_discussion($_smarty_tpl->tpl_vars['object_id']->value, $_smarty_tpl->tpl_vars['object_type']->value, true, $_REQUEST), null, 0); if ($_smarty_tpl->tpl_vars['object_type']->value == "P") { ?> <?php $_smarty_tpl->tpl_vars['new_post_title'] = new Smarty_variable($_smarty_tpl->__("write_review"), null, 0); } else { ?> <?php $_smarty_tpl->tpl_vars['new_post_title'] = new Smarty_variable($_smarty_tpl->__("new_post"), null, 0); } if ($_smarty_tpl->tpl_vars['discussion']->value && $_smarty_tpl->tpl_vars['discussion']->value['type'] != "D") { ?> <div class="discussion-block" id="<?php if ($_smarty_tpl->tpl_vars['container_id']->value) { echo htmlspecialchars($_smarty_tpl->tpl_vars['container_id']->value, ENT_QUOTES, 'UTF-8'); } else { ?> content_discussion<?php } ?> "> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <?php $_smarty_tpl->_capture_stack[0][] = array("content", null, null); ob_start(); ?> <?php echo $_smarty_tpl->getSubTemplate("common/subheader.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('title' => $_smarty_tpl->tpl_vars['title']->value), 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['subheader']->value) { ?> <h4><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['subheader']->value, ENT_QUOTES, 'UTF-8'); ?> </h4> <?php } ?> <div id="posts_list"> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['posts']) { ?> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value, 'extra_url' => "&selected_section=discussion", 'search' => $_smarty_tpl->tpl_vars['discussion']->value['search']), 0); ?> <?php $_smarty_tpl->tpl_vars['post'] = new Smarty_Variable(); $_smarty_tpl->tpl_vars['post']->_loop = false; $_from = $_smarty_tpl->tpl_vars['discussion']->value['posts']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); } foreach ($_from as $_smarty_tpl->tpl_vars['post']->key => $_smarty_tpl->tpl_vars['post']->value) { $_smarty_tpl->tpl_vars['post']->_loop = true; ?> <div class="ty-discussion-post__content"> <?php $_smarty_tpl->smarty->_tag_stack[] = array('hook', array('name' => "discussion:items_list_row")); $_block_repeat = true; echo smarty_block_hook(array('name' => "discussion:items_list_row"), null, $_smarty_tpl, $_block_repeat); while ($_block_repeat) { ob_start(); ?> <span class="ty-discussion-post__author"><?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['name'], ENT_QUOTES, 'UTF-8'); ?> </span> <span class="ty-discussion-post__date"><?php echo htmlspecialchars(smarty_modifier_date_format($_smarty_tpl->tpl_vars['post']->value['timestamp'], (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['date_format'] . ", " . (string) $_smarty_tpl->tpl_vars['settings']->value['Appearance']['time_format']), ENT_QUOTES, 'UTF-8'); ?> </span> <div class="ty-discussion-post <?php echo smarty_function_cycle(array('values' => ", ty-discussion-post_even"), $_smarty_tpl); ?> " id="post_<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['post_id'], ENT_QUOTES, 'UTF-8'); ?> "> <span class="ty-caret"> <span class="ty-caret-outer"></span> <span class="ty-caret-inner"></span></span> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "R" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B" && $_smarty_tpl->tpl_vars['post']->value['rating_value'] > 0) { ?> <div class="clearfix ty-discussion-post__rating"> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/stars.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('stars' => fn_get_discussion_rating($_smarty_tpl->tpl_vars['post']->value['rating_value'])), 0); ?> </div> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['discussion']->value['type'] == "C" || $_smarty_tpl->tpl_vars['discussion']->value['type'] == "B") { ?> <div class="ty-discussion-post__message"><?php echo nl2br(htmlspecialchars($_smarty_tpl->tpl_vars['post']->value['message'], ENT_QUOTES, 'UTF-8', true)); ?> </div> <?php } ?> </div> <?php $_block_content = ob_get_clean(); $_block_repeat = false; echo smarty_block_hook(array('name' => "discussion:items_list_row"), $_block_content, $_smarty_tpl, $_block_repeat); } array_pop($_smarty_tpl->smarty->_tag_stack); ?> </div> <?php } ?> <?php echo $_smarty_tpl->getSubTemplate("common/pagination.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('id' => "pagination_contents_comments_" . (string) $_smarty_tpl->tpl_vars['object_id']->value, 'extra_url' => "&selected_section=discussion", 'search' => $_smarty_tpl->tpl_vars['discussion']->value['search']), 0); ?> <?php } else { ?> <p class="ty-no-items"><?php echo $_smarty_tpl->__("no_posts_found"); ?> </p> <?php } ?> <!--posts_list--></div> <?php if (strpos("CRB", $_smarty_tpl->tpl_vars['discussion']->value['type']) !== false && !$_smarty_tpl->tpl_vars['discussion']->value['disable_adding']) { ?> <?php if ($_smarty_tpl->tpl_vars['object_type']->value == 'P' && $_smarty_tpl->tpl_vars['addons']->value['cscr_purchase_to_review']['review_setup'] == 'purchase_to_review') { ?> <?php $_smarty_tpl->tpl_vars["is_purchased"] = new Smarty_variable(fn_check_customer_purchase($_smarty_tpl->tpl_vars['auth']->value['user_id'], $_smarty_tpl->tpl_vars['object_id']->value), null, 0); ?> <?php if ($_smarty_tpl->tpl_vars['is_purchased']->value == 'Y') { ?> <div class="ty-discussion-post__buttons buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => $_smarty_tpl->tpl_vars['new_post_title']->value, 'but_role' => "submit", 'but_target_id' => "new_post_dialog_" . (string) $_smarty_tpl->tpl_vars['obj_id']->value, 'but_meta' => "cm-dialog-opener cm-dialog-auto-size ty-btn__primary", 'but_rel' => "nofollow"), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["return_current_url"] = new Smarty_variable(rawurlencode($_smarty_tpl->tpl_vars['config']->value['current_url']), null, 0); ?> <?php $_smarty_tpl->_capture_stack[0][] = array("cscr_sign_in", null, null); ob_start(); ?> <a href="<?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "auth" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "login_form") { echo htmlspecialchars(fn_url($_smarty_tpl->tpl_vars['config']->value['current_url']), ENT_QUOTES, 'UTF-8'); } else { echo htmlspecialchars(fn_url("auth.login_form?return_url=" . (string) $_smarty_tpl->tpl_vars['return_current_url']->value), ENT_QUOTES, 'UTF-8'); } ?> " <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> data-ca-target-id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="cm-dialog-opener cm-dialog-auto-size ty-btn ty-btn__primary"<?php } else { ?> class="ty-btn ty-btn__primary"<?php } ?> rel="nofollow"><?php echo $_smarty_tpl->__("sign_in"); ?> </a> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { echo $_smarty_tpl->__("purchase_to_review"); } else { echo smarty_modifier_replace($_smarty_tpl->__("sign_in_and_purchase_to_review"), "[sign_in]", Smarty::$_smarty_vars['capture']['cscr_sign_in']); } ?> <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> <div id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="hidden" title="<?php echo $_smarty_tpl->__("sign_in"); ?> "> <div class="ty-login-popup"> <?php echo $_smarty_tpl->getSubTemplate("views/auth/login_form.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('style' => "popup", 'id' => "popup" . (string) $_smarty_tpl->tpl_vars['block']->value['snapping_id']), 0); ?> </div> </div> <?php } ?> <?php } ?> <?php } elseif ($_smarty_tpl->tpl_vars['object_type']->value != 'P' && $_smarty_tpl->tpl_vars['addons']->value['cscr_purchase_to_review']['review_setup'] == 'purchase_to_review') { ?> <div class="ty-discussion-post__buttons buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => $_smarty_tpl->tpl_vars['new_post_title']->value, 'but_role' => "submit", 'but_target_id' => "new_post_dialog_" . (string) $_smarty_tpl->tpl_vars['obj_id']->value, 'but_meta' => "cm-dialog-opener cm-dialog-auto-size ty-btn__primary", 'but_rel' => "nofollow"), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['addons']->value['cscr_purchase_to_review']['review_setup'] == 'sign_in_to_review') { ?> <?php if ($_smarty_tpl->tpl_vars['auth']->value['user_id']) { ?> <div class="ty-discussion-post__buttons buttons-container"> <?php echo $_smarty_tpl->getSubTemplate("buttons/button.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('but_id' => "opener_new_post", 'but_text' => $_smarty_tpl->tpl_vars['new_post_title']->value, 'but_role' => "submit", 'but_target_id' => "new_post_dialog_" . (string) $_smarty_tpl->tpl_vars['obj_id']->value, 'but_meta' => "cm-dialog-opener cm-dialog-auto-size ty-btn__primary", 'but_rel' => "nofollow"), 0); ?> </div> <?php echo $_smarty_tpl->getSubTemplate("addons/discussion/views/discussion/components/new_post.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('new_post_title' => $_smarty_tpl->tpl_vars['new_post_title']->value), 0); ?> <?php } else { ?> <?php $_smarty_tpl->tpl_vars["return_current_url"] = new Smarty_variable(rawurlencode($_smarty_tpl->tpl_vars['config']->value['current_url']), null, 0); ?> <?php $_smarty_tpl->_capture_stack[0][] = array("cscr_sign_in", null, null); ob_start(); ?> <a href="<?php if ($_smarty_tpl->tpl_vars['runtime']->value['controller'] == "auth" && $_smarty_tpl->tpl_vars['runtime']->value['mode'] == "login_form") { echo htmlspecialchars(fn_url($_smarty_tpl->tpl_vars['config']->value['current_url']), ENT_QUOTES, 'UTF-8'); } else { echo htmlspecialchars(fn_url("auth.login_form?return_url=" . (string) $_smarty_tpl->tpl_vars['return_current_url']->value), ENT_QUOTES, 'UTF-8'); } ?> " <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> data-ca-target-id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="cm-dialog-opener cm-dialog-auto-size ty-btn ty-btn__primary"<?php } else { ?> class="ty-btn ty-btn__primary"<?php } ?> rel="nofollow"><?php echo $_smarty_tpl->__("sign_in"); ?> </a> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php echo smarty_modifier_replace($_smarty_tpl->__("sign_in_to_review"), "[sign_in]", Smarty::$_smarty_vars['capture']['cscr_sign_in']); ?> <?php if ($_smarty_tpl->tpl_vars['settings']->value['Security']['secure_auth'] != "Y") { ?> <div id="login_block<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['block']->value['snapping_id'], ENT_QUOTES, 'UTF-8'); ?> " class="hidden" title="<?php echo $_smarty_tpl->__("sign_in"); ?> "> <div class="ty-login-popup"> <?php echo $_smarty_tpl->getSubTemplate("views/auth/login_form.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, null, array('style' => "popup", 'id' => "popup" . (string) $_smarty_tpl->tpl_vars['block']->value['snapping_id']), 0); ?> </div> </div> <?php } ?> <?php } ?> <?php } ?> <?php } ?> <?php if ($_smarty_tpl->tpl_vars['wrap']->value == true) { ?> <?php list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php echo Smarty::$_smarty_vars['capture']['content']; ?> <?php } else { ?> <?php $_smarty_tpl->_capture_stack[0][] = array("mainbox_title", null, null); ob_start(); echo htmlspecialchars($_smarty_tpl->tpl_vars['title']->value, ENT_QUOTES, 'UTF-8'); list($_capture_buffer, $_capture_assign, $_capture_append) = array_pop($_smarty_tpl->_capture_stack[0]); if (!empty($_capture_buffer)) { if (isset($_capture_assign)) { $_smarty_tpl->assign($_capture_assign, ob_get_contents()); } if (isset($_capture_append)) { $_smarty_tpl->append($_capture_append, ob_get_contents()); } Smarty::$_smarty_vars['capture'][$_capture_buffer] = ob_get_clean(); } else { $_smarty_tpl->capture_error(); } ?> <?php } ?> </div> <?php } } }
function content_55cdb2ac7687b2_24471595($_smarty_tpl) { fn_preload_lang_vars(array('seo.rich_snippets_rating', 'seo.rich_snippets_reviews')); if ($_smarty_tpl->tpl_vars['discussion']->value && $_smarty_tpl->tpl_vars['discussion']->value['average_rating']) { ?> <?php $_smarty_tpl->tpl_vars['stars'] = new Smarty_variable(fn_get_discussion_rating($_smarty_tpl->tpl_vars['discussion']->value['average_rating']), null, 0); ?> <p class="nowrap gstars"> <?php if (isset($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"])) { unset($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]); } $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['name'] = "full_star"; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop'] = is_array($_loop = $_smarty_tpl->tpl_vars['stars']->value['full']) ? count($_loop) : max(0, (int) $_loop); unset($_loop); $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show'] = true; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['max'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step'] = 1; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['start'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step'] > 0 ? 0 : $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop'] - 1; if ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show']) { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop']; if ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total'] == 0) { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show'] = false; } } else { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total'] = 0; } if ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show']) { for ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['start'], $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] = 1; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] <= $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] += $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step'], $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration']++) { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['rownum'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index_prev'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] - $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index_next'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] + $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['first'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] == 1; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['last'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] == $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total']; ?> <i class="gicon-star"></i><?php } } ?> <?php if ($_smarty_tpl->tpl_vars['stars']->value['part']) { ?> <i class="gicon-star-half"></i><?php } ?> <?php if (isset($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"])) { unset($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]); } $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['name'] = "full_star"; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop'] = is_array($_loop = $_smarty_tpl->tpl_vars['stars']->value['empty']) ? count($_loop) : max(0, (int) $_loop); unset($_loop); $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show'] = true; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['max'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step'] = 1; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['start'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step'] > 0 ? 0 : $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop'] - 1; if ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show']) { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['loop']; if ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total'] == 0) { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show'] = false; } } else { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total'] = 0; } if ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['show']) { for ($_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['start'], $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] = 1; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] <= $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] += $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step'], $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration']++) { $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['rownum'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index_prev'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] - $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index_next'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['index'] + $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['step']; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['first'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] == 1; $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['last'] = $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['iteration'] == $_smarty_tpl->tpl_vars['smarty']->value['section']["full_star"]['total']; ?> <i class="gicon-star-empty"></i><?php } } ?> </p> <?php echo $_smarty_tpl->__("seo.rich_snippets_rating"); ?> : <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['discussion']->value['average_rating'], ENT_QUOTES, 'UTF-8'); ?> - <?php echo $_smarty_tpl->__("seo.rich_snippets_reviews", array($_smarty_tpl->tpl_vars['discussion']->value['search']['total_items'])); ?> - <?php } ?> <?php }