I am trying to working with srcset to create a responsive image for my website, the idea is that I have a few breakpoints, 320, 768, 1024, 1280 and for each break point I display an appropriate resolution image, so for a breakpoint between 320-768 I would show the 768 image.
I have tried the following,
<img src="http://abc.dev/wp-content/uploads/2017/05/abc-320x187.jpg"
srcset="http://abc.dev/wp-content/uploads/2017/05/abc-768x450.jpg 480w,
http://abc.dev/wp-content/uploads/2017/05/abc-992x581.jpg 768w,
http://abc.dev/wp-content/uploads/2017/05/abc-1200x703.jpg 992w,
http://abc.dev/wp-content/uploads/2017/05/abc-1500x878.jpg 1200w,
http://abc.dev/wp-content/uploads/2017/05/abc-1800x1054.jpg 1500w,
http://abc.dev/wp-content/uploads/2017/05/abc-1920x1124.jpg 1700w" alt="">
What ever my screen size I ways seem to get served the 1920x1124 image.
Can any one shed any light on what I am doing incorrectly?