Reputation: 18745
I'm facing a weird problem. Suddenly I can't get data from POST
request in my view
. I can see that it's there.
@csrf_exempt
def get_candidate_prices_and_xpaths(request):
if request.method == 'POST':
print request.POST
request_url = request.POST.get('request_url','')
print request_url
I can see in command line this:
<QueryDict: {u'product_url': [u'asdasd']}>
and the empty line (the second print
)
How to access the request_url
parameter from post?
Upvotes: 1
Views: 223
Reputation: 1951
You are using two different variables: request_url and product_url.
Upvotes: 3