Compare commits
3 Commits
d8220b21b8
...
3fbb6c99df
Author | SHA1 | Date | |
---|---|---|---|
3fbb6c99df | |||
1c1e322bd8 | |||
381e534e02 |
@@ -24,7 +24,7 @@ if (!isset($_SESSION['user'])) {
|
|||||||
<thead>
|
<thead>
|
||||||
<tr class="text-gray-800 dark:text-gray-50 brightness-125 text-xl font-bold text-center border-none">
|
<tr class="text-gray-800 dark:text-gray-50 brightness-125 text-xl font-bold text-center border-none">
|
||||||
<th></th>
|
<th></th>
|
||||||
<th>gLink</th>
|
<th>GLink</th>
|
||||||
<th>URL</th>
|
<th>URL</th>
|
||||||
<th>Edit</th>
|
<th>Edit</th>
|
||||||
<th>Delete</th>
|
<th>Delete</th>
|
||||||
|
@@ -33,7 +33,7 @@ if (!isset($_SESSION['user'])) {
|
|||||||
|
|
||||||
<div id="root" class="w-full h-full">
|
<div id="root" class="w-full h-full">
|
||||||
<div id="formspace" class="flex flex-wrap flex-row w-full bg-white dark:bg-black rounded-lg shadow-lg shadow-black/50">
|
<div id="formspace" class="flex flex-wrap flex-row w-full bg-white dark:bg-black rounded-lg shadow-lg shadow-black/50">
|
||||||
<form id="form" class="lg:w-1/2 sm:w-full justify-center" method="GET" action="result.php" onsubmit="return validate()">
|
<form id="form" class="lg:w-1/2 sm:w-full justify-center" method="POST" action="result.php" onsubmit="return validate()">
|
||||||
<div class="flex flex-wrap">
|
<div class="flex flex-wrap">
|
||||||
<label for="URL" class="text-2xl ml-4 font-rubik self-center dark:text-[#ffff59] dark:brightness-125">URL</label>
|
<label for="URL" class="text-2xl ml-4 font-rubik self-center dark:text-[#ffff59] dark:brightness-125">URL</label>
|
||||||
<span class="mandatory font-rubik self-center text-2xl">*</span>
|
<span class="mandatory font-rubik self-center text-2xl">*</span>
|
||||||
|
@@ -20,11 +20,11 @@ exit();
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mt-10 sm:mx-auto sm:w-full sm:max-w-sm">
|
<div class="mt-10 sm:mx-auto sm:w-full sm:max-w-sm">
|
||||||
<form class="space-y-6" action="login.php" method="GET">
|
<form class="space-y-6" action="login.php" method="POST">
|
||||||
<div>
|
<div>
|
||||||
<label for="email" class="block text-sm font-medium leading-6 text-gray-900">Email address</label>
|
<label for="email" class="block text-sm font-medium leading-6 text-gray-900">Email address</label>
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<input id="email" name="email" type="email" autocomplete="email" required class="block w-full rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
<input id="email" name="email" type="email" autocomplete="email" required class="px-2 block w-full rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
||||||
<div id="email-error" class="hidden mt-2 text-red-800 text-xs">
|
<div id="email-error" class="hidden mt-2 text-red-800 text-xs">
|
||||||
Invalid Email
|
Invalid Email
|
||||||
</div>
|
</div>
|
||||||
@@ -38,7 +38,7 @@ exit();
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-2 relative block">
|
<div class="mt-2 relative block">
|
||||||
<input id="password" name="password" type="password" autocomplete="off" required class="block w-11/12 rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
<input id="password" name="password" type="password" autocomplete="off" required class="px-2 block w-11/12 rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
||||||
|
|
||||||
<span id="pswd-invisible" class="absolute inset-y-0 right-0 flex items-center px-1 rounded-r-md">
|
<span id="pswd-invisible" class="absolute inset-y-0 right-0 flex items-center px-1 rounded-r-md">
|
||||||
<svg class="w-6 h-6 m-auto" fill="none" stroke="currentColor" viewBox="0 0 24 24"
|
<svg class="w-6 h-6 m-auto" fill="none" stroke="currentColor" viewBox="0 0 24 24"
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once 'db.inc.php';
|
require_once 'db.inc.php';
|
||||||
|
|
||||||
$email = $_GET['email'];
|
$email = $_POST['email'];
|
||||||
$password = $_GET['password'];
|
$password = $_POST['password'];
|
||||||
|
|
||||||
$session = init_cass_db();
|
$session = init_cass_db();
|
||||||
|
|
||||||
|
@@ -11,7 +11,7 @@ var glink = params.get("glink");
|
|||||||
|
|
||||||
var lat;
|
var lat;
|
||||||
var long;
|
var long;
|
||||||
var method = "GET";
|
var method = "POST";
|
||||||
var request;
|
var request;
|
||||||
|
|
||||||
function requestHandler() {
|
function requestHandler() {
|
||||||
|
16
result.php
16
result.php
@@ -33,21 +33,21 @@ ini_set('display_errors', 1);
|
|||||||
|
|
||||||
$session = init_cass_db();
|
$session = init_cass_db();
|
||||||
|
|
||||||
$url = $_GET["url"];
|
$url = $_POST["url"];
|
||||||
|
|
||||||
if (isset($_GET["restricted"])) {
|
if (isset($_POST["restricted"])) {
|
||||||
$is_geo = 1;
|
$is_geo = 1;
|
||||||
} else {
|
} else {
|
||||||
$is_geo = 0;
|
$is_geo = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($is_geo == 1) {
|
if ($is_geo == 1) {
|
||||||
$radius = $_GET["radius"];
|
$radius = $_POST["radius"];
|
||||||
|
|
||||||
$latitude = $_GET["latitude"];
|
$latitude = $_POST["latitude"];
|
||||||
$latitude = doubleval($latitude);
|
$latitude = doubleval($latitude);
|
||||||
|
|
||||||
$longitude = $_GET["longitude"];
|
$longitude = $_POST["longitude"];
|
||||||
$longitude = doubleval($longitude);
|
$longitude = doubleval($longitude);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -57,10 +57,10 @@ if (($matches == 0) || ($matches == false)) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$shortlink = $_GET["glink"];
|
$shortlink = $_POST["glink"];
|
||||||
|
|
||||||
if (isset($_GET["ttl"])) {
|
if (isset($_POST["ttl"])) {
|
||||||
$ttl = $_GET["ttl"];
|
$ttl = $_POST["ttl"];
|
||||||
} else {
|
} else {
|
||||||
$ttl = 0;
|
$ttl = 0;
|
||||||
}
|
}
|
||||||
|
@@ -20,11 +20,11 @@ exit();
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mt-10 sm:mx-auto sm:w-full sm:max-w-sm">
|
<div class="mt-10 sm:mx-auto sm:w-full sm:max-w-sm">
|
||||||
<form class="space-y-6" action="signup.php" method="GET"> <!--Change to php-->
|
<form class="space-y-6" action="signup.php" method="POST"> <!--Change to php-->
|
||||||
<div>
|
<div>
|
||||||
<label for="email" class="block text-sm font-medium leading-6 text-gray-900">Email address</label>
|
<label for="email" class="block text-sm font-medium leading-6 text-gray-900">Email address</label>
|
||||||
<div class="mt-2">
|
<div class="mt-2">
|
||||||
<input id="email" name="email" type="email" autocomplete="email" required class="block w-full rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
<input id="email" name="email" type="email" autocomplete="email" required class="px-2 block w-full rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
||||||
<div id="email-error" class="hidden mt-2 text-red-800 text-xs">
|
<div id="email-error" class="hidden mt-2 text-red-800 text-xs">
|
||||||
Invalid Email
|
Invalid Email
|
||||||
</div>
|
</div>
|
||||||
@@ -35,7 +35,7 @@ exit();
|
|||||||
<label for="password" class="block text-sm font-medium leading-6 text-gray-900">Password</label>
|
<label for="password" class="block text-sm font-medium leading-6 text-gray-900">Password</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-2 relative block">
|
<div class="mt-2 relative block">
|
||||||
<input id="password" name="password" type="password" autocomplete="off" required class="block w-11/12 rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
<input id="password" name="password" type="password" autocomplete="off" required class="px-2 block w-11/12 rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
||||||
|
|
||||||
<span id="pswd-invisible" class="absolute inset-y-0 right-0 flex items-center px-1 rounded-r-md">
|
<span id="pswd-invisible" class="absolute inset-y-0 right-0 flex items-center px-1 rounded-r-md">
|
||||||
<svg class="w-6 h-6 m-auto" fill="none" stroke="currentColor" viewBox="0 0 24 24"
|
<svg class="w-6 h-6 m-auto" fill="none" stroke="currentColor" viewBox="0 0 24 24"
|
||||||
@@ -80,7 +80,7 @@ exit();
|
|||||||
<label for="verify" class="block text-sm font-medium leading-6 text-gray-900">Retype Password</label>
|
<label for="verify" class="block text-sm font-medium leading-6 text-gray-900">Retype Password</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-2 relative block">
|
<div class="mt-2 relative block">
|
||||||
<input id="verify" name="verify" type="password" autocomplete="off" required class="block w-11/12 rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
<input id="verify" name="verify" type="password" autocomplete="off" required class="px-2 block w-11/12 rounded-md border-0 py-1.5 text-gray-900 shadow-sm ring-1 ring-inset ring-gray-300 placeholder:text-gray-400 focus:ring-2 focus:ring-inset focus:ring-indigo-600 sm:text-sm sm:leading-6">
|
||||||
|
|
||||||
<span id="check-pswd-invisible" class="absolute inset-y-0 right-0 flex items-center px-1 rounded-r-md">
|
<span id="check-pswd-invisible" class="absolute inset-y-0 right-0 flex items-center px-1 rounded-r-md">
|
||||||
<svg class="w-6 h-6 m-auto" fill="none" stroke="currentColor" viewBox="0 0 24 24"
|
<svg class="w-6 h-6 m-auto" fill="none" stroke="currentColor" viewBox="0 0 24 24"
|
||||||
|
@@ -1,10 +1,10 @@
|
|||||||
<?php
|
<?php
|
||||||
require_once 'db.inc.php';
|
require_once 'db.inc.php';
|
||||||
|
|
||||||
$email = $_GET['email'];
|
$email = $_POST['email'];
|
||||||
$email = strval($email);
|
$email = strval($email);
|
||||||
$username = $_GET['username'];
|
$username = $_POST['username'];
|
||||||
$password = $_GET['password'];
|
$password = $_POST['password'];
|
||||||
$id = rand(0,99999999);
|
$id = rand(0,99999999);
|
||||||
|
|
||||||
$hash = password_hash($password,PASSWORD_BCRYPT);
|
$hash = password_hash($password,PASSWORD_BCRYPT);
|
||||||
|
Reference in New Issue
Block a user