Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

PHP 

.htaccess - GET Rewriting?

Attemped and failed at this.

I am trying to get: example.com/?from=STRAT&to=EUR&amount=3

To

example.com/STRAT/EUR/3

How an earth can I do this? Is this the wrong sub-forum?


What I have so far:

Code
RewriteEngine on

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^/]+)$ index.php?from=$1 [L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([^/]+)/([^/]+)$ index.php?from=$1&to=$2&amount=$3 [L]
Try this one:
Code
^([^.]+)/([^.]+)/([^.]+)+$
[Image: vibesignature.gif]


“Whatever Your Mind Can Conceive and Believe, It Can Achieve.” – Napoleon Hill
(Jun 13, 2017 11:43 AM)newQuery Wrote:  Try this one:
Code
^([^.]+)/([^.]+)/([^.]+)+$

Code
RewriteEngine On
RewriteRule ^([^/]*)/([^/]*)/([^/]*) /index.php?from=$1&to=$2&amount=$3 [L]

https://cryptoing.net/1/1/test

It doesn't recognise my GETS now.
(Jun 13, 2017 01:39 PM)Skidy Wrote:  
Code
RewriteEngine On
RewriteRule ^([^/]*)/([^/]*)/([^/]*) /index.php?from=$1&to=$2&amount=$3 [L]

https://cryptoing.net/1/1/test

It doesn't recognise my GETS now.

This works for me: https://cryptoing.net/STRAT/EUR/3
[Image: vibesignature.gif]


“Whatever Your Mind Can Conceive and Believe, It Can Achieve.” – Napoleon Hill
(Jun 14, 2017 05:19 AM)newQuery Wrote:  This works for me: https://cryptoing.net/STRAT/EUR/3

Yeah I just fixed it all.

Thank you for your help.


Possibly Related Threads...
Thread / Author Replies Views Last Post
by ClumsyOct 31, 2024 05:53 AM 3 221 Oct 31, 2024 05:53 AM
Last Post: Nachfolger
[PHP] by MarkoTheHackerOct 29, 2024 08:56 PM 2 246 Oct 29, 2024 08:56 PM
Last Post: Clumsy
[PHP] by SkidyJan 29, 2017 06:06 PM 10 263 Jan 29, 2017 06:06 PM
Last Post: Skidy