ajax requests for functionality

user registrations with checks, getting userid for database queries,
adding a favourite, listing a users favourites