apache - RewriteRule for SEO in a SPA not working -


i wish implement seo single page application website (assume @ www.myexample.com)

after reading google's documentation (https://developers.google.com/webmasters/ajax-crawling/docs/getting-started) started attempting website's home page. means, www.myexample.com?_escaped_fragment_= should 'map to' www.myexample.com/staticindex.html

i added following .htaccess file in website's public_html folder:

rewriteengine on rewritecond %{query_string} ^_escaped_fragment_= rewriterule ^_escaped_fragment_= /staticindex.html [pt] 

after change, when try url www.myexample.com?_escaped_fragment_= in browser, expected browser show me content of file staticindex.html instead, shows me content of www.myexample.com (index.html) , browser url remains unchanged www.myexample.com?_escaped_fragment_=

could me rewriterule?

thanks.

try this:

rewriteengine on rewritecond %{query_string} ^_escaped_fragment_=$ rewriterule (.*) staticindex.html [pt] 

Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -