Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
get the width in percent via jquery.width() - DEMO: http://jsfiddle.net/voku/r72VV/1/
var selector = $("#getID");
var withPercent = selector.width() / selector.parent().width() * 100;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment