Home Two Ajax calls only meet one condition at a time

# Two Ajax calls only meet one condition at a time

user2976
1#
user2976 Published in March 23, 2018, 9:02 am
 I have the following script that sends a POST of my select option to a url called requestaccess. This works great when using only one of the two, but when I change the other field the result of the POST is None for the first and correct for the second and vice-versa. 
 My view gets the POST value with the following: selectedaccesslevel = request.POST.get('accesslevelid') print(selectedaccesslevel) selectedphi = request.POST.get('phi') print(selectedphi)  However, my print either displays as: None 1 or 2 or 7, 5, 3, 6, 4 None.  My desired results are for it to display as : 7, 5, 3, 6, or 4 1 or 2 
 You need to login account before you can post.
Processed in 0.327367 second(s) , Gzip On .