<?php 
if($this->session->userdata['shopsy_session_user_name']!= ''){
	redirect('home');
}
$this->load->view('site/templates/commonheader');
?>
<script type="text/javascript">


function show_more(){
	//alert(val);
	if($('.more-view').css('display')=='block'){
		$('.more-view').hide('');	
	}else{
		$('.more-view').show('');
	}
}
function hide_more(){
	//alert(val);
	if($('.more-view').css('display')=='block'){
		 $('.more-view').show('');
	}else{
		$('.more-view').hide('');	
	}
}
</script>

<script src="js/site/popup_jquery.js"></script>

 <script type="text/javascript">

		function displayfunction(id,id2){
		
		
		if(document.getElementById(id).style.display=="none")
		{
		document.getElementById(id).style.display="block";
		document.getElementById(id2).style.display="none";
		return true;
		}
		if(document.getElementById(id).style.display=="block")
		{
		document.getElementById(id).style.display="none";
		document.getElementById(id2).style.display="block";
		return true;
		}
		
		}
		
		
		
</script>


</head>
 		<?php
				if($this->session->flashdata('sErrMSG') != '') { ?>
                <div class="errorContainer" id="<?php echo $this->session->flashdata('sErrMSGType'); ?>">
                  <script>setTimeout("hideErrDiv('<?php echo $this->session->flashdata('sErrMSGType'); ?>')", 5000);</script>
                  <p><span> <?php echo $this->session->flashdata('sErrMSG');  ?> </span></p>
                </div>
   		 <?php } ?>
<body>



