Advertisement
Guest User

Untitled

a guest
Mar 12th, 2018
345
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.91 KB | None | 0 0
  1. <?php
  2. include('config.php');
  3.  
  4. global $db;
  5. $message = "";
  6.  
  7. if (isset($_POST['register'])) {
  8. $email = $_POST['email'];
  9. $password = $_POST['password'];
  10. $password = md5($password);
  11.  
  12. $username = strtolower($username);
  13. $db->Select("user_register", array('email' => $email));
  14.  
  15. if ($db->records == 0) {
  16. $result = $db->Insert(array('email' => $email,
  17. 'password' => $password,
  18. 'confirm_acc' => md5($email),
  19. 'active' => '0'), "user_register");
  20.  
  21. /* send email to confirm */
  22.  
  23. require 'SendGrid-API/vendor/autoload.php';
  24.  
  25.  
  26. // Login credentials
  27. $username = 'itassists';
  28. $password = '7810.JAYlove';
  29.  
  30.  
  31. $from = new SendGrid\Email("JioCoin Token", "register@jiocoins.io");
  32. $subject = "Confirm Your Registration";
  33. //echo $email;
  34. $to = new SendGrid\Email($email, $email);
  35.  
  36. $reglink=md5($email);
  37. $link="https://jiocoins.io/tokensale/confirm_registration.php?id=".$reglink;
  38.  
  39. $message = "<head>
  40. <meta charset=\"utf-8\">
  41. <meta name=\"viewport\" content=\"width=device-width\">
  42. <!--[if !mso]><!-->
  43. <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\">
  44. <!--<![endif]-->
  45. <title>Confirmed, you’re on the Twist beta waitlist!</title>
  46. <!-- Normalize Styles -->
  47. <style type=\"text/css\">
  48. /* What it does: Remove spaces around the email design added by some email clients. */
  49. /* Beware: It can remove the padding / margin and add a background color to the compose a reply window. */
  50. html,
  51. body {
  52. margin: 0 auto !important;
  53. padding: 0 !important;
  54. height: 100% !important;
  55. width: 100% !important;
  56. }
  57. /* What it does: Stops WebKit and Windows mobile clients resizing small text. */
  58. * {
  59. -ms-text-size-adjust: 100%;
  60. -webkit-text-size-adjust: 100%;
  61. }
  62. /* What is does: Centers email on Android 4.4 */
  63. div[style*=\"margin: 16px 0\"] {
  64. margin: 0 !important;
  65. }
  66. /* What it does: Remove spacing between tables in Outlook 2007 and up. */
  67. table,
  68. td {
  69. mso-table-lspace: 0pt !important;
  70. mso-table-rspace: 0pt !important;
  71. }
  72. /* What it does: Fixes webkit padding issue. Fix for Yahoo mail table alignment bug. */
  73. table {
  74. border-spacing: 0 !important;
  75. border-collapse: collapse !important;
  76. table-layout: fixed !important;
  77. margin: 0 auto !important;
  78. }
  79. /* What it does: Reset styles. */
  80. img {
  81. line-height: 100%;
  82. outline: none;
  83. text-decoration: none;
  84. /* Uses a smoother rendering method when resizing images in IE. */
  85. -ms-interpolation-mode: bicubic;
  86. /* Remove border when inside `a` element in IE 8/9/10. */
  87. border: 0;
  88. /* Sets a maximum width relative to the parent and auto scales the height */
  89. max-width: 100%;
  90. height: auto;
  91. /* Remove the gap between images and the bottom of their containers */
  92. vertical-align: middle;
  93. }
  94. /* What it does: Overrides styles added when Yahoo's auto-senses a link. */
  95. .yshortcuts a {
  96. border-bottom: none !important;
  97. }
  98. /* What it does: A work-around for iOS meddling in triggered links. */
  99. a[x-apple-data-detectors] {
  100. color: inherit !important;
  101. text-decoration: none !important;
  102. font-size: inherit !important;
  103. font-family: inherit !important;
  104. font-weight: inherit !important;
  105. line-height: inherit !important;
  106. }
  107. /* What it does: Neutralize whitespace for inline-block grids on iOS. */
  108. @media screen and (min-width: 600px) {
  109. .ios-responsive-grid {
  110. display: -webkit-box !important;
  111. display: flex !important;
  112. }
  113. /* Alternative method. Not needed if already using the .ios-responsive-grid flex workaround. */
  114. /* .ios-responsive-grid__unit class would need to be added to the inline-block
  115. <div>
  116. grid units */
  117. .ios-responsive-grid__unit {
  118. float: left;
  119. }
  120. }
  121. </style>
  122. <!--[if gte mso 9]>
  123. <style type=\"text/css\">
  124. /* What it does: Normalize space between bullets and text. */
  125. /* https://litmus.com/community/discussions/1093-bulletproof-lists-using-ul-and-li */
  126. li {
  127. text-indent: -1em;
  128. }
  129. </style>
  130. <![endif]-->
  131. <!-- Progressive Enhancements -->
  132. <style type=\"text/css\">
  133. /* Components */
  134. /* What it does: Hover styles for buttons */
  135. .button__td,
  136. .button__a {
  137. transition: all 100ms ease;
  138. }
  139. .button__td:hover,
  140. .button__a:hover {
  141. background: #1ab77b !important;
  142. }
  143. /* What it does: Mobile optimized styles */
  144. @media screen and (max-width: 599px) {
  145. /* Components */
  146. .tw-card { padding: 20px !important; }
  147. .tw-h1 { font-size: 22px !important; }
  148. /* Utilities */
  149. /* Display */
  150. .mobile-hidden {
  151. display: none !important;
  152. }
  153. .mobile-d-block {
  154. display: block !important;
  155. }
  156. /* Size */
  157. .mobile-w-full {
  158. width: 100% !important;
  159. }
  160. /* Margin */
  161. .mobile-m-h-auto {
  162. margin: 0 auto !important;
  163. }
  164. /* Padding */
  165. .mobile-p-0 {
  166. padding: 0 !important;
  167. }
  168. .mobile-p-t-0 {
  169. padding-top: 0 !important;
  170. }
  171. /* Images */
  172. .mobile-img-fluid {
  173. max-width: 100% !important;
  174. width: 100% !important;
  175. height: auto !important;
  176. }
  177. }
  178. </style>
  179. </head>
  180. <body style=\"background: #ffffff; height: 100% !important; margin: 0 auto !important; padding: 0 !important; width: 100% !important; ;\">
  181. <div style=\"display: none; font-size: 1px; line-height: 1px; max-height: 0; max-width: 0; opacity: 0; overflow: hidden; mso-hide: all;\">
  182. </div>
  183. <table cellpadding=\"0\" cellspacing=\"0\" style=\"background: #f2f2f2; border: 0; border-radius: 0; width: 100%;\">
  184. <tbody>
  185. <tr>
  186. <td align=\"center\" class=\"\" style=\"padding: 0 20px;\">
  187. <table cellpadding=\"0\" cellspacing=\"0\" style=\"background: #f2f2f2; border: 0; border-radius: 0;\">
  188. <tbody>
  189. <tr>
  190. <td align=\"center\" class=\"\" style=\"width: 600px;\">
  191. <table cellpadding=\"0\" cellspacing=\"0\" dir=\"ltr\" style=\"border: 0; width: 100%;\">
  192. <tbody>
  193. <tr>
  194. <td class=\"\" style=\"padding: 20px 0; text-align: center; ;\">
  195. <a href=\"https://www.jiocoins.io\" style=\"text-decoration: none; ;\" target=\"_blank\">
  196. <h2>JioCoin Token</h2>
  197. </a>
  198. </td>
  199. </tr>
  200. </tbody>
  201. </table>
  202. <table cellpadding=\"0\" cellspacing=\"0\" style=\"background: #ffffff; border: 0; border-radius: 4px; width: 100%;\">
  203. <tbody>
  204. <tr>
  205. <td align=\"center\" class=\"tw-card\" style=\"padding: 20px 50px;\">
  206. <table cellpadding=\"0\" cellspacing=\"0\" dir=\"ltr\" style=\"border: 0; width: 100%;\">
  207. <tbody>
  208. <tr>
  209. <td class=\"\" style=\"padding: 20px 0; text-align: center; ;\">
  210. <img alt=\"\" class=\" \" src=\"https://jiocoins.io/test/tokensale/img/jiocoins_150px.png\" style=\"border: 0; height: auto; max-width: 100%; vertical-align: middle; ;\" width=\"120px\" height=\"120px\">
  211. </td>
  212. </tr>
  213. </tbody>
  214. </table>
  215. <table cellpadding=\"0\" cellspacing=\"0\" dir=\"ltr\" style=\"border: 0; width: 100%;\">
  216. <tbody>
  217. <tr>
  218. <td class=\"\" style=\"padding: 20px 0; text-align: left; color: #474747; font-family: sans-serif;;\">
  219. <p style=\"margin: 20px 0;; font-size: 18px; mso-line-height-rule: exactly; line-height: 24px; margin: 30px 0;; ;\">
  220. <span style=\"font-weight: bold;;\">Confirm Your Registration!</span>
  221. </p>
  222. <p style=\"margin: 20px 0;; font-size: 14px; mso-line-height-rule: exactly; line-height: 24px; margin: 30px 0;; ;\">
  223. Welcome to Coin
  224. </p>
  225. <p style=\"margin: 20px 0;; font-size: 14px; mso-line-height-rule: exactly; line-height: 24px; margin: 30px 0;; ;\">
  226. Click the link bellow to complete verification:
  227. </p>
  228.  
  229. <a href=\"$link\" target=\"_blank\" style=\"background-color:#2c90e4; border: 1px solid #6070E9; border-radius: 4px; padding: 19px 27px; font-family: 'Source Sans Pro', Arial, Verdana, Tahoma, Geneva, sans-serif; color: #ffffff; font-size: 26px; line-height: 30px; text-decoration: none; white-space: nowrap; font-weight: 600;\">
  230. <font face=\"'Source Sans Pro', sans-serif\" color=\"#ffffff\" style=\"font-size: 26px; line-height: 30px; text-decoration: none; white-space: nowrap; font-weight: 600;\">
  231. <span style=\"font-family: 'Source Sans Pro', Arial, Verdana, Tahoma, Geneva, sans-serif; color: #ffffff; font-size: 26px; line-height: 30px; text-decoration: none; white-space: nowrap; font-weight: 600;\">Confirm Email</span>
  232. </font>
  233. </a>
  234.  
  235. <h4 style=\"color:red;margin-top:35px;\">Security Tips</h4>
  236.  
  237. <ul>
  238. <li> DO NOT give your password to anyone! </li>
  239. <li> Do Not call any phone number for someone claiming to be JioCoins Support! </li>
  240. <li> Do Not send any money to anyone claiming to be a member of JioCoins Support! </li>
  241. <li> Make Sure you are visiing https://jiocoins.io </li>
  242. </ul>
  243.  
  244. </td>
  245. </tr>
  246. </tbody>
  247. </table>
  248.  
  249. </td>
  250. </tr>
  251. </tbody>
  252. </table>
  253. <br><br>
  254. </td>
  255. </tr>
  256. </tbody>
  257. </table>
  258. </td>
  259. </tr>
  260. </tbody>
  261. </table>
  262. </body>";
  263.  
  264.  
  265. $content = new SendGrid\Content("text/html", ".$message.");
  266. $mail = new SendGrid\Mail($from, $subject, $to, $content);
  267.  
  268. $apiKey = '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';
  269. $sg = new SendGrid($apiKey);
  270.  
  271.  
  272. $response = $sg->client->mail()->send()->post($mail);
  273. /*echo $response->statusCode();
  274. print_r($response->headers());
  275. print_r($response->body());*/
  276.  
  277.  
  278.  
  279. if ($result) {
  280. $message = "<div class='alert alert-success'> Thanks For Registration. <a href='login.php'>Log In</a> </div>";
  281. } else {
  282. $db->lastError;
  283. }
  284. } else {
  285. $message = "<div class='alert alert-danger'> Username is already exist.!! </div>";
  286. }
  287.  
  288. }
  289. ?>
  290.  
  291. <!DOCTYPE html>
  292. <html>
  293.  
  294.  
  295. <!-- Mirrored from eagle-material-admin.bylancer.com/eagle/demo-7/pages/extra-page/register.html by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 01 Nov 2017 06:30:42 GMT -->
  296. <head>
  297. <meta charset="UTF-8">
  298. <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
  299. <title>Register | JioCoin Token </title>
  300. <!-- Favicon-->
  301. <link rel="icon" href="../img/logo--dark.png" type="image/x-icon">
  302.  
  303. <!-- Bootstrap Core Css -->
  304. <link href="plugins/bootstrap/css/bootstrap.css" rel="stylesheet">
  305.  
  306. <!-- Waves Effect Css -->
  307. <link href="plugins/node-waves/waves.css" rel="stylesheet"/>
  308.  
  309. <!-- Animation Css -->
  310. <link href="plugins/animate-css/animate.css" rel="stylesheet"/>
  311.  
  312. <!-- Custom Css -->
  313. <link href="assets/css/style.css" rel="stylesheet">
  314. </head>
  315.  
  316. <body class="register-ac">
  317. <div class="register-box">
  318. <div class="card">
  319. <div class="body">
  320. <div class="row">
  321. <div class="col-lg-12">
  322. <div class="login-logo">
  323. <img src="img/jiocoins_150px.png" alt="Jio Coins Token" width="100px" height="100px" class="img-responsive img-circle align-center">
  324. <h3>Jio Coin</h3>
  325. </div>
  326. </div>
  327. </div>
  328. <form name='register' id="register" method="POST">
  329. <div class="msg">Create an account</div>
  330. <div class="input-group addon-line">
  331. <span class="input-group-addon">
  332. <i class="material-icons">email</i>
  333. </span>
  334. <div class="form-line">
  335. <input type="email" class="form-control" name="email" placeholder="Your Email Address" required>
  336. </div>
  337. </div>
  338. <div class="input-group addon-line">
  339. <span class="input-group-addon">
  340. <i class="material-icons">lock</i>
  341. </span>
  342. <div class="form-line">
  343. <input type="password" class="form-control" name="password" minlength="6"
  344. placeholder="Define Password" required>
  345. </div>
  346. </div>
  347. <div class="input-group addon-line">
  348. <span class="input-group-addon">
  349. <i class="material-icons">lock</i>
  350. </span>
  351. <div class="form-line">
  352. <input type="password" class="form-control" name="confirm" minlength="6"
  353. placeholder="Confirm Password" required>
  354. </div>
  355. </div>
  356. <div class="form-group">
  357. <input type="checkbox" name="terms" id="terms" class="filled-in chk-col-blue">
  358. <label for="terms">I agree with the <a href="#">terms and policy</a>.</label>
  359. </div>
  360.  
  361. <button name="register" id="register" class="btn btn-block btn-primary waves-effect" type="submit">
  362. REGISTER NOW
  363. </button>
  364.  
  365. <div class="m-t-25 m-b--5 align-center">
  366. <a href="login.php">You already have an account?</a>
  367. <?php echo $message; ?>
  368. </div>
  369. </form>
  370. </div>
  371. </div>
  372. </div>
  373.  
  374. <!-- CORE PLUGIN JS -->
  375. <script src="plugins/jquery/jquery.min.js"></script>
  376. <script src="plugins/bootstrap/js/bootstrap.js"></script>
  377. <script src="plugins/node-waves/waves.js"></script>
  378. <script src="plugins/jquery-slimscroll/jquery.slimscroll.js"></script>
  379.  
  380. <!--THIS PAGE LEVEL JS-->
  381. <script src="plugins/jquery-validation/jquery.validate.js"></script>
  382. <script src="assets/js/pages/examples/register.js"></script>
  383.  
  384. <!-- LAYOUT JS -->
  385. <script src="assets/js/demo.js"></script>
  386.  
  387. </body>
  388.  
  389.  
  390. <!-- Mirrored from eagle-material-admin.bylancer.com/eagle/demo-7/pages/extra-page/register.html by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 01 Nov 2017 06:30:42 GMT -->
  391. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement