ziad-saab/hw-parallax — pull request #3 by markchitty (2014-06-09 11:57:52+00:00)
Title: New 'image_attr' option

Allows alternative 'data-image-mobile' attribute to be specified for loading mobile optimised images:

##### HTML
```HTML

```
The `data-wdith` and `data-height` attributes still refer to the main full-size image and don't need repeating as they're only used to calculate the image aspect-ratio.

##### JavaScript
To use this option, specify which `image_attr` to use when initialising parallax().
```javascript
var touch = Modernizr.touch;
$('.parallax').parallax({
image_attr: (touch) ? 'image-mobile' : 'image',
scroll_factor: 0.5
});
```

*Attribution*: idea and implementation lifted pretty much wholesale from https://github.com/pederan/Parallax-ImageScroll.