<div  class="register_popup_main" id="details" style="display:none;"> 
  
  <div class="main">
  
  <div  class="register_popup"> 
  
  	
  	 <a onClick="return displayfunction('details','details_parent');" id="cboxClose"></a>
  
    <div id="TabbedPanels1" class="TabbedPanels">
            <ul style="float:left;margin:0 0  0; background:#f5f5f1;padding: 26px 42px 0;width: 85.6%;" class="TabbedPanelsTabGroup">
             <li style="font-size: 13px;height:auto !important; padding: 5px 10px;width:auto; " class="TabbedPanelsTab " tabindex="0"><?php if($this->lang->line('user_signin') != '') { echo stripslashes($this->lang->line('user_signin')); } else echo "Sign In"; ?></li>
            <li style="font-size: 13px;height:auto !important; padding: 5px 10px;width:auto; " class="TabbedPanelsTab " tabindex="0"><?php if($this->lang->line('user_register') != '') { echo stripslashes($this->lang->line('user_register')); } else echo "Register"; ?></li>
            </ul>
            
           
        <div class="TabbedPanelsContentGroup">
        
        
        <div class="TabbedPanelsContent ">
        <div>
           <div style="padding-bottom: 20px;" class="popup_tab_content">
				<?php   if ($this->config->item('facebook_app_id') != '' && $this->config->item('facebook_app_secret') != ''){?> 
                <div class="fb_div"><a id="fbsignin" class="button-faceb" href="<?php echo base_url().'facebook/user.php'; ?>"><span> <?php if($this->lang->line('sign_facebook') != '') { echo stripslashes($this->lang->line('sign_facebook')); } else echo "Sign In Using Facebook"; ?> </span></a></div>
               
                <div class="or_div">
                    <span><?php if($this->lang->line('user_or') != '') { echo stripslashes($this->lang->line('user_or')); } else echo "OR"; ?></span>
                </div> <?php } ?>	
                <form method="post" action="site/user/login_user" class="frm clearfix" onSubmit="return loginVal();">
                <div class="popup_login">
                <label><?php if($this->lang->line('user_email_or_uname') != '') { echo stripslashes($this->lang->line('user_email_or_uname')); } else echo "Email or Username"; ?></label><span style="color:#F00;" class="redFont" id="emailAddr_Warn"></span> 
                <input type="text" class="search" style="margin:0" name="emailAddr" id="emailAddr"/>
                </div> 
                <div class="popup_login">
                <label><?php if($this->lang->line('user_password') != '') { echo stripslashes($this->lang->line('user_password')); } else echo "Password"; ?></label><span style="color:#F00;" class="redFont" id="password_Warn"></span>  
                <input type="password" class="search" style="margin:0" name="password" id="password"/>
                </div>
                <div class="popup_login">
                <input  style="margin: 0px 5px 0px 0px;" type="checkbox" name="stay_signed_in" value="yes" checked/><?php if($this->lang->line('stay_sign') != '') { echo stripslashes($this->lang->line('stay_sign')); } else echo "Stay Signed in"; ?>
                </div>
                <div class="popup_login" style="margin-bottom:15px">
                <input type="submit" class="submit_btn" value="<?php if($this->lang->line('user_signin') != '') { echo stripslashes($this->lang->line('user_signin')); } else echo "Sign In"; ?>" />
                 <span id="loginloadErr" style="display:none;"><img src="images/indicator.gif" alt="Loading..."></span>
                 
                 
                </div>
                </form>
                <div style=" margin: 0 0 10px 45px;" class="div_line"></div>
                <a href="forgot-password" style="float:left;font-size: 12px; width:100%;    line-height: 23px; margin:0 0 0px 44px;"><?php if($this->lang->line('user_fgt_pwd') != '') { echo stripslashes($this->lang->line('user_fgt_pwd')); } else echo "Forgot your password?"; ?></a>
                <?php /*?><a href="javascript:void(0)" style="float:left;font-size: 12px; width:100%;    line-height: 13px; margin:0 0 0px 50px;">Forgot your username or email?</a><?php */?>
                <a href="reopen-account" style="float:left;font-size: 12px; width:100%;    line-height: 13px; margin:0 0 0px 44px;"><?php if($this->lang->line('land_reopenacc') != '') { echo stripslashes($this->lang->line('land_reopenacc')); } else echo "Reopen your account?"; ?></a>
        	</div>
        <div>
        </div>
  		</div>
    </div>
    
    <div class="TabbedPanelsContent">
    		<div class="view_invoice">
			<div class="popup_tab_content">
				<?php   if ($this->config->item('facebook_app_id') != '' && $this->config->item('facebook_app_secret') != ''){?> 
                <div class="fb_div"><a id="fbsignin" style="margin:0" class="button-faceb" href="<?php echo base_url().'facebook/user.php'; ?>"><span><?php if($this->lang->line('user_signup_use_fb') != '') { echo stripslashes($this->lang->line('user_signup_use_fb')); } else echo " Sign Up Using Facebook"; ?> </span></a></div>
                <!--<img src="images/sign_fb.png" onClick="window.location.href='<?php echo base_url().'facebook/user.php'; ?>'"/>-->
                
                <p style="font-size:9px; margin:0 0 15px 44px; color:#666; width:auto; float:left"><?php if($this->lang->line('land_allowfrindsup') != '') { echo stripslashes($this->lang->line('land_allowfrindsup')); } else echo "Signing up will allow your friends to find you on"; ?> <?php echo $this->config->item('email_title'); ?>. <?php if($this->lang->line('land_postpermission') != '') { echo stripslashes($this->lang->line('land_postpermission')); } else echo "We'll never post without your permission"; ?>. </p>
                <div class="or_div">
                    <span><?php if($this->lang->line('user_or') != '') { echo stripslashes($this->lang->line('user_or')); } else echo "OR"; ?></span>
                </div>
                <?php } ?>	
                <form  method="post" action=""  onSubmit="return register_user();">
                    <div class="popup_login">
                        <label><?php if($this->lang->line('user_fname') != '') { echo stripslashes($this->lang->line('user_fname')); } else echo "First Name"; ?></label><span style="color:#F00;" class="redFont" id="fullnameErr"></span> 
                        <input type="text" class="search" style="margin:0" name="fullname" id="fullname"/>
                    </div>
                    <div class="popup_login">
                        <label><?php if($this->lang->line('user_lname') != '') { echo stripslashes($this->lang->line('user_lname')); } else echo "Last Name"; ?></label><span style="color:#F00;" class="redFont" id="lastnameErr"></span> 
                        <input type="text" class="search" style="margin:0" name="lastname" id="lastname"/>
                    </div>
                    <div class="popup_login">
                        <input type="radio" style="float:left;margin: 6px 6px 0 2px;" name="gender" value="Male" checked/><span class="gen_check"><?php if($this->lang->line('user_male') != '') { echo stripslashes($this->lang->line('user_male')); } else echo "Male"; ?></span>
                        <input type="radio" style="float:left;margin: 6px 6px 0 12px;" name="gender" value="Female"/><span class="gen_check"><?php if($this->lang->line('user_female') != '') { echo stripslashes($this->lang->line('user_female')); } else echo "Female"; ?></span>
                        <input type="radio" style="float:left;margin: 6px 6px 0 12px;" name="gender" value="Unspecified"/><span class="gen_check"><?php if($this->lang->line('user_rather_not_say') != '') { echo stripslashes($this->lang->line('user_rather_not_say')); } else echo "Rather not say"; ?></span>
                    </div>
                    <div class="div_line" style="margin:20px 0 0px 45px"></div>
                    <div class="popup_login">
                        <label><?php if($this->lang->line('user_email') != '') { echo stripslashes($this->lang->line('user_email')); } else echo "Email"; ?></label><span style="color:#F00;" class="redFont" id="emailErr"></span> 
                        <input type="text" class="search" style="margin:0" name="email" id="email"/>
                    </div>
                    <div class="popup_login">
                        <label><?php if($this->lang->line('user_password') != '') { echo stripslashes($this->lang->line('user_password')); } else echo "Password"; ?></label><span style="color:#F00;" class="redFont" id="user_passwordErr"></span> 
                        <input type="password" class="search" style="margin:0" name="pwd" id="pwd"/>
                    </div>
                    <div class="popup_login">
                        <label><?php if($this->lang->line('user_confrm_pwd') != '') { echo stripslashes($this->lang->line('user_confrm_pwd')); } else echo "Confirm Password"; ?></label><span style="color:#F00;" class="redFont" id="user_ConfirmpasswordErr"></span> 
                        <input type="password" class="search" style="margin:0" name="Confirmpwd" id="Confirmpwd"/>
                    </div>
                    <div class="popup_login">
                        <label><?php if($this->lang->line('user_user_name') != '') { echo stripslashes($this->lang->line('user_user_name')); } else echo "Username"; ?></label><span style="color:#F00;" class="redFont" id="usernameErr"></span> 
                        <span id="SpecialErr" style="margin:10px; color:#F00;"></span>
                        <input type="text" class="search" style="margin:0" name="username" id="username"/>
                    </div>
                    <div class="div_line" style="margin:20px 0 0px 45px"></div>
                    <p style="font-size:12px;  margin: 5px 0 4px 42px; color:#666; width:auto; float:left">
                    
                  <span style=" color: #999999;font-size: 11px;margin: 12px 0 5px;"> 
                  <input type="checkbox" name="privacychecking" id="privacychecking"  checked/> 
				  <?php if($this->lang->line('user_by_clk_rster') != '') { echo stripslashes($this->lang->line('user_by_clk_rster')); } else echo "By clicking Register, you confirm that you accept our"; ?> 
                    <a href="pages/terms-conditions" target="_blank"><?php if($this->lang->line('user_touse') != '') { echo stripslashes($this->lang->line('user_touse')); } else echo "Terms of Use"; ?></a> <?php if($this->lang->line('user_and') != '') { echo stripslashes($this->lang->line('user_and')); } else echo "and"; ?><a href="pages/privacy-policy" target="_blank"> <?php if($this->lang->line('user_privacy_policy') != '') { echo stripslashes($this->lang->line('user_privacy_policy')); } else echo "Privacy Policy"; ?></a></span>
                    <br />
                    
                     <input type="checkbox" name="subscription" id="subscription" style="display:none;" />
                      <?php /*if($this->lang->line('land_toreceive') != '') { echo stripslashes($this->lang->line('land_toreceive')); } else echo "I want to receive"; ?> <?php echo $this->config->item('email_title'); ?> <?php if($this->lang->line('land_anemailnews') != '') { echo stripslashes($this->lang->line('land_anemailnews')); } else echo "Finds, an email newsletter of fresh trends and editors' picks";*/ ?>
                    <span class="error" id="PrivacyErr"></span>
                    </p>
                    
                    <div class="popup_login" style="margin-bottom:15px">
                    	<input type="submit" class="submit_btn" value="<?php if($this->lang->line('user_register') != '') { echo stripslashes($this->lang->line('user_register')); } else echo "Register"; ?>"/>
                        <span id="loadErr"></span>
                    </div>
                </form>
			</div>
        	</div>
  		</div>
  		
		</div>            
        <div class="clear"></div>
        <!--end of tab panels-->
	</div>
  </div>

</div>

</div>
<script type="text/javascript">
<!--
var TabbedPanels1 = new Spry.Widget.TabbedPanels("TabbedPanels1");
 //-->
</script>

<!-- header_start -->
<header>    	   
        <div class="header">
        	<div class="main">
            	<h1 style="float:left">
                <a href="<?php echo base_url(); ?>"><img src="images/logo/<?php echo $this->config->item('like_text'); ?>" alt="<?php echo $this->config->item('email_title'); ?>" title="<?php echo $this->config->item('email_title'); ?>" /></a>
               </h1>   
                
                <div class="head_search">
                	<form name="search" action="search/all" method="get">
                    	<input type="text" class="head_input" name="item" id="search_items" placeholder="<?php if($this->lang->line('land_lookingfor') != '') { echo stripslashes($this->lang->line('land_lookingfor')); } else echo "What are you looking for?"; ?>" autocomplete="off" />
                    	<input type="submit" class="search_butn" value="<?php if($this->lang->line('land_search') != '') { echo stripslashes($this->lang->line('land_search')); } else echo "Search"; ?>" />
                        <div id="sugglist"></div>
                    </form>
                </div>
                <ul class="header_links">
                	<li class="regist-popup"><a id="try-1" onClick="return displayfunction('details','details_parent');" href="javascript:void(0);" ><?php if($this->lang->line('user_signin') != '') { echo stripslashes($this->lang->line('user_signin')); } else echo "Sign In"; ?></a></li>
                    <li class="divide"><a href="cart"><span class="cart_img"></span><?php if($this->lang->line('comm_cart') != '') { echo stripslashes($this->lang->line('comm_cart')); } else echo "Cart"; ?><span class="cart_count"><?php echo $MiniCartViewSet; ?></span></a></li>
                </ul>
            </div>
        </div>
        <div class="menu_navigation">
        	<div class="browse-navigation-wrap">
            	<div class="browse-navigation">
                	<ul>
                     <?php 
					 	 $i=0;  foreach ($mainCategories->result() as $row){
						if ($row->cat_name != ''){ 
						$commentData = $this->category_model->get_all_counts($row->id,''); 
						if($commentData[0]['disp']>0){
							if($i<8)
							{
                      ?>
                    	<li><a href="category-list/<?php echo $row->id;?>-<?php echo $row->seourl;?>"><?php echo $row->cat_name;?></a></li>
                       <?php }
					   else if($i>7){$cnt=1;}
					   $i++;
						
						}}
                      }
                      if($cnt==1)
					  {
					  ?>
                      <li class="more_down more-display"><a href="#"><?php if($this->lang->line('com_more') != '') { echo stripslashes($this->lang->line('com_more')); } else echo "More"; ?></a>
   <div  class="more-dropdown display-view" style="left:0px; float:right; position:absolute; top:54px; z-index:999;">
   <ul>
				<?php 
					 $i=0;  foreach ($mainCategories->result() as $row){
						if ($row->cat_name != ''){ 
						$commentData = $this->category_model->get_all_counts($row->id,''); 
						if($commentData[0]['disp']>0){
							if($i>7)
							{
                      ?>
                    	<li><a href="category-list/<?php echo $row->id;?>-<?php echo $row->seourl;?>"><?php echo $row->cat_name;?></a></li>
                       <?php }
					   $i++;
						
						}}
                      }
                      
					  ?>
                        
                        </ul></div> 
                        
                        </li>
                    <?php }?>
                    </ul>
                    
                </div>
            </div>
        </div>
     </header>
<!-- header_end -->
<!-- banner_starts -->
<div class="banner" <?php if($recentFavorites[0]['seller_banner']!=''){ ?>style="background-image:url(images/banner/<?php echo $recentFavorites[0]['seller_banner']; ?>)" <?php } ?>>
    	<div class="main">
			<h1><?php echo $this->config->item('banner_description'); ?></h1>
            </div>
            <?php if($FavoriteShops !=''){ ?>
	        <div class="image-footer-container">
            <div class="main">
				<?php $FavShops=explode(',',rtrim($FavoriteShops,',')); ?>
                <?php echo $FavoriteShopsProducts[$FavShops[0]]['image']; ?>
              	<?php if(count($FavoriteShopsProducts[$FavShops[0]])>0){ ?> 
                        <a href="shop-section/<?php echo $recentFavorites[0]['shop_seourl']; ?>">
                            <img class="bannner-autor" src="images/<?php if($recentFavorites[0]['thumbnail']!=''){ echo 'users/thumb/'.$recentFavorites[0]['thumbnail']; }else{ echo 'default_avat.png';} ?>" />
                            <div class="seller-banner">
                            <span class="banner-text">
                                 <?php echo $recentFavorites[0]['full_name']; ?> <em><?php if($this->lang->line('com_more') != '') { echo stripslashes($this->lang->line('com_more')); } else echo "More"; ?>of</em>
                                 <span class="featured-shop-name"> <?php echo $recentFavorites[0]['shop_name']; ?></span></span><br>
                                 <em style=" font-family: 'GeorgiaRegular';"><?php echo $recentFavorites[0]['city']; ?></em>
                            </div>
                        </a>
                        
                        <ul style="float:right" class="seller-links">
                        <?php if(count($FavoriteShopsProducts[$FavShops[0]])>4){ $cnt=4;}else{$cnt=count($FavoriteShopsProducts[$FavShops[0]]);} for($l=0;$l<$cnt;$l++){  ?>
                        <?php $img=explode(',',$FavoriteShopsProducts[$FavShops[0]][$l]['image']); ?>                        
                        <li>                        
                            <a href="products/<?php echo $FavoriteShopsProducts[$FavShops[0]][$l]['seourl']; ?>">
                                <div class="seller-outer">
                                    <div class="seller-inner">
                                        <img width="170" height="135"  src="images/product/list-image/<?php echo $img[0]; ?>" />
                                    </div>
                                </div>
                            </a>
                        </li>
                        <?php } ?>                       
                        <li>
                            <a href="shop-section/<?php echo $recentFavorites[0]['shop_name']; ?>">
                                <div class="seller-outer count-box">
                                    <div class="seller-inner">
                                        <span class="count-number"><?php echo count($FavoriteShopsProducts[$FavShops[0]]); ?></span>
                                        <?php if($this->lang->line('shop_items') != '') { echo stripslashes($this->lang->line('shop_items')); } else echo "items"; ?>
                                    </div>
                                </div>
                            </a>
                        </li>
                    </ul>
                    <?php } ?>
               
        </div>  </div>   
  			<?php } ?>      
        </div>  

