Skip to content

A tiny Javascript snippet which automatically changes your filepath in the browser to localhost.

License

Notifications You must be signed in to change notification settings

thielicious/aLocal.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aLocal.js

A JavaScript solution which automatically updates your address bar to localhost


INTRODUCTION

aLocal ('a' for auto) is a tiny JavaScript snippet which automatically updates the address bar to localhost - ready for server-side scripts.


SETUP

  1. Follow this link and choose your download option or open your Git CLI and enter the following:
git clone https://github.com/thielicious/eMM.git
  1. Place this script in your root directory of your host.
  2. Open any PHP file which must be inside of the root path.
  3. Embed alocal.js in your page header just like any other linked script
    <script src="http://localhost/aLocal.js"></script>
  4. Save it and done.

CONFIGURATION

  • .setPath(path) defines the root path, default: XAMPP folder
  • .setLocal(server) defines your server, default: localhost
  • .change() executes the change

USAGE

Once embedded, it's ready to perform. Simply, open a PHP file in your browser, no need to alter the annoying address bar anymore. Not a special thing but a timesaver.



If you encounter any bugs, feel free to open up an issue, thank you.

thielicious.github.io

About

A tiny Javascript snippet which automatically changes your filepath in the browser to localhost.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published