Last modified: 2013-04-03 23:08:33 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T48865, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 46865 - https://fundraising.wikimedia.org has broken layout, buttons not working and and uncaught javascript exceptions
https://fundraising.wikimedia.org has broken layout, buttons not working and ...
Status: RESOLVED FIXED
Product: Wikimedia
Classification: Unclassified
Fundraising (Other open bugs)
wmf-deployment
All All
: High major (vote)
: ---
Assigned To: Matt Walker
: code-update-regression
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-04-03 21:29 UTC by Krinkle
Modified: 2013-04-03 23:08 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments
Screenshot of problems. (335.96 KB, image/png)
2013-04-03 21:29 UTC, Krinkle
Details

Description Krinkle 2013-04-03 21:29:31 UTC
Created attachment 12033 [details]
Screenshot of problems.

* Urls in the page are hardcoded http which means in modern browsers those requests are blocked when the page itself is accessed over HTTPS.
  > Use protocol relative urls.

* There are scripts on the page embedded via <script> with no if(window.mw) guard.
  > Use a guard.
  > Better yet, put them in a module and load them that way instead of embedding it (better caching, easier to update)

* There are references to global functions in eval() evaluated event handlers in html attributes:
  <input type="submit" value="Unsubscribe" onclick="$('#execute').attr('value',1);">

  > Bind an event handler from a script instead of from html.

Assuming this has been in place for years, this should never have passed review.
Comment 1 Matt Walker 2013-04-03 23:08:25 UTC
(In reply to comment #0)
> * Urls in the page are hardcoded http which means in modern browsers those
> requests are blocked when the page itself is accessed over HTTPS.
>   > Use protocol relative urls.
This was actually due to wgServer having the full protocol in it. So server configuration error.

> * There are scripts on the page embedded via <script> with no if(window.mw)
> guard.
The only scripts on the page that I added via the extension do not have have mediaWiki dependencies. If there are such scripts they are present in Vector and you should file bugs there; but on quick inspection I didn't find any.

> * There are references to global functions in eval() evaluated event handlers
> in html attributes:
I could bind it in JS; but what's the point? All of this is encapsulated in one template file.

> Assuming this has been in place for years, this should never have passed
> review.
That's a bit harsh. Not everyone has your experience with JS, and the one major flaw you found was a configuration issue unrelated to the code.

I'll mark this as resolved as I fixed the configuration issue. But lets continue this discussion; either in new bugs, on list, or here.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links