<!-- banner_ends -->
<!--  recent favorites -->
<?php if($FavShops > 0){ ?>
<div class="recent_favour">
    	<div class="main">
        	<h2><?php if($this->lang->line('land_rfavorites') != '') { echo stripslashes($this->lang->line('land_rfavorites')); } else echo "Recent Favorites"; ?></h2>
            <p class="sub-head"><?php if($this->lang->line('land_marketplace') != '') { echo stripslashes($this->lang->line('land_marketplace')); } else echo "Discover finds from around the marketplace"; ?>.</p>
            <ul class="trending-listings">
            	<?php #$FavShops=explode(',',rtrim($FavoriteShops,',')); ?>
            	<?php  for($i=1;$i<count($FavShops);$i++){ ?>
                 <?php $img=explode(',',$FavoriteShopsProducts[$FavShops[$i]][0]['image']); ?>      
            		<li class="trending-listing">
                	<a href="products/<?php echo $FavoriteShopsProducts[$FavShops[$i]][0]['seourl']; ?>" class="listing-image">
                    	<img src="images/product/<?php echo $img[0]; ?>" />
                    	<div class="listing-info">
                        <?php if($FavoriteShopsProducts[$FavShops[$i]][0]['price']!= 0.00){ $price=$FavoriteShopsProducts[$FavShops[$i]][0]['price']; $pls=''; } else{ $price=$FavoriteShopsProducts[$FavShops[$i]][0]['pricing']; $pls='+'; } ?>
                        	<span class="listing-price">
                            <span class="currency-symbol"><?php echo $currencySymbol;?></span>
                            <span class="currency-value"><?php echo number_format($currencyValue*$price,2); echo $pls; ?></span> 
                            <span class="currency-code"><?php echo $currencyType;?></span></span>
                            <span class="listing-title"><?php echo $FavoriteShopsProducts[$FavShops[$i]][0]['product_name']; ?></span>
                        </div>
                    </a>
                    <ul class="related-listings">
                    	<?php if(count($FavoriteShopsProducts[$FavShops[$i]])>2){ $cnt=3;}else{$cnt=count($FavoriteShopsProducts[$FavShops[$i]]);} for($l=1;$l<$cnt;$l++){  ?>
                        <?php $img=explode(',',$FavoriteShopsProducts[$FavShops[$i]][$l]['image']); ?>                        
                    	<li>                        
                        	<a href="products/<?php echo $FavoriteShopsProducts[$FavShops[$i]][$l]['seourl']; ?>">
                            	<div class="thumbnail-outer">
                                	<div class="thumbnail-inner">
                                    	<img src="images/product/list-image/<?php echo $img[0]; ?>" />
                                    </div>
                                </div>
                            </a>
                        </li>
                        <?php } ?>
                        <li class="shop-listing-count">
                        	<div class="thumbnail-outer count-box">
                            	<div class="thumbnail-inner">
                                	<a href="shop-section/<?php echo $recentFavorites[$i]['shop_seourl']; ?>" class="shop-listing-count">
                                    	<span class="listing-count"><?php echo count($FavoriteShopsProducts[$FavShops[$i]]); ?></span><?php if($this->lang->line('shop_items') != '') { echo stripslashes($this->lang->line('shop_items')); } else echo "items"; ?>
                                    </a>
                                </div>
                            </div>
                        </li>
                    </ul>
                    <div class="about-shop clear">
                    <?php if($recentFavorites[$i]['thumbnail']!=''){ $profile_pic='users/thumb/'.$recentFavorites[$i]['thumbnail']; } else { $profile_pic='default_avat.png';}?>
                    	<a href="shop-section/<?php echo $recentFavorites[$i]['shop_seourl']; ?>">
                        	<span class="owner-details">
                            	<span class="about-image"><img src="images/<?php echo $profile_pic; ?>" /></span>
                                <em><?php if($this->lang->line('user_from') != '') { echo stripslashes($this->lang->line('user_from')); } else echo 'From'; ?></em>
                                <span class="shop-name"><?php echo $recentFavorites[$i]['shop_name']; ?></span><br />
                                <?php if($recentFavorites[$i]['city']!=''){ ?>
                                <em><?php if($this->lang->line('prod_in') != '') { echo stripslashes($this->lang->line('prod_in')); } else echo 'in'; ?></em>
                                <span class="location"><?php echo $recentFavorites[$i]['city']; ?></span><br />
                                <?php } ?>
                                <span class="reviews">
                                	<div class="stars small" style="width: <?php echo $recentFavorites[$i]['shop_ratting']*17.2 ?>px !important;"> </div>
                            	</span> 
                            	<span class="reviews-numbers">
                					<span class="review-num"><?php echo $recentFavorites[$i]['review_count']; ?></span> <?php if($this->lang->line('shopsec_reviews') != '') { echo stripslashes($this->lang->line('shopsec_reviews')); } else echo "Reviews"; ?>
              					</span>
                            
                            
                            </span>
                                                        
                        </a>
                    </div>
                </li>
                <?php }  ?>
            </ul>
        </div>
    </div>
    <?php } ?>
