I personally feel you should look into doing the post via Ajax, pass
your form field values into an array and unpack the values in your
view:
ie:
function AjaxSubmitForm(formdata){
$.post('/ajax/some-view/'+formdata+'/', function(data){
if(data == 'done'){
d.body.innerHTML = "
Sent: Sun Feb 01 21:07:28 2009
Subject: Re: trouble with Django and javascript
Not working. Still the same problem( when button is clicked, the text
of "This is a test" will display in the iframe for one second, and
then disappear.).
On Feb 2, 12:55 pm, "Will Matos" wrote:
>
Dir. of Tech. Sales
>
>
>
> - Original Message -
> From: django-users@googlegroups.com
> To: Django users
> Sent: Sun Feb 01 20:54:32 2009
> Subject: Re: trouble with Django and javascript
>
> If I use Onclick="submit();", how to add the javascript fu
Onclick="test();submit();"
Will Matos
TCDI
Dir. of Tech. Sales
- Original Message -
From: django-users@googlegroups.com
To: Django users
Sent: Sun Feb 01 20:54:32 2009
Subject: Re: trouble with Django and javascript
If I use Onclick="submit();", how to add the
Greensboro, NC 27407
> 336.232.5832 office
> 336.232.5850 fax
> 336.414.0467 mobile
>
>
>
> - Original Message -
> From: django-users@googlegroups.com
> To: Django users
> Sent: Sun Feb 01 19:52:49 2009
> Subject: Re: trouble with Django and javascript
ubject: Re: trouble with Django and javascript
Thanks for you reply.
However, if I change the 'submit' to button, how can I submit the form
to the server?
Regards
min
On Feb 2, 11:34 am, "Todd O'Bryan" wrote:
> In addition to displaying the message, it's also submi
Thanks for you reply.
However, if I change the 'submit' to button, how can I submit the form
to the server?
Regards
min
On Feb 2, 11:34 am, "Todd O'Bryan" wrote:
> In addition to displaying the message, it's also submitting the form,
> so you see the text for a second and then the form reloads
Thanks for you reply.
However, if I change the 'submit' to button, how can I submit the form
to the server?
Regards
min
On Feb 2, 11:34 am, "Todd O'Bryan" wrote:
> In addition to displaying the message, it's also submitting the form,
> so you see the text for a second and then the form reloads
Thanks for you reply.
However, if I change the 'submit' to button, how can I submit the form
to the server?
Regards
min
On Feb 2, 11:34 am, "Todd O'Bryan" wrote:
> In addition to displaying the message, it's also submitting the form,
> so you see the text for a second and then the form reloads
Thanks for you reply.
However, if I change the 'submit' to button, how can I submit the form
to the server?
On Feb 2, 11:34 am, "Todd O'Bryan" wrote:
> In addition to displaying the message, it's also submitting the form,
> so you see the text for a second and then the form reloads.
>
> Change
Thanks for you reply.
However, if I change the 'submit' to button, how can I submit the form
to the server?
On Feb 2, 11:34 am, "Todd O'Bryan" wrote:
> In addition to displaying the message, it's also submitting the form,
> so you see the text for a second and then the form reloads.
>
> Change
In addition to displaying the message, it's also submitting the form,
so you see the text for a second and then the form reloads.
Change the instead of "submit" and see if that helps.
Todd
On Sun, Feb 1, 2009 at 6:05 PM, min wrote:
>
> First I have a form:
>
> class TestForm(forms.Form):
>
Besides, I use firefox.
thanks
On Feb 2, 10:05 am, min wrote:
> First I have a form:
>
> class TestForm(forms.Form):
> name = forms.CharField( max_length=30 )
> age = forms.CharField( max_length=30 )
>
> Then in the views.py:
>
> def Test_page(request):
>
> form = TestForm()
> variable
Besides, I use firefox.
On Feb 2, 10:05 am, min wrote:
> First I have a form:
>
> class TestForm(forms.Form):
> name = forms.CharField( max_length=30 )
> age = forms.CharField( max_length=30 )
>
> Then in the views.py:
>
> def Test_page(request):
>
> form = TestForm()
> variables = Requ
Besides, I use firefox.
On Feb 2, 10:05 am, min wrote:
> First I have a form:
>
> class TestForm(forms.Form):
> name = forms.CharField( max_length=30 )
> age = forms.CharField( max_length=30 )
>
> Then in the views.py:
>
> def Test_page(request):
>
> form = TestForm()
> variables = Requ
First I have a form:
class TestForm(forms.Form):
name = forms.CharField( max_length=30 )
age = forms.CharField( max_length=30 )
Then in the views.py:
def Test_page(request):
form = TestForm()
variables = RequestContext(request, {
'form': form,
})
return render_to_response('Tes
16 matches
Mail list logo