Made urls shorter and better

This commit is contained in:
alopexc0de 2012-10-07 20:34:33 -04:00
parent f35debca09
commit a1e15fe76a
2 changed files with 6 additions and 6 deletions

View File

@ -1,6 +1,6 @@
<?php <?php
$random=rand(); //your random ID key $random=rand(); //your random ID key
$path="url/"; //shortening url storage folder $path="."; //shortening url storage folder
$pagepath = "http://unps-gama.tk/short/"; $pagepath = "http://ugama.tk/short/";
$pagetitle = "Unps-gama.tk short"; $pagetitle = "Unps-gama.tk shortner";
?> ?>

View File

@ -18,7 +18,7 @@ if($_POST["submit"])
{ {
if(isset($_POST['dest'])) if(isset($_POST['dest']))
{ {
$myFile = $path.$random.".html"; $myFile = $random.".html";
$fh = fopen($myFile, 'w') or die("can't open file"); $fh = fopen($myFile, 'w') or die("can't open file");
$stringData = ' $stringData = '
@ -36,8 +36,8 @@ Service by '.$pagepath.'
fclose($fh); fclose($fh);
echo ' echo '
Thanks for using '.$pagetitle.' <br> Thanks for using '.$pagetitle.' <br>
your Link is shorten link is available here:<br> your link is available here:<br>
<a href='.$pagepath.$path.$random.'>'.$pagepath.$path.$random.'</a><br> <a href='.$pagepath.$random.'>'.$pagepath.$random.'</a><br>
<a href="index.php">Back to index</a><br> <a href="index.php">Back to index</a><br>
<a href="http://unps-gama.tk">Home</a> <a href="http://unps-gama.tk">Home</a>