<!-- recent favorites -->
<!--Community Tastemakers-->
<?php $tm=0; if(sizeof($pickedUsers) > 0){ ?>
<div class="community-tastemaker">
	<div class="main">
        <div id="tastemakers">
            <div class="container section clearfix">
                <div class="index_headline">
                    <h2><?php if($this->lang->line('land_tastemakers') != '') { echo stripslashes($this->lang->line('land_tastemakers')); } else echo "Community Tastemakers"; ?></h2>
                    <p class="sub-head">
                    <?php if($this->lang->line('land_fromthese') != '') { echo stripslashes($this->lang->line('land_fromthese')); } else echo "Get inspiration from these"; ?> <?php echo $this->config->item('email_title'); ?> <?php if($this->lang->line('land_memberspicks') != '') { echo stripslashes($this->lang->line('land_memberspicks')); } else echo "members' top picks."; ?>
                    </p>
                    <a name="tastemakers"></a>
                </div>
               
                <ul id="tastemaker-list">
                	<?php  foreach($pickedUsers as $UsersPick){ 
					if(count($pickedUsersFavorites[$UsersPick['user_id']])!=0){
					
					$tm++; ?> 
                    <?php 
					if($UsersPick['thumbnail']!=''){ 
						$profile_pic='users/thumb/'.$UsersPick['thumbnail']; 
					}else { 
						$profile_pic='default_avat.png';
					}
					?>
                    <?php if($tm>4){break;} ?>                   
                    <li class="tastemaker">
                        <div class="tastemaker-desc">
                            <div class="tastemaker-avatar trigger-action-toolbox" data-source="hp_tastemaker">
                                <a href="#" class="favorite-0">
                                    <img  width="170" height="135" src="images/<?php echo $profile_pic; ?>">
                                </a>
                            </div>
                            <p class="tastemaker-name">
                            	<a class="member-name" href="people/<?php echo $UsersPick['user_name']; ?>/favorites/items-i-love"><?php echo $UsersPick['full_name']; ?><?php if($this->lang->line('seller_s') != '') { echo stripslashes($this->lang->line('seller_s')); } else echo "'s"; ?></a> <?php if($this->lang->line('user_favorites') != '') { echo stripslashes($this->lang->line('user_favorites')); } else echo "Favorites"; ?>
                            </p>
                        </div>
                        <div class="tastemaker-favorites">
                        	<?php  
							#echo "<pre>"; print_r($FavoriteShopsProducts[$UsersPick['user_id']]);
								$itemcount=0; $listitems=0;
								for($i=0;$i<count($pickedUsersFavorites[$UsersPick['user_id']]);$i++){
										if($listitems<4){
										$img=explode(',',$pickedUsersFavorites[$UsersPick['user_id']][$i]->image); 
								?>
                            <a href="people/<?php echo $UsersPick['user_name']; ?>/favorites/items-i-love" class="favorite-<?php echo $i; ?>">
                            	<img  width="75" height="75" alt="<?php echo $pickedUsersFavorites[$UsersPick['user_id']][$i]->product_name; ?>" src="images/product/list-image/<?php echo $img[0]; ?>">
                            </a>
                            <?php } $itemcount=$itemcount+1; $listitems++;   }?>
                        </div>
                        <div class="tastemaker-link clear">
                            <a class="title-text" href="people/<?php echo $UsersPick['user_name']; ?>/favorites/items-i-love">
                                <h4><?php echo $UsersPick['full_name']; ?><?php if($this->lang->line('seller_s') != '') { echo stripslashes($this->lang->line('seller_s')); } else echo "'s"; ?> <?php if($this->lang->line('user_favorites') != '') { echo stripslashes($this->lang->line('user_favorites')); } else echo "Favorites"; ?></h4>
                                <p class="favorites-number"><?php echo count($pickedUsersFavorites[$UsersPick['user_id']]); ?> <?php if($this->lang->line('user_items') != '') { echo stripslashes($this->lang->line('user_items')); } else echo "items"; ?></p>
                                <span class="arrow"></span>
                            </a>
                        </div>
                    </li>
                    <?php } }?>
                </ul>
                        <!--<div id="friend-finder">
                            <a class="find-friends" href="#">
                            <p>What items do your favorite brands and bloggers love?</p>
                            <span class="btn btn-primary">Browse Their Favorites</span>
                            </a>
                        </div>-->
                    </div>
        </div>
 	</div>
</div>
<?php } ?>
<!--Community Tastemakers-->

