Advertisement
Guest User

Shortlink instructions

a guest
Mar 21st, 2018
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.91 KB | None | 0 0
  1. the code that checks if the user went through a shortlinks is the following:
  2.  
  3. <?php if ((isset($_SESSION['shortlink']['solved']))&&($_SESSION['shortlink']['solved']==true)) { echo' YOUR_CODE_HERE '; } ?>
  4.  
  5. this is the same code that checks if the user went through the shortlink before adding the bonus to the claim ammount.
  6.  
  7. this is the code that displays the claimbutton in the base template and i will use it for the example:
  8. <div>
  9. <input type="submit" class="btn btn-primary btn-lg claim-button" value="Get reward!">
  10. </div>
  11. so if we put the php code arround this code snippet above we get this:
  12.  
  13. <?php if ((isset($_SESSION['shortlink']['solved']))&&($_SESSION['shortlink']['solved']==true)) { echo'
  14. <div>
  15. <input type="submit" class="btn btn-primary btn-lg claim-button" value="Get reward!">
  16. </div>
  17. '; } ?>
  18.  
  19. this means that the claim button will only appear if the user has gone through the shortlink.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement