SHARE
TWEET

Untitled

a guest Sep 4th, 2017 71 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <head>
  2. <style>
  3. .showAtDate { display: none; }
  4. </style>
  5.  
  6. //Modify the following and check it:
  7. <table id="itemsTable" class="showAtDate" data-limit="' . date("Y/m/d H:i:s", strtotime("+1 week")) . '">
  8.  
  9. //Added to the bottom
  10. <script type="text/javascript">
  11.                 $(function() {
  12.                         var currentDate = Date.now();
  13.                         $("table.showAtDate").each(function() {
  14.                                 var specifiedDateLimit = $(this).data(\'limit\');
  15.                                 var date = Date.parse(specifiedDateLimit);
  16.                                 if(!isNaN(date) && currentDate - date < 0) {
  17.                                        $(this).show();
  18.                                 }
  19.                         });
  20.                 });
  21.         </script>
RAW Paste Data
Top