A simple method that doesn’t require JQuery:
while(elem.attributes.length > 0)
elem.removeAttribute(elem.attributes[0].name);
More Related Contents:
- How to do this mouse over effect in jquery?
- Regular Expression jquery validation1 [duplicate]
- Creating a JavaScript global array with static elements?
- Can’t append element
- jQuery document.createElement equivalent?
- jQuery’s jquery-1.10.2.min.map is triggering a 404 (Not Found)
- CORS – How do ‘preflight’ an httprequest?
- How to change value of object which is inside an array using JavaScript or jQuery?
- how to access iFrame parent page using jquery?
- How do I print part of a rendered HTML page in JavaScript?
- Is there a jQuery autogrow plugin for text fields?
- jQuery – script tags in the HTML are parsed out by jQuery and not executed
- How to add anything in through jquery/javascript?
- Detect click event inside iframe
- Obtain a reference to parent element [duplicate]
- How do I encode a JavaScript object as JSON?
- Uploading Image to Amazon s3 with HTML, javascript & jQuery with Ajax Request (No PHP)
- What is the best way to detect retina support on a device using JavaScript?
- Modifying a query string without reloading the page
- Store jquery selector in variable
- Aborting jQuery().load()
- Window.Open POST
- Error “Uncaught SyntaxError: Unexpected token with JSON.parse”
- Get Correct keyCode for keypad(numpad) keys
- hide div if clicked outside of it [duplicate]
- How to hide optgroup/option elements?
- What is the new proper way to use a child selector with a context node in jQuery?
- How to include jquery.js in another js file?
- Determine distance from the top of a ‘div’ to top of the window with JavaScript
- How to use confirm using sweet alert?