('submit', event => {
	let searchParams = new URL(location.href).searchParams;

	let petId = searchParams.get('petId');

	let body = '';
	body += 'visitDate='    + document.querySelector("input[name='date']").value;
	body += '&description=' + document.querySelector("input[name='description']").value;

	let headers = new Headers();
	headers.set('Accept', 'application/json');
	headers.set('Content-Type', 'application/x-www-form-urlencoded');

	fetch(url + '/pets/' + petId + '/visits', {
		method: 'POST',
		bo