Re: Entering Text into a Database

2012-02-03 Thread akaariai
On Feb 4, 2:21 am, ds39 wrote: > Thanks to everyone who took the time to respond. I've been looking at > the godjango website, and its been very helpful with figuring out > forms. I was able to modify some of the tutorial examples on the site, > adding form.save(), to successfully enter text into

Re: Entering Text into a Database

2012-02-03 Thread ds39
Thanks to everyone who took the time to respond. I've been looking at the godjango website, and its been very helpful with figuring out forms. I was able to modify some of the tutorial examples on the site, adding form.save(), to successfully enter text into the database. So, I think I've found my

Re: Entering Text into a Database

2012-02-02 Thread Mario Gudelj
Hey dude, Let's say you have some model with fields defined. It's called Business. Looks something like this: class Business(models.Model): id = models.AutoField(primary_key=True) name = models.CharField("Business Name", max_length=NAME, blank=False) You create a ModelForm like this: cl

Re: Entering Text into a Database

2012-02-02 Thread Python_Junkie
Not sure if this will help, but I have diverted from the standard method of database updates taught in the tutorial. I take a more traditional sql methodology for example in any view that I am using. I collect the data elements via a request and then build a sql statement for example (The exac

Re: Entering Text into a Database

2012-02-02 Thread ajohnston
On Feb 2, 2:30 pm, ds39 wrote: Is there any page, outside of the > official documentation, that gives an example from beginning to end > regarding how to save ModelForms in your database using views.py > rather than the shell (including sample URLs) ? Also, how would I > access the entered text vi

Entering Text into a Database

2012-02-02 Thread ds39
Hello Everyone, I've just started web programming and using Django, and I'm still not sure how to enter text into a database via a page. From everything I've read, the suggestion seems to be that a ModelForm should be used. I've tried to implement this on a simple example model, but I'm sure I'm d