Link to home
Start Free TrialLog in
Avatar of sandshakimi
sandshakimiFlag for United States of America

asked on

Resize Button to Match?

I need the Cancel button to have the same dimension as the Save button.

User generated image
Here's the markup:

<div class="form-actions form-wrapper" id="edit-actions"><button type="button" value="Cancel" onClick="javascript: history.go(-1)">Cancel</button><input type="submit" id="edit-submit" name="op" value="Save" class="form-submit" /></div>

Open in new window

Avatar of Russ Suter
Russ Suter

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
No points.  A small update to Russ's code.

Make both buttons instead of button and input.  Make buttons same height and width and added padding.
<!DOCTYPE html>
  <meta charset="utf-8">
    height: 40px;
    width: 80px;
<div class="form-actions form-wrapper" id="edit-actions">
  <button type="button" value="Cancel" onClick="javascript: history.go(-1)">Cancel</button>
  <button type="submit" id="edit-submit" name="op"  class="form-submit">Save</button>

Open in new window

Avatar of sandshakimi


These are dynamically generated so Russ's approach is the one I was able to use.