button

  • Cross Browser Support for DOM Events

    Firefox follows the DOM standard and passes an event object to each event listener, however has the global event: windows.event. Problem:I wanted to fire a piece of javascript after the user keyed some text and pressed enter or clicked a button. The skeleton code is below:<input id=”NewsletterEmail” value=”Email here” type=”text”   onfocus=”javascript:this.value = ”;” class=”WiderLoginTextBox” /><input value=”OK”…

    Know More

  • Styling Buttons in IE

    Even though the button had a class specified on it to change the background image, in IE7 this did not style the button (but in Firefox the styling was picked up from the CSS class “Button”) e.g.and the CSS class was: .Button, input[type=”submit”], input[type=”button”] {   background-position: center center;   background-image: url(Images/ButtonImage.gif); } Solution:The default styling on the IE…

    Know More