Page MenuHomePhabricator

Link to switch back to desktop in mobile view is forcing HTTP even if viewing over HTTPS
Closed, ResolvedPublic

Description

Visit https://en.m.wikipedia.org/wiki/Clebsch%E2%80%93Gordan_coefficients

At the bottom of the page is <li>Mobile</li><li><a id="mw-mf-display-toggle" href="http://en.wikipedia.org/w/index.php?title=Clebsch%E2%80%93Gordan_coefficients&amp;mobileaction=toggle_view_desktop">Desktop</a></li>

This was reported via OTRS ticket #2015050410022502.

Event Timeline

Legoktm raised the priority of this task from to High.
Legoktm updated the task description. (Show Details)
Legoktm added projects: MobileFrontend, HTTPS.
Legoktm added a subscriber: Legoktm.
Restricted Application added a subscriber: Aklapper. · View Herald Transcript

There are some other issues though - grep http: i18n/* | wc -l through the MobileFrontend returns a lot of insecure links to Wikipedias or foundationwiki.

There are some other issues though - grep http: i18n/* | wc -l through the MobileFrontend returns a lot of insecure links to Wikipedias or foundationwiki.

Try checking it while logged out.

Change 213190 had a related patch set uploaded (by Legoktm):
Have link to switch back to desktop view be protocol-relative

https://gerrit.wikimedia.org/r/213190

Change 213190 merged by jenkins-bot:
Have link to switch back to desktop view be protocol-relative

https://gerrit.wikimedia.org/r/213190

Okay, so that's done. I do wonder about this code in includes/models/MobilePage.php though:

					$imgUrl = wfExpandUrl( $thumb->getUrl(), PROTO_CURRENT );
					if ( $useBackgroundImage ) {
						$props['style'] = 'background-image: url("' . wfExpandUrl( $imgUrl, PROTO_CURRENT ) . '")';
						$text = '';
					}
phuedx claimed this task.
phuedx removed a project: Patch-For-Review.