Splitted fetch_posts function up into two functions.

Splitted into fetch_posts_nearby and fetch_posts_within.
Also documented the functions, but not yet implemented fetch_posts_within.