I want to use a part of the data from the form to use in my HttpResponseRedirect method, but I can't seem to manipulate the data once I get it from the form.
view.py:
if request.method == 'POST':
form = ReviewForm(request.POST)
if form.is_valid():
form.save(commit=True)
joint = form.cleaned_data['place']
//Gets me the name of the joint.
//I need to clean up the name so I can use it in a URL
joint = joint.replace('_', ' ')
joint = joint.replace('00', "'")
joint_url = joint.replace('11', "/")
return HttpResponseRedirect('/burgers/place/' + joint_url)
But when someone submits a name like "Hotdog House " The name of the place is returned, and all of my cleaning doesn't stick. I would expect to get Hotdog_House - but I get Hotdog House.