0👍
✅
I wasn’t able to resolve it in your way, but I managed out how to do it:
C go directly to S via javascript opening a popup with:
window.open("http://<S_address>/<path_to_request_form>");
In this way, user using C that is logged via a third party authentication server (I forgot to mention it earlier, sorry), is still logged in the popup window in S and receives the form in it with a correct csrf token. I don’t know if it’s correct but it works.
Thanks for your time
👤gc5
1👍
Try defining your context and returning it like this…
context = RequestContext(request, {
'request': request
})
return render_to_response(..., context_instance=context)
👤Dave
- [Answered ]-Why does timezone aware datetime have 2 times in django
- [Answered ]-Access model name in Django CreateView from template
- [Answered ]-Django Rest Framework nested serializer
- [Answered ]-Django, TastyPie, Authentication, and custom middleware headache
- [Answered ]-Wagtail Image template tags
1👍
This is by design, and disallows for cross site POST execution. One option you have is to mark the methods you would like to be able to execute as safe, as per the django docs:
- [Answered ]-Running a Python function from Ansible script
- [Answered ]-User permissions for content in Django
Source:stackexchange.com