A solution that requires JavaScript and canvas, but offers great versatility -
Result:

ONLINE DEMO
the code:
function makeBorder(id, bw, rSkew, radius) { var el = document.getElementById(id), canvas = document.createElement('canvas'), ctx = canvas.getContext('2d'), bwh = bw / 2, w = parseInt(getComputedStyle(el).getPropertyValue('width'), 10), h = parseInt(getComputedStyle(el).getPropertyValue('height'), 10); canvas.width = w; canvas.height = h;
Add this to create a rounded rectangle (with a skew mod):
function roundedRect(ctx, x, y, w, h, rul, skew) {
Then you simply call this function with the element identifier, border width and the number of pixels that you want to skew on the right side:
makeBorder('demo', 2, 50, 7);
K3N
source share