%PDF- %PDF-
Direktori : /home/bitrix/www/bitrix/templates/p4_new/components/bitrix/rating.vote/blueimp/ |
Current File : /home/bitrix/www/bitrix/templates/p4_new/components/bitrix/rating.vote/blueimp/template.php |
<?if(!defined("B_PROLOG_INCLUDED") || B_PROLOG_INCLUDED!==true)die();?> <?//echo '<pre>'; print_r($arResult); echo '</pre>';?> <li id="blueimp-like"><span class="bx-ilike-button <?=($arResult['VOTE_AVAILABLE'] == 'Y'? '': 'bx-ilike-button-disable')?>" id="bx-ilike-button-<?=htmlspecialcharsbx($arResult['VOTE_ID'])?>"><span class="bx-ilike-left-wrap" <?=($arResult['VOTE_AVAILABLE'] == 'Y'? '': 'title="'.htmlspecialcharsbx($arResult['ALLOW_VOTE']['ERROR_MSG']).'"')?>><? if($arResult['VOTE_AVAILABLE'] == 'Y'): ?><span title="<?=($arResult['USER_HAS_VOTED'] == 'N'?'':'')?>" class="bx-ilike-text"><?=($arResult['USER_HAS_VOTED'] == 'N'? '<i class="fa fa-heart-o"></i>': '<i class="fa fa-heart"></i>')?></span><? else:?> <span class="bx-ilike-text-none"><i class="fa fa-heart-o"></i></span> <? endif;?></span><span class="bx-ilike-right-wrap <?=($arResult['USER_HAS_VOTED'] == 'N'? '': 'bx-you-like')?>"> <span class="bx-ilike-right" style="display: none;"><?=htmlspecialcharsEx($arResult['TOTAL_VOTES'])?></span> </span> </span><span class="bx-ilike-wrap-block" id="bx-ilike-popup-cont-<?=htmlspecialcharsbx($arResult['VOTE_ID'])?>" style="display:none;"><span class="bx-ilike-popup"><span class="bx-ilike-wait"></span></span></span></li> <script type="text/javascript"> BX.ready(function() { <?if ($arResult['AJAX_MODE'] == 'Y'):?> BX.loadCSS('<?=$this->GetFolder()?>/popup.css'); BX.loadScript('/bitrix/js/main/rating_like.js', function() { <?endif;?> if (!window.RatingLike && top.RatingLike) RatingLike = top.RatingLike; if (!IsAuthorized()) { $('span#bx-ilike-button-<?=htmlspecialcharsbx($arResult['VOTE_ID'])?> i').click(function(){ showAuthAlert('like'); }); } if (typeof(RatingLike) == 'undefined') return false; RatingLike.Set( '<?=CUtil::JSEscape($arResult['VOTE_ID'])?>', '<?=CUtil::JSEscape($arResult['ENTITY_TYPE_ID'])?>', '<?=IntVal($arResult['ENTITY_ID'])?>', '<?=CUtil::JSEscape($arResult['VOTE_AVAILABLE'])?>', '<?=$USER->GetId()?>', { 'LIKE_Y' : '<i class="fa fa-heart"></i>', 'LIKE_N' : '<i class="fa fa-heart-o"></i>', 'LIKE_D' : '<?=htmlspecialcharsBx(CUtil::JSEscape($arResult['RATING_TEXT_LIKE_D']))?>'}, 'light', '<?=CUtil::JSEscape($arResult['PATH_TO_USER_PROFILE'])?>' ); if (typeof(RatingLikePullInit) == 'undefined') { RatingLikePullInit = true; BX.addCustomEvent("onPullEvent-main", function(command,params) { if (command == 'rating_vote') { RatingLike.LiveUpdate(params); } }); } <?if ($arResult['AJAX_MODE'] == 'Y'):?> }); <?endif;?> }); </script>