How to properly use a php page displayed on form action -


i've got finished site , i'm working on customer callback form put in name, email, tel me contact them. way have on form action specify "php/sendform.php" scrip. in script put html normal web pages have footer , header message thank contacting us. works seems little awkward , i've never seen on other mainstream sites, of sudden address bar changes php page other pages on site html.

so question is, there way maybe call php in async way? or somehow mask address bar doesn't reveal php directory because says site.com/php/sendform.php. thanks.

you can use url rewriting. change form action submit. , in .htaccess file add these lines:

rewriteengine on rewriterule    ^submit?$    php/sendform.php    [nc,l] 

so php page this:

yourdomain.extension/submit


Comments

Popular posts from this blog

java - SSE Emitter : Manage timeouts and complete() -

jquery - uncaught exception: DataTables Editor - remote hosting of code not allowed -

java - How to resolve error - package com.squareup.okhttp3 doesn't exist? -