I'm new to this, please have grace...

So I understand changing the .htaccess file to let users type in a new link, and then it reference the old page as seen here:
I want to access, by typing in

.htaccess file:
Options +FollowSymLinks
RewriteEngine On

RewriteRule ^(.*)_(.*)_(.*)\.html$ result.php?var1=$1&var2=$2&var3=$3

it works... but now, how do I automatically when I submit the form, get the new link to display? Or in other words, how do when we type in be redirected to

Any help would be appreciated!

You have to send the 301 redirect code explicitly as a flag
These flags go in brackets after your RewriteRule. In your case you could try this:

RewriteRule ^(.*)_(.*)_(.*)\.html$ result.php?var1=$1&var2=$2&var3=$3 [R=301, L]

R=301 says "send the 301 permanent redirect"
the L flag says that this is the last flag for this command.

Here is a random googled page for RewriteRule flags:

Good luck!

I had a similar doubt too. Thanks for the link guyinpv.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.