<!--Stories--> 
<?php foreach($testimonials as $testiMoni){ ?>
<?php if($FavShops[0]!=$testiMoni->seller_id && $testiMoni->seller_banner!=''){ ?>
<div class="stories-abt-seller">
    <div id="stories">
        <div class="about-photo lazy-bg"  style="background-image: url(images/banner/<?php echo $testiMoni->seller_banner; ?>);"></div>
            <div class="container section clearfix">
                <div class="seller-story">
                    <a class="seller-photo lazy-bg" href="view-profile/<?php echo $testiMoni->user_name; ?>" style="background-image: url(images/<?php if($testiMoni->thumbnail!=''){ echo 'users/thumb/'.$testiMoni->thumbnail; }else{ echo 'default_avat.png';} ?>); background-size:100% 100%;"></a>
                    <a href="<?php echo base_url().'blog/'.$testiMoni->post_name; ?>" target="_blank"><p class="about-desc">"<?php echo $testiMoni->post_title; ?>"</p></a>
                    <span class="owner-details">
                    <em>Meet</em>
                    <a class="shop-name" href="shop-section/<?php echo $testiMoni->shopurl; ?>">
                    <span class="user-name"><?php echo $testiMoni->full_name; ?></span> of <?php echo $testiMoni->shopname; ?></a>
                    <em>in</em> <span class="location"><?php echo $testiMoni->city; ?></span>
                    </span>
                </div>
        </div>
    </div>
</div>
<?php break;} } ?>
<!--Stories-->


<!--Trust-->
<div class="recent_favour">
  <div class="main">



<div id="trust">
        <div class="container section clearfix">
            <div class="trust1 col col4 lazy-bg"  style="background-image: url(images/trust-1.png);">
                <span class="trust-illo"></span>
                <h3><?php if($this->lang->line('land_satisfied') != '') { echo stripslashes($this->lang->line('land_satisfied')); } else echo 'Satisfied Customers'; ?></h3>
                <p>
                    <?php if($this->lang->line('land_reviews') != '') { echo stripslashes($this->lang->line('land_reviews')); } else echo 'Get to know shops and items with reviews from our community'; ?>.
                </p>
            </div>
            <div class="trust2 col col4 lazy-bg"  style="background-image: url(images/trust-2.png);">
                <span class="trust-illo"></span>
                <h3><?php if($this->lang->line('land_passionate') != '') { echo stripslashes($this->lang->line('land_passionate')); } else echo 'Sales & Promotions'; ?></h3>
                <p>
                    <?php if($this->lang->line('land_craftsmanship') != '') { echo stripslashes($this->lang->line('land_craftsmanship')); } else echo 'Discover Sales and Promtions in one easy place'; ?>.
                </p>
            </div>
            <div class="trust3 col col4 col-last lazy-bg"  style="background-image: url(images/trust-2.png);">
                <span class="trust-illo"></span>
                <h3><?php if($this->lang->line('land_transactions') != '') { echo stripslashes($this->lang->line('land_transactions')); } else echo 'Secure Transactions'; ?></h3>
                <p>
                    <?php if($this->lang->line('land_confident') != '') { echo stripslashes($this->lang->line('land_confident')); } else echo 'Feel confident knowing our Trust &amp; Safety team is here to protect you'; ?>.
                </p>
            </div>
<!-- 
            <div class="promo-ef clear lazy-bg"  style="background-image: url(images/weddings-texture.png);">
    <div class="promo-ef-center signup-message">
        <div class="signup-message-wrap">
            <h3 id="shopsy_finds_signup_message">
                
                    <?php if($this->lang->line('land_trends') != '') { echo stripslashes($this->lang->line('land_trends')); } else echo "Get top trends and fresh editors' picks"; ?><br>
                    <?php if($this->lang->line('land_inbox') != '') { echo stripslashes($this->lang->line('land_inbox')); } else echo "in your inbox with"; ?> <?php echo $this->config->item('email_title'); ?> <?php if($this->lang->line('user_finds') != '') { echo stripslashes($this->lang->line('user_finds')); } else echo "Finds"; ?>.
                
            </h3>
        </div>
        <span class="promo-image signup lazy-bg"  style="background-image: url(images/your-feed-finds.png);"></span>
        <div class="form-wrap">
 -->           
<!--<form method="post" class="subscribe-form" onSubmit="return subscribe_user();" action="site/user/subscribeUser">
    <input type="hidden" name="campaign_slug" value="finds">
    <input type="hidden" name="subscribe" value="true">
    <input type="hidden" name="_nnc" value="1:fb80f7eda898690f942b1723441434096f00f592ecb3ca292015ae5e7f37a26c:cd7b8b59538321bae92b6ac8ac409559ecea5424929bee28b406f4e87c6e877e" class="hidden csrf">

        <div class="subscribe-content-inner">
            <input type="text" class="text" style="margin:0" name="email" id="email-text"><br><span style="color:#F00;" class="redFont" id="emailErrr"></span>
        </div>
    
    <div class="sub-spin">
        <button type="submit" class="btn-primary subscribe-link">Subscribe</button>
    </div>
