Project

General

Profile

Actions

Patch #17401

closed

Better fix for r13159 issue #16708

Added by Daniel Felix almost 10 years ago. Updated almost 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Code cleanup/refactoring
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:

Description

You can fix this one with a little bit cleaner code:

Change:
<button class="tab-left" onclick="moveTabLeft(this); return false;"></button>

to:
<button class="tab-left" type="button" onclick="moveTabLeft(this);"></button>

Browsers defaults often to type="submit" which submits the form. If you explicite define a type, it will be fine.
The return false; is not the cleanest way, as... if you call some code afterwards, it won't be executed because the propagation ends there.

Actions

Also available in: Atom PDF