Django:How to stop a form from showing up when user enters the direct url of the page containing the form?
Can you just use HTTP verbs?
If both of your entries into the URL are from forms, then you could simply not support GET access to that URL at all.
Suppose I have two modelforms 'A' and 'B' associated with models 'C' and 'D' respectively.Model 'D' has a foreign key of model 'C'.So objects of models should be created first.Now when user submits form 'A',an object of 'C' is generated.Now to send the id of object of model 'C' I'm using a url like this "/{{ object.id }}/".This way the modelform 'B' gets to know which object of model 'C' should be associated with the object of model 'D'.
Now the problem I'm facing is if I enter the url "/{{ object.id }}/",I get to see the modelform 'B' which I don't want.What can I do?