Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                
<h2>Our Team</h2>
<div class="physicianList">
<input type='hidden' id='current_page' />
<input type='hidden' id='show_per_page' />
  <ul id="pagingBox">
    <li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/gE7cc5/user_4.jpg" alt="user_4" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Emily</strong></h6>
							<p class="text-info">Web Designer</p>
							<p>+880-168-240</p>
							<p>emily@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
    
    <li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/czhXAQ/user_1.jpg" alt="user_1" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Abram</strong></h6>
							<p class="text-info">Frontend Developer</p>
							<p>+880-168-240</p>
							<p>abram@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
	<li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/gE7cc5/user_4.jpg" alt="user_4" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Emily 2</strong></h6>
							<p class="text-info">Web Designer</p>
							<p>+880-168-240</p>
							<p>emily@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
    
    <li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/czhXAQ/user_1.jpg" alt="user_1" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Abram 2</strong></h6>
							<p class="text-info">Frontend Developer</p>
							<p>+880-168-240</p>
							<p>abram@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
	<li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/hnYLh5/team_member01.jpg" alt="team_member01" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Emily 3</strong></h6>
							<p class="text-info">Web Designer</p>
							<p>+880-168-240</p>
							<p>emily@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
    
    <li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/czhXAQ/user_1.jpg" alt="user_1" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Abram 3</strong></h6>
							<p class="text-info">Frontend Developer</p>
							<p>+880-168-240</p>
							<p>abram@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
	<li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/gE7cc5/user_4.jpg" alt="user_4" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Emily 4</strong></h6>
							<p class="text-info">Web Designer</p>
							<p>+880-168-240</p>
							<p>emily@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
    
    <li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://preview.ibb.co/c90NvQ/team_corporate_3.jpg" alt="team_corporate_3" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Abram 4</strong></h6>
							<p class="text-info">Frontend Developer</p>
							<p>+880-168-240</p>
							<p>abram@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
	<li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://preview.ibb.co/gnbvFQ/team_corporate_4.jpg" alt="team_corporate_4" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Emily 5</strong></h6>
							<p class="text-info">Web Designer</p>
							<p>+880-168-240</p>
							<p>emily@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
    
    <li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/czhXAQ/user_1.jpg" alt="user_1" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Abram 5</strong></h6>
							<p class="text-info">Frontend Developer</p>
							<p>+880-168-240</p>
							<p>abram@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
	<li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/gE7cc5/user_4.jpg" alt="user_4" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Emily 6</strong></h6>
							<p class="text-info">Web Designer</p>
							<p>+880-168-240</p>
							<p>emily@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
    
    <li>
      <div class="physicianBox">
					<div class="physicianPic">
						<img src="https://image.ibb.co/czhXAQ/user_1.jpg" alt="user_1" border="0">
					</div>
					
					<div class="physicianInfo">
						<div class="info">
							<h6><strong>Abram 6</strong></h6>
							<p class="text-info">Frontend Developer</p>
							<p>+880-168-240</p>
							<p>abram@gmail.com</p>
						</div>

					</div>
				
				<div class="physicianBio">
					<a class="showBioBtn" href="javascript:void(0)">Show BIO</a>
				</div>
			</div>
    </li>
	
	
  </ul>
</div>

<div id='page_navigation'></div>

              
            
!

