Defect #16708

Form is submitted when switching tab

Added by Nicolas Rodriguez over 4 years ago. Updated about 4 years ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:Jean-Philippe Lang% Done:

0%

Category:UI
Target version:2.5.2
Resolution:Fixed Affected version:2.5.1

Description

In render_tabs method, when I click on next tab or previous tab button, form is submit instead of switching tab.

I think you should change

  <div class="tabs-buttons" style="display:none;">
    <button class="tab-left" onclick="moveTabLeft(this);"></button>
    <button class="tab-right" onclick="moveTabRight(this);"></button>
  </div>

to

  <div class="tabs-buttons" style="display:none;">
    <button class="tab-left" onclick="moveTabLeft(this); return false;"></button>
    <button class="tab-right" onclick="moveTabRight(this); return false;"></button>
  </div>

Associated revisions

Revision 13108
Added by Jean-Philippe Lang over 4 years ago

Don't submit the form when tabs are inside a form (#16708).

Patch by Nicolas Rodriguez.

History

#1 Updated by Jean-Philippe Lang over 4 years ago

  • Target version set to 2.5.2

#2 Updated by Jean-Philippe Lang over 4 years ago

  • Status changed from New to Resolved
  • Assignee set to Jean-Philippe Lang
  • Resolution set to Fixed

Fix committed in r13108, thanks.

#3 Updated by Jean-Philippe Lang over 4 years ago

  • Status changed from Resolved to Closed

Merged.

#4 Updated by Jean-Philippe Lang about 4 years ago

  • Subject changed from Form is submit when swithing tab to Form is submitted when swithing tab

#5 Updated by Toshi MARUYAMA about 4 years ago

  • Subject changed from Form is submitted when swithing tab to Form is submitted when switching tab

Also available in: Atom PDF