Load more data on page scroll using jQuery, Ajax and PHP
Posted onby CodersMag Team
Pagination, also known as paging, is the process of dividing a document into discrete pages.The dynamic record is loaded from the server automatically while scrolling page down. Infinite scrolling is a user-friendly way to load additional content on the web application. In this post, We have share how to implement Load more data on page scroll using jQuery, Ajax and PHP. This is a very simple example, you can just copy paste and change according to your requirement.
Before started to implement the Load more data on page scroll using jQuery, Ajax and PHP look files structure:
- load-data-on-page-scroll-using-php-mysql-jquery
- css
- style.css
- shimmer.css
- images
- templates
- header.php
- footer.php
- config.php
- fetch_record.php
- index.php
- css
Step 1: Create the database and Table
Run the following script against MySQL to create the database news table.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
-- Table structure for table `news` CREATE TABLE `news` ( `id` int(11) NOT NULL, `title` varchar(255) DEFAULT 'NULL', `description` text NOT NULL, `name` varchar(255) NOT NULL, `email` varchar(255) NOT NULL, `user_pic` varchar(255) NOT NULL, `created_date` varchar(12) NOT NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1; -- Dumping data for table `news` INSERT INTO `news` (`id`, `title`, `description`, `name`, `email`, `user_pic`, `created_date`) VALUES (1, 'Lorem Ipsum is simply dummy text of the printing and typesetting industry.', 'Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry\'s standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum', 'Coders Mag', 'info@codersmag.com', 'blank-profile.png', '1569687279'), (2, 'It is a long established fact that a reader will be distracted', 'It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using \'Content here, content here\', making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for \'lorem ipsum\' will uncover many web sites still in their infancy. Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).', 'Web Team', 'info@web.com', 'user-default.jpg', '1569687279'), (3, 'There are many variations of passages of Lorem Ipsum', 'There are many variations of passages of Lorem Ipsum available, but the majority have suffered alteration in some form, by injected humour, or randomised words which don\'t look even slightly believable. If you are going to use a passage of Lorem Ipsum, you need to be sure there isn\'t anything embarrassing hidden in the middle of text. All the Lorem Ipsum generators on the Internet tend to repeat predefined chunks as necessary, making this the first true generator on the Internet. It uses a dictionary of over 200 Latin words, combined with a handful of model sentence structures, to generate Lorem Ipsum which looks reasonable. The generated Lorem Ipsum is therefore always free from repetition, injected humour, or non-characteristic words etc.', 'Alex', 'info@example.com', 'user-default.jpg', '1569687279'), (4, 'Contrary to popular belief, Lorem Ipsum is not simply random text', 'Contrary to popular belief, Lorem Ipsum is not simply random text. It has roots in a piece of classical Latin literature from 45 BC, making it over 2000 years old. Richard McClintock, a Latin professor at Hampden-Sydney College in Virginia, looked up one of the more obscure Latin words, consectetur, from a Lorem Ipsum passage, and going through the cites of the word in classical literature, discovered the undoubtable source. Lorem Ipsum comes from sections 1.10.32 and 1.10.33 of \"de Finibus Bonorum et Malorum\" (The Extremes of Good and Evil) by Cicero, written in 45 BC. This book is a treatise on the theory of ethics, very popular during the Renaissance. The first line of Lorem Ipsum, \"Lorem ipsum dolor sit amet..\", comes from a line in section 1.10.32.\r\n\r\nThe standard chunk of Lorem Ipsum used since the 1500s is reproduced below for those interested. Sections 1.10.32 and 1.10.33 from \"de Finibus Bonorum et Malorum\" by Cicero are also reproduced in their exact original form, accompanied by English versions from the 1914 translation by H. Rackham.', 'James', 'info@james.com', 'user-default.jpg', '1569687279'), (5, 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut', 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.', 'Sam', 'sam@example.com', 'blank-profile.png', '1569687279'), (6, 'Sed ut perspiciatis unde omnis iste natus', 'Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur', 'Adam', 'adam@example.com', 'user-default.jpg', '1569687279'), (7, 'At vero eos et accusamus et iusto odio dignissimos ducimus qui', 'At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga.', 'Nancy', 'nancy@example.com', 'user-default.jpg', '1569687279'), (8, 'On the other hand, we denounce with righteous indignatio', 'On the other hand, we denounce with righteous indignation and dislike men who are so beguiled and demoralized by the charms of pleasure of the moment, so blinded by desire, that they cannot foresee the pain and trouble that are bound to ensue; and equal blame belongs to those who fail in their duty through weakness of will, which is the same as saying through shrinking from toil and pain. These cases are perfectly simple and easy to distinguish. In a free hour, when our power of choice is untrammelled and when nothing prevents our being able to do what we like best, every pleasure is to be welcomed and every pain avoided. But in certain circumstances and owing to the claims of duty or the obligations of business it will frequently occur that pleasures have to be repudiated and annoyances accepted. The wise man therefore always holds in these matters to this principle of selection: he rejects pleasures to secure other greater pleasures, or else he endures pains to avoid worse pains', 'Marry', 'marry@example.com', 'user-default.jpg', '1569687279'), (9, 'injected humour, or non-characteristic words et', 'There are many variations of passages of Lorem Ipsum available, but the majority have suffered alteration in some form, by injected humour, or randomised words which don\'t look even slightly believable. If you are going to use a passage of Lorem Ipsum, you need to be sure there isn\'t anything embarrassing hidden in the middle of text. All the Lorem Ipsum generators on the Internet tend to repeat predefined chunks as necessary, making this the first true generator on the Internet. It uses a dictionary of over 200 Latin words, combined with a handful of model sentence structures, to generate Lorem Ipsum which looks reasonable. The generated Lorem Ipsum is therefore always free from repetition, injected humour, or non-characteristic words etc.', 'Tiger', 'tiger@example.com', 'blank-profile.png', '1569687279'), (10, 'The standard chunk of Lorem Ipsum used since the 1500s', 'The standard chunk of Lorem Ipsum used since the 1500s is reproduced below for those interested. Sections 1.10.32 and 1.10.33 from \"de Finibus Bonorum et Malorum\" by Cicero are also reproduced in their exact original form, accompanied by English versions from the 1914 translation by H. Rackham.', 'Naina', 'naina@example.com', 'user-default.jpg', '1569687279'), (11, 'All the Lorem Ipsum generators on the Internet tend', 'All the Lorem Ipsum generators on the Internet tend to repeat predefined chunks as necessary, making this the first true generator on the Internet. It uses a dictionary of over 200 Latin words, combined with a handful of model sentence structures, to generate Lorem Ipsum which looks reasonable. The generated Lorem Ipsum is therefore always free from repetition, injected humour, or non-characteristic words etc.', 'Dolly', 'dolly@example.com', 'user-default.jpg', '1569687279'), (12, 'Sed ut perspiciatis unde omnis iste natus', 'Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur', 'Adam', 'adam@example.com', 'blank-profile.png', '1569687279'), (13, 'It is a long established fact that a reader will be distracted', 'It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using \'Content here, content here\', making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for \'lorem ipsum\' will uncover many web sites still in their infancy. Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).', 'Web Team', 'info@web.com', 'user-default.jpg', '1569687279'), (14, 'The standard chunk of Lorem Ipsum used since the 1500s', 'The standard chunk of Lorem Ipsum used since the 1500s is reproduced below for those interested. Sections 1.10.32 and 1.10.33 from \"de Finibus Bonorum et Malorum\" by Cicero are also reproduced in their exact original form, accompanied by English versions from the 1914 translation by H. Rackham.', 'Naina', 'naina@example.com', 'user-default.jpg', '1569687279'), (15, 'The standard chunk of Lorem Ipsum used since the 1500s', 'The standard chunk of Lorem Ipsum used since the 1500s is reproduced below for those interested. Sections 1.10.32 and 1.10.33 from \"de Finibus Bonorum et Malorum\" by Cicero are also reproduced in their exact original form, accompanied by English versions from the 1914 translation by H. Rackham.', 'Naina', 'naina@example.com', 'user-default.jpg', '1569687279'), (16, 'injected humour, or non-characteristic words et', 'There are many variations of passages of Lorem Ipsum available, but the majority have suffered alteration in some form, by injected humour, or randomised words which don\'t look even slightly believable. If you are going to use a passage of Lorem Ipsum, you need to be sure there isn\'t anything embarrassing hidden in the middle of text. All the Lorem Ipsum generators on the Internet tend to repeat predefined chunks as necessary, making this the first true generator on the Internet. It uses a dictionary of over 200 Latin words, combined with a handful of model sentence structures, to generate Lorem Ipsum which looks reasonable. The generated Lorem Ipsum is therefore always free from repetition, injected humour, or non-characteristic words etc.', 'Tiger', 'tiger@example.com', 'user-default.jpg', '1569687279'), (17, 'Contrary to popular belief, Lorem Ipsum is not simply random text', 'Contrary to popular belief, Lorem Ipsum is not simply random text. It has roots in a piece of classical Latin literature from 45 BC, making it over 2000 years old. Richard McClintock, a Latin professor at Hampden-Sydney College in Virginia, looked up one of the more obscure Latin words, consectetur, from a Lorem Ipsum passage, and going through the cites of the word in classical literature, discovered the undoubtable source. Lorem Ipsum comes from sections 1.10.32 and 1.10.33 of \"de Finibus Bonorum et Malorum\" (The Extremes of Good and Evil) by Cicero, written in 45 BC. This book is a treatise on the theory of ethics, very popular during the Renaissance. The first line of Lorem Ipsum, \"Lorem ipsum dolor sit amet..\", comes from a line in section 1.10.32.\r\n\r\nThe standard chunk of Lorem Ipsum used since the 1500s is reproduced below for those interested. Sections 1.10.32 and 1.10.33 from \"de Finibus Bonorum et Malorum\" by Cicero are also reproduced in their exact original form, accompanied by English versions from the 1914 translation by H. Rackham.', 'James', 'info@james.com', 'blank-profile.png', '1569687279'); -- Indexes for table `news` ALTER TABLE `news` ADD PRIMARY KEY (`id`); -- AUTO_INCREMENT for table `news` ALTER TABLE `news` MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=18; |
Step 2: Database Configuration (config.php)
The config.php file is used to connect and fetch record from database. You should change your username, password and database name. See the config.php file below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
<?php $dbHostname = "localhost"; $dbName = "test_DB"; $dbUsername = "root"; $dbPassword = ""; try { $conn = new PDO("mysql:host=$dbHostname;dbname=$dbName", $dbUsername, $dbPassword); // set the PDO error mode to exception $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); } catch(PDOException $e) { echo "Connection failed: " . $e->getMessage(); } ?> |
Step 3: Load Data from Database (fetch_record.php)
The fetch_record.php file is called by the Ajax request on page scroll.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
<?php include_once('config.php'); $start = $_POST['start']; $limit = $_POST['limit']; try { $stmt = $conn->prepare("SELECT id, title, description, name, email, user_pic, created_date FROM news LIMIT $limit OFFSET $start"); $stmt->execute(); $query = $stmt->fetchAll(\PDO::FETCH_ASSOC); foreach ($query as $key => $element) { echo '<div class="card gedf-card" style="margin: 5px;"> <div class="card-header"> <div class="d-flex justify-content-between align-items-center"> <div class="d-flex justify-content-between align-items-center"> <div class="mr-2"> <img class="rounded-circle" width="45" src="images/'.$element['user_pic'].'" alt="'.$element['title'].'"> </div> <div class="ml-2"> <div class="h5 m-0">@'.$element['name'].'</div> <div class="h7 text-muted">'.$element['email'].'</div> </div> </div> <div> </div> </div> </div> <div class="card-body"> <div class="text-muted h7 mb-2"> <i class="fa fa-clock-o"></i> '.date('j M Y g:ia', $element['created_date']).'</div> <a class="card-link" href="JavaScript:Void(0);" style="color:#000000;"> <h5 class="card-title">'.$element['title'].'</h5> </a> <p class="card-text">'.$element['description'].'</p> </div> </div>'; } } catch (PDOException $e) { echo 'Connection failed: ' . $e->getMessage(); } ?> |
Step 4: Create index.php
Create a PHP file index.php to create HTML to display dynamically loaded record on page scroll.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
<?php include_once('templates/header.php'); ?> <section class="showcase"> <div class="container"> <div class="pb-2 mt-4 mb-2 border-bottom"> <h2>Load more data on page scroll using jQuery, Ajax and PHP</h2> </div> <div class="row"> <div class="col-md-12 gedf-main"> <span id="load-data"></span> <span id="load-data-msg"></span> </div> </div> </div> </section> <?php include_once('templates/footer.php'); ?> <script> jQuery(document).ready(function() { var limit = 5; var start = 0; var flag = "inactive"; function placeHolderShimmer(limit) { var bindHTML = ''; for(var counter=0; counter<limit; counter++) { bindHTML += '<div class="timeline-item">'; bindHTML += '<div class="animated-background">'; bindHTML += '<div class="background-masker header-top"></div>'; bindHTML += '<div class="background-masker header-left"></div>'; bindHTML += '<div class="background-masker header-right"></div>'; bindHTML += '<div class="background-masker header-bottom"></div>'; bindHTML += '<div class="background-masker subheader-left"></div>'; bindHTML += '<div class="background-masker subheader-right"></div>'; bindHTML += '<div class="background-masker subheader-bottom"></div>'; bindHTML += '<div class="background-masker content-top"></div>'; bindHTML += '<div class="background-masker content-first-end"></div>'; bindHTML += '<div class="background-masker content-second-line"></div>'; bindHTML += '<div class="background-masker content-second-end"></div>'; bindHTML += '<div class="background-masker content-third-line"></div>'; bindHTML += '<div class="background-masker content-third-end"></div>'; bindHTML += '</div>'; bindHTML += '</div>'; } jQuery("#load-data-msg").html(bindHTML); } // call function placeHolderShimmer(limit); function getData(limit, start) { jQuery.ajax({ url:"fetch_record.php", method:"POST", data:{limit:limit, start:start}, dataType: 'html', cache: false, success:function(html) { if(html == '') { jQuery('span#load-data-msg').html('<div class="text-muted" style="font-weight:bold; font-size:18px; text-align:center;">No more result yet!</div>'); flag = 'active'; } else { jQuery('span#load-data').append(html); jQuery('span#load-data-msg').html(""); flag = 'inactive'; } } }) } if(flag == 'inactive') { flag = 'active'; getData(limit, start); } jQuery(window).scroll(function() { if(jQuery(window).scrollTop() + jQuery(window).height() > jQuery("span#load-data").height() && flag == 'inactive') { placeHolderShimmer(limit); flag = 'active'; start = start + limit; setTimeout(function() { getData(limit, start); }, 1000); } }); }); </script> |
Step 5: jQuery & Ajax Code:
We will also need to use jQuery code in index.php to load pagination and make Ajax request to load more records.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 |
<script> jQuery(document).ready(function() { var limit = 5; var start = 0; var flag = "inactive"; function placeHolderShimmer(limit) { var bindHTML = ''; for(var counter=0; counter<limit; counter++) { bindHTML += '<div class="timeline-item">'; bindHTML += '<div class="animated-background">'; bindHTML += '<div class="background-masker header-top"></div>'; bindHTML += '<div class="background-masker header-left"></div>'; bindHTML += '<div class="background-masker header-right"></div>'; bindHTML += '<div class="background-masker header-bottom"></div>'; bindHTML += '<div class="background-masker subheader-left"></div>'; bindHTML += '<div class="background-masker subheader-right"></div>'; bindHTML += '<div class="background-masker subheader-bottom"></div>'; bindHTML += '<div class="background-masker content-top"></div>'; bindHTML += '<div class="background-masker content-first-end"></div>'; bindHTML += '<div class="background-masker content-second-line"></div>'; bindHTML += '<div class="background-masker content-second-end"></div>'; bindHTML += '<div class="background-masker content-third-line"></div>'; bindHTML += '<div class="background-masker content-third-end"></div>'; bindHTML += '</div>'; bindHTML += '</div>'; } jQuery("#load-data-msg").html(bindHTML); } // call function placeHolderShimmer(limit); function getData(limit, start) { jQuery.ajax({ url:"fetch_record.php", method:"POST", data:{limit:limit, start:start}, dataType: 'html', cache: false, success:function(html) { if(html == '') { jQuery('span#load-data-msg').html('<div class="text-muted" style="font-weight:bold; font-size:18px; text-align:center;">No more result yet!</div>'); flag = 'active'; } else { jQuery('span#load-data').append(html); jQuery('span#load-data-msg').html(""); flag = 'inactive'; } } }) } if(flag == 'inactive') { flag = 'active'; getData(limit, start); } jQuery(window).scroll(function() { if(jQuery(window).scrollTop() + jQuery(window).height() > jQuery("span#load-data").height() && flag == 'inactive') { placeHolderShimmer(limit); flag = 'active'; start = start + limit; setTimeout(function() { getData(limit, start); }, 1000); } }); }); </script> |
Step 6: Create header (header.php)
This view contains the header section of the webpage. The Bootstrap library is used to provide a better UI, so, include it in the header section.
Located at the top of a website, the header typically contains elements that include a company’s logo, website navigation, and contact information.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
<!DOCTYPE html> <html lang="en"> <head> <link rel="canonical" href="https://www.codersmag.com/" /> <meta name="author" content="CodersMag"> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <meta name="description" content=""> <meta name="author" content=""> <link rel="icon" type="image/ico" href="https://codersmag.com/demos/ci/assets/images/favicon.ico"> <title>Load more data on page scroll using jQuery, Ajax and PHP | Coders Mag</title> <!-- Bootstrap core CSS --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/css/bootstrap.min.css" /> <!-- Custom fonts for this template --> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.7.2/css/all.min.css" /> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/simple-line-icons/2.4.1/css/simple-line-icons.css" /> <link href="https://fonts.googleapis.com/css?family=Lato:300,400,700,300italic,400italic,700italic" rel="stylesheet" type="text/css"> <!-- Custom styles for this template --> <link href="css/style.css" rel="stylesheet"> <link href="css/shimmer.css" rel="stylesheet"> </head> <body> <!-- Navigation --> <nav class="navbar navbar-expand-lg navbar-dark bg-dark static-top header-bg-dark" style="background: ##FFFFFF!;"> <div class="container"> <a class="navbar-brand font-weight-bold" href="https://codersmag.com/"><h1>Coders Mag</h1></a> <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> <div class="collapse navbar-collapse" id="navbarResponsive"> <ul class="navbar-nav ml-auto"> <li class="nav-item active"> <a class="nav-link" href="https://codersmag.com/">Home <span class="sr-only">(current)</span> </a> </li> <li class="nav-item"> <a class="nav-link" href="https://codersmag.com/php-script-demos/">LIVE DEMO</a> </li> </ul> </div> </div> </nav> |
Step 7: Create a view file named footer.php
This view contains the footer section of the webpage.
- jQuery – needed by Bootstrap JavaScript.
- Bootstrap JavaScript – to make cool UI
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
<!-- Footer --> <footer class="footer bg-light footer-bg-dark"> <div class="container"> <div class="row"> <div class="col-lg-6 h-100 text-center text-lg-left my-auto"> <ul class="list-inline mb-2"> <li class="list-inline-item"> <a href="#">About</a> </li> <li class="list-inline-item">⋅</li> <li class="list-inline-item"> <a href="#">Contact</a> </li> <li class="list-inline-item">⋅</li> <li class="list-inline-item"> <a href="#">Terms of Use</a> </li> <li class="list-inline-item">⋅</li> <li class="list-inline-item"> <a href="#">Privacy Policy</a> </li> </ul> <p class="small mb-4 mb-lg-0" style="color: #E6ECF0;">Copyright © 2017 - <?php print date('Y', time());?> <a style="color: #E6ECF0;" href="https://codersmag.com/">CODERSMAG.COM</a> All rights reserved.</p> </div> <div class="col-lg-6 h-100 text-center text-lg-right my-auto"> <ul class="list-inline mb-0"> <li class="list-inline-item mr-3"> <a href="#"> <i class="fab fa-facebook fa-2x fa-fw"></i> </a> </li> <li class="list-inline-item mr-3"> <a href="#"> <i class="fab fa-twitter-square fa-2x fa-fw"></i> </a> </li> <li class="list-inline-item"> <a href="#"> <i class="fab fa-instagram fa-2x fa-fw"></i> </a> </li> </ul> </div> </div> </div> </footer> <!-- Bootstrap core JavaScript --> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.bundle.min.js"></script> </body> </html> |