Jdlrobson has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/349261 )

Change subject: Search button should not be wrapped in a link
......................................................................

Search button should not be wrapped in a link

This looks like an artifact of the old search form. The problem with
using a link is that in certain browsers the link may be followed
rather than the submit.

Clicking the search icon submit button will have the same effect as
clicking the link - it will submit with an empty search query.

Also add method to form to avoid ambiguity.

Bug: T163049
Change-Id: Ide7725dff259596c963542a0171a78f38ed7e038
---
M includes/skins/MinervaTemplate.php
M includes/skins/minerva.mustache
2 files changed, 2 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend 
refs/changes/61/349261/1

diff --git a/includes/skins/MinervaTemplate.php 
b/includes/skins/MinervaTemplate.php
index 2465e63..0acd750 100644
--- a/includes/skins/MinervaTemplate.php
+++ b/includes/skins/MinervaTemplate.php
@@ -274,8 +274,7 @@
                        'headelement' => $data[ 'headelement' ],
                        'menuButton' => $data['menuButton'],
                        'headinghtml' => $data['footer-site-heading-html'],
-                       'searchButton' => Html::rawElement( 'a', [
-                               'href' => SpecialPage::getTitleFor( 'Search' 
)->getLocalURL(),
+                       'searchButton' => Html::rawElement( 'div', [
                                'id' => 'searchIcon',
                                'class' => MobileUI::iconClass( 
'magnifying-glass', 'element' ),
                        ], $input ),
diff --git a/includes/skins/minerva.mustache b/includes/skins/minerva.mustache
index 2ac61d8..b082526 100644
--- a/includes/skins/minerva.mustache
+++ b/includes/skins/minerva.mustache
@@ -9,7 +9,7 @@
                        {{>banners}}
                </div>
                <div class="header-container header-chrome">
-                       <form class="header" action="{{wgScript}}">
+                       <form class="header" action="{{wgScript}}" method="get">
                                <div>{{{menuButton}}}</div>
                                <div class="branding-box">
                                        <h1>

-- 
To view, visit https://gerrit.wikimedia.org/r/349261
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ide7725dff259596c963542a0171a78f38ed7e038
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to