Prepare server to return strings for ajax calls