Skip to content
A simple URL shortening service created using PHP.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
assets
.htaccess
LICENSE.md
README.md
database.sql
directory.php
index.php
redirect.php

README.md

PHP URL Shortener

Build status MIT License

This simple PHP-based service converts URLs into short, redirected links on a custom top-level domain. It features an in-page alert system to notify the user upon a successful (or unsuccessful) URL shortening. The service also records the IP address of every user who successfully submits a short link, along with the short link's exact time of creation and how many clicks it has received.

Live Demo: https://php-url-shortener.herokuapp.com/

Getting Started

This service must be in your domain's root directory, and your web server must allow .htaccess file overrides.

Create the database

Create a MySQL database named surl and import the database.sql file.

Connect to the database

Open the assets/config.ini.php file and replace YOUR_USERNAME (line 7) and YOUR_PASSWORD (line 8) with your MySQL username and password.

Credits

You can’t perform that action at this time.