I am new to Wagtail and I am trying to work out how to extract the query string as part of the FormPage
model.
In models.py
I tried:
def get_context(self, request):
context = super().get_context(request)
context['embed'] = request.GET.get('embed')
return context
But I’m not 100% how to call this in my FormPage model to include this in the email that will be sent when a form is submitted.
I’ve tried to add the following to the FormPage model:
def get_context(self, request):
context = super().get_context(request)
context['embed'] = request.GET.get('embed')
return context
New contributor
Christopher Shimmin-Vincent is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.