CSS

              
                a{
  text-decoration: none;
}
.text-info {
    color: #31708f;
}
.physicianList ul{margin: 0; padding: 0; list-style: none;}
.physicianList ul li{display: inline-block; width: 240px; float: left; margin-right: 15px; margin-bottom: 15px;}
.physicianBox{
	border: 1px solid #ddd;
	color: #333;
	margin-bottom: 20px;
	position: relative;
	padding-bottom: 20px;
	background-color: #f5f5f5;
	
}
.physicianBox .physicianPic {
	padding: 15px 0;
	background-color: #fff;
  text-align: center;
}
.physicianBox .physicianPic img{
	border: 6px solid #f8f8f8;
	-webkit-border-radius: 50%;
    border-radius: 50%;
    transition: all 0.3s ease 0s;
    margin: 0 auto;
    height: 120px;
    width: 120px;
}
.physicianInfo{
	padding: 10px;
	text-align: center;
	border-top: 1px solid #eee;
}
.physicianInfo h6{font-size: 16px; margin:0;}
.physicianBox strong{color: #444;}
.physicianBox p{font-size: 13px; margin: 0; line-height: 22px;}
.physicianBio{position:absolute; right: 0; bottom: 3px;}
.physicianModal{text-align: center;}
.physicianModal .physicianPic img {
    border: 6px solid #f8f8f8;
	-webkit-border-radius: 50%;
    border-radius: 50%;
    transition: all 0.3s ease 0s;
    margin: 0 auto;
    height: 180px;
    width: 180px;
}
.physicianModal .info p, .physicianModal .info .text-info{margin: 0;}
.showBioBtn{background-color: #337ab7; padding: 5px 10px; color: #fff; font-size: 12px;}

/*Pagination CSS*/
#page_navigation {
  clear:both;
  margin: 20px 0;
}
#page_navigation a{
	padding:3px 6px;
	border:1px solid #2e6da4;
	margin:2px;
	color:black;
	text-decoration:none
}
.active_page{
	background:#337ab7;
	color:white !important;
}
              
            
!

JS

              
                jQuery(document).ready(function () {

		//Pagination JS
		//how much items per page to show
		var show_per_page = 4; 
		//getting the amount of elements inside pagingBox div
		var number_of_items = $('#pagingBox').children().size();
		//calculate the number of pages we are going to have
		var number_of_pages = Math.ceil(number_of_items/show_per_page);
		
		//set the value of our hidden input fields
		$('#current_page').val(0);
		$('#show_per_page').val(show_per_page);
		
		//now when we got all we need for the navigation let's make it '
		
		/* 
		what are we going to have in the navigation?
			- link to previous page
			- links to specific pages
			- link to next page
		*/
		var navigation_html = '<a class="previous_link" href="javascript:previous();">Prev</a>';
		var current_link = 0;
		while(number_of_pages > current_link){
			navigation_html += '<a class="page_link" href="javascript:go_to_page(' + current_link +')" longdesc="' + current_link +'">'+ (current_link + 1) +'</a>';
			current_link++;
		}
		navigation_html += '<a class="next_link" href="javascript:next();">Next</a>';
		
		$('#page_navigation').html(navigation_html);
		
		//add active_page class to the first page link
		$('#page_navigation .page_link:first').addClass('active_page');
		
		//hide all the elements inside pagingBox div
		$('#pagingBox').children().css('display', 'none');
		
		//and show the first n (show_per_page) elements
		$('#pagingBox').children().slice(0, show_per_page).css('display', 'block');
	
});



//Pagination JS

function previous(){
	
	new_page = parseInt($('#current_page').val()) - 1;
	//if there is an item before the current active link run the function
	if($('.active_page').prev('.page_link').length==true){
		go_to_page(new_page);
	}
	
}

function next(){
	new_page = parseInt($('#current_page').val()) + 1;
	//if there is an item after the current active link run the function
	if($('.active_page').next('.page_link').length==true){
		go_to_page(new_page);
	}
	
}
function go_to_page(page_num){
	//get the number of items shown per page
	var show_per_page = parseInt($('#show_per_page').val());
	
	//get the element number where to start the slice from
	start_from = page_num * show_per_page;
	
	//get the element number where to end the slice
	end_on = start_from + show_per_page;
	
	//hide all children elements of pagingBox div, get specific items and show them
	$('#pagingBox').children().css('display', 'none').slice(start_from, end_on).css('display', 'block');
	
	/*get the page link that has longdesc attribute of the current page and add active_page class to it
	and remove that class from previously active page link*/
	$('.page_link[longdesc=' + page_num +']').addClass('active_page').siblings('.active_page').removeClass('active_page');
	
	//update the current page input field
	$('#current_page').val(page_num);
}
              
            
!
999px

Console