</form>-->  
<!--
<form method="post" class="subscribe-form" action="site/user/subscribeUser">
	<div class="subscribe-content-inner">
        <input type="text" class="text" placeholder="<?php if($this->lang->line('land_email') != '') { echo stripslashes($this->lang->line('land_email')); } else echo 'Enter Your E-mail address'; ?>" style="margin:0" name="emaill" id="emailtext"><br>
        
    </div>
    <div class="sub-spin">
        <button type="submit" class="btn-primary subscribe-link" onClick="return subscribe_user();"><?php if($this->lang->line('land_subscribe') != '') { echo stripslashes($this->lang->line('land_subscribe')); } else echo 'Subscribe'; ?></button>
    </div>
    <br>
	<div >
    <span id="suscribeemailErr" style="background:#FFEEEE;border:1px solid #FFC0CB;color:#000000;color:#F00;font-size: 12px !important;padding: 4px 5px;display:none;"></span>
    <span id="SpecialErr" style="background:#FFEEEE;border:1px solid #FFC0CB;color:#000000;color:#F00;font-size: 12px !important;padding: 4px 5px;display:none;"></span>
    </div> 
</form>
 
</div>
    </div>
  
</div>
        </div>
    </div>

</div>
</div>
  -->

<!--Trust- end-->

<div class="regional-setting" style="display:none;">
<div class="main">
<div style="text-align:left" class="regional-setting-left">
<h5><?php if($this->lang->line('land_regionalsettings') != '') { echo stripslashes($this->lang->line('land_regionalsettings')); } else echo "Hi! We'd like to set these regional settings for you"; ?>.</h5>
<h3><?php if($this->lang->line('land_english') != '') { echo stripslashes($this->lang->line('land_english')); } else echo "English (US), $ United States Dollar USD ,India"; ?> </h3>
</div>
<div class="regional-setting-right">
<input class="ok-button" value="<?php if($this->lang->line('land_okay') != '') { echo stripslashes($this->lang->line('land_okay')); } else echo "okay"; ?>" type="button">
<input class="canceling-button3" value="<?php if($this->lang->line('land_nothanks') != '') { echo stripslashes($this->lang->line('land_nothanks')); } else echo "No thanks"; ?>" type="button">
</div>
</div>
</div>

    </footer>
<script type="text/javascript">
function loginVal(){ 
	$('#loginloadErr').show();
	$("#emailAddr_Warn").html('');
	$("#password_Warn").html('');
	
	var emailAddr = $("#emailAddr").val();
	var password = $("#password").val();
	
	if(emailAddr.length==0){
	$("#emailAddr_Warn").html('This Field required');
	$('#loginloadErr').hide();
	return false;
	}else if(password==''){
	$("#password_Warn").html('This Field required');
	$('#loginloadErr').hide();
	return false;
	}
	//return false;
}
</script>

<script type="text/javascript"><!--
 $(document).ready(function() {
    $("#emailtext").blur(function() {
		 $("#msgbox").html('');
		var a = $("#emailtext").val();
		var filter = /^[a-zA-Z0-9]+[a-zA-Z0-9_.-]+[a-zA-Z0-9_-]+@[a-zA-Z0-9]+[a-zA-Z0-9.-]+[a-zA-Z0-9]+.[a-z]{2,4}$/;
		if(filter.test(a)) {
        //remove all the class add the messagebox classes and start fading
        //$("#msgbox").removeClass().addClass('messagebox').text('Checking...').fadeIn("slow");
        //check the username exists or not from ajax keyup mouseout

        $.post("site/user/check_user_availability",{ emaill:$(this).val() } ,function(data) {
            if(data=='no') {
                $("#msgbox").fadeTo(200,0.1,function() {  //start fading the messagebox

                    //add message and change the class of the box and start fading
                    $(this).html('Email Id is Already exists').addClass('messageboxerror').fadeTo(900,1);
                });

            }
            else if(data=='yes') {
                $("#msgbox").fadeTo(200,0.1,function() {  //start fading the messagebox
                    //add message and change the class of the box and start fading
                    $(this).html('Email Id is Available').addClass('messageboxok').fadeTo(900,1);    
                });
            }
        });

		}
		/*else{
		$("#msgbox").fadeTo(200,0.1,function() {  //start fading the messagebox
		//add message and change the class of the box and start fading
		$(this).html('Please enter valid email id').addClass('messageboxerror').fadeTo(900,1);    
		});
		}*/
    });

});  
</script>    
<?php $this->load->view('site/templates/footer');?>

<!-- footer_end -->
