Szabolcs Szűcs
Szabolcs Szűcs

Reputation: 49

Url parameter redirect

I don't know how to explain,what I want but from examples I think you know. Momently my registration link is:

example.com/pages/registration.php

but I want to open my registration.php on this link:

example.com/registration

How can I do this? Or where can I learn about it,and how to call this?

Thanks

Upvotes: 0

Views: 32

Answers (3)

FrankSunnyman
FrankSunnyman

Reputation: 241

I know them as pretty URL's/clean URL's.

You can create them using a .htaccess file.

http://www.desiquintans.com/cleanurls

Upvotes: 1

Poiz
Poiz

Reputation: 7617

You can achieve that using normal Header Redirect.

Open the file...

     `example.com/pages/registration.php` 

At the top of that file simply add the lines:

<?php        
    header('location: example.com/registration');
    exit;

Upvotes: 0

Sasikumar
Sasikumar

Reputation: 863

Use the following redirection in .htaccess file

RewriteCond %{REQUEST_URI} /registration
RewriteRule ^registration ./pages/registration.php [L]

Upvotes: 2

Related Questions