On wordpess how can i show recent posts on sidebar
from:

I have sticky posts on my site and this code doesn't work properly because of them. How can i show only recent posts on sidebar with codes.

Poster :
McCoy