Differentiate $\displaystyle x^{\sin x}$

I know this has got something to do with the formula $\displaystyle \frac{d}{dx}(a^x)=(a^x)(\ln a)$ but i don't know how to do it. I tried using the chain rule but couldn't even figure it out. I need some pointers on how to do it.

Thanks for any help