-2

I have just installed and activated the Amp plugin (wordpress.org/plugins/amp ).I had no problem during the installation process.

I cleared cache and checked my site on a mobile device to see how it now displays and there is no difference.

Is there more I need to do after activating the plugin?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
  • which plugin? please offer more information about your problem.... – Adrian Lambertz Sep 13 '16 at 15:00
  • I'm using AMP plugin for more details you can go through the url : https://wordpress.org/plugins/amp/ My site url : http://www.valuecoders.com/blog/ – Shubham Kumar Sep 14 '16 at 06:05
  • Ok dude, read the description of the plugin... :-) the plugin adds a AMP enabled version to your blog posts and archive pages.. just add an /amp/ at the end of your URL (within a blogpost) and see the magic happen.... I think you just need to add a rewrite to add the /amp/ automatically if you are on mobile devices... – Adrian Lambertz Sep 14 '16 at 06:21
  • can you please assist me the right code and where to add it means in which files to add the /amp/ automatically if users are on mobile device . Thankyou in advance all replies will be appreciated. – Shubham Kumar Sep 14 '16 at 07:02

1 Answers1

0

Try this to redirect your users i they are on mobile (i addition to our comments ):

RewriteEngine On
RewriteCond %{REQUEST_URI} !/amp$ [NC]
RewriteCond %{HTTP_USER_AGENT} (android|blackberry|googlebot\-mobile|iemobile|iphone|ipod|\#opera\ mobile|palmos|webos) [NC]
RewriteRule ^([a-zA-Z0-9-]+)([\/]*)$ https://example.com/$1/amp [L,R=302]

Taken from here.

Community
  • 1
  • 1
Adrian Lambertz
  • 913
  • 6
  • 11
  • I have added the above code as suggested but it's not working will you please assist me thankyou in advance all replies will be appreciated. – Shubham Kumar Sep 14 '16 at 13:03