Skip to content

Shadow-Develops/redirect

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Shadow Development - Redirect Page

A modern, dark-themed redirect page built with Express.js featuring countdown timers and auto-redirect functionality.

Features

  • Modern dark theme with blue accents
  • Configurable countdown timer
  • Auto-redirect option with localStorage
  • Stop/cancel redirect functionality
  • Easy configuration via JSON file
  • Fully responsive design

Installation

  1. Install dependencies:
npm install
  1. Start the server:
npm start

For development with auto-reload:

npm run dev

The server will run on http://localhost:3000 by default.

Configuration

Edit config.json to customize your redirect page:

{
	"redirectUrl": "https://shadowdevs.com",
	"logoUrl": "/logo.png",
	"countdownSeconds": 5,
	"autoKey": "dev"
}

Configuration Options:

  • redirectUrl: The destination URL for the redirect
  • logoUrl: Path to your logo image (place in public/ folder)
  • countdownSeconds: Number of seconds before redirect (default: 5)
  • autoKey: Local Storage Key for Auto Redirect (Change if using same domain, but want to reset people's auto redirect)

Adding Your Logo

Place your logo image in the public/ folder and update the logoUrl in config.json:

{
	"logoUrl": "/your-logo.png"
}

How It Works

  1. First Visit: User sees countdown timer (5 seconds by default)
  2. Stop Redirect: Cancels the countdown and changes button to "Redirect Now"
  3. Enable Auto-Redirect: Saves preference to localStorage and immediately redirects. On future visits, user is instantly redirected without countdown.

File Structure

shadow-redirect/
├── server.js           # Express server
├── config.json         # Configuration file
├── package.json        # Dependencies
└── public/
    ├── index.html      # Main page
    ├── styles.css      # Styling
    ├── script.js       # Client-side logic
    └── logo.png        # Your logo (add this)

Customization

Change Colors

Edit public/styles.css and modify the CSS variables and color values to match your brand.

Change Port

Set the PORT environment variable:

PORT=8080 npm start

Or modify server.js:

const PORT = process.env.PORT || 3000;

License

MIT License - Shadow Development

About

Simple redirect website

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published