We removed the Exit Reader Mode link because it collided with long site titles. See bug report: https://github.com/ampproject/amp-wp/issues/4573
Now when mobile redirection is enabled (a new option in v2.0), an exit mobile site link is added to the footer instead.
C’mon, please don’t ditch that, what if we don’t want to redirect all the mobile users to AMP. If I disable that redirection and some one lands on the AMP page directly (as I share AMP urls more), then there is no button for him to exit except changing the url.
I had my template designed for AMP, but that button now is disappeared, any function to get that back?
Thread Starter
Łukasz
(@lumay)
Please give it back, maybe as an option? Thx in advance
How about this: currently we only show the “Exit mobile version” link in the footer when Mobile Redirection is enabled. How about we show it all the time on AMP pages when in Reader mode or Transitional mode?
Thread Starter
Łukasz
(@lumay)
But footer is too far 🙂 User have to scroll dawn to go on mobile version…
Maybe we could self modify code to add one line of code? But when I added this:
$customizer_settings = AMP_Customizer_Settings::get_settings();
if ( ! empty( $customizer_settings[‘display_exit_link’] ) ) {
$data[‘post_canonical_link_url’] = get_permalink( $this->ID );
$data[‘post_canonical_link_text’] = __( ‘Exit Reader Mode’, ‘amp’ );
}
It doesn’t work…
You can customize the Reader mode template to re-add the desired link for your use case. In your custom theme, create an amp directory. Then put the following header-bar.php file in that location: https://gist.github.com/westonruter/8c47157b88ba3a2622ec76a2d17ecfc6
Thread Starter
Łukasz
(@lumay)
@westonruter Thank you so much for your help! It’s OK now!
@prudhvikanakala what about for you? Would a footer placement be sufficient?
yeah, after my testing, I feel it very reasonable. After user exits the reader mode, still a link is available on non-AMP version to re-enter. that’s awesome and that what I exactly needed from long time.
I decided to go with the flow.
by the way, Thank you so much for such a big change, you guys really did a great hard work for this big jump.This is so meaning full. A big Thanks to you team.
Thanks for the feedback.
I also opened an issue to show the exit mobile version in the footer (on AMP pages) even when mobile redirection is turned off: https://github.com/ampproject/amp-wp/issues/5293
-
This reply was modified 5 years, 9 months ago by
Weston Ruter.
Can you help me in one thing, How can I display comments and comment writing area in legacy template(My custom one)?
I’ve seen that in your provided templates, Can I add that to my template?
If not possible, at least tell me how to display comments with leave comment button.
Thank you.
Please open a new support topic for that.