added options to get_posts and get_url