-1 for moving it to SO. This is design related. Tell how it is not.
As for the answer: If you're set on doing this with images rather than CSS you will need 3 images. A left, a right, and a center. I assume you're going for the rounded button style so the right and left images are the rounded edges. The middle image is just the height to match the other two and the same background.
Note: if going for a gradient it won't work if you do it right to left but will work just fine if you do it top to bottom.
Now:
<span class="left"><a class="button" href="#">This is my expandable button</a></span>
or
<span class="left"><button class="button">This is my expandable button</button></span>
Css:
* { padding: 0; margin: 0; box-sizing: border-box; /*needs all vendor prefixes*/ }
.left { background: url(left.jpg) no-repeat; display: block; width: somthingpx; height: somethingpx; }
.button { background: url(middle.jpg) repeat-x; }