Just updated Django to revision 632. Hadn't done anything with django
in a couple of weeks. I started a new project with 'django-admin.py
startproject projectname'. Added my database settings to it and ran
'django-admin.py init'. Everything working so far. Then created my
app with 'django-adm
jocknerd wrote:
Just updated Django to revision 632. Hadn't done anything with django
in a couple of weeks.
The model syntax has changed some time ago:
http://www.djangoproject.com/weblog/2005/aug/25/modelsyntax/
I can't figure out a very simple file upload. I have a simple model with
one-to-many relation:
class Dashboard(meta.Model):
name=meta.CharField(maxlength=20)
class Thumbnail(meta.Model):
dashboard=meta.ForeignKey(Dashboard)
image=meta.ImageField(upload_to='...')
1. First problem is that D
I've been throught this too :)
First of all, you need to use both {{ form.image}} and {{
form.image_file }}
this will create the hidden file and the file input field.
Also, if you forgot like I did, you need to put
enctype="multipart/form-data"
into the form tag.
Thirdly, in the view, do this
Well, maybe i'm not clear or there is no solution. Perhaps my solution
would be in writing some
GenericViews(http://www.djangoproject.com/documentation/generic_views/)...
Thanks. I saw that in the latest tutorial but I was using some old
code. I'll make the adjustments.
On 9/7/05, Eugene Lazutkin <[EMAIL PROTECTED]> wrote:
> The only piece I need for true happiness with Django is caching. Dreamhost
> doesn't provide memcached:. simple: is, well, too simple because it is not
> thread-safe. If only we had mysql:, or file: cache option... Nudge, nudge,
> wink, wink,
Hi,
I'm just started to play with Django and it looks very promissing to me.
For a small test app I would like to store sorted lists of items. In
pure (Pseudo-)SQL I would do it like this:
create table itemlists (
int unique_id,
int name,
...
)
create table items (
int unique_id
That's great. So, the views don't, by default, consider SITE_ID then.
Thanks much,
A.
On Sep 8, 2005, at 8:56 AM, Achim Domma wrote:
I'm just started to play with Django and it looks very promissing
to me. For a small test app I would like to store sorted lists of
items. In pure (Pseudo-)SQL I would do it like this:
create table itemlists (
int unique_id,
int name,
Dagur wrote:
First of all, you need to use both {{ form.image}} and {{
form.image_file }}
Ah! This did it. Thank you very much!
2005/9/5, Tristan Lawrence <[EMAIL PROTECTED]>:
> Well, my first problem was that blastwave.org does not have a psycopg package
> for Solaris. But then I did a source install only to have it keep coredumping
> on me :(
hi tristan
sorry for the late reply.
have you seen the following post (and the
Documentation on authentication is still very much needed.
The interim solution suggested earlier in this thread entails far too
much code duplication when Django already has an auth system. Here's
hoping it will be simple for apps to take advantage of the auth
framework without having to (re)wr
Hi. I've more-or-less finished a django app that might be useful to
other people --- it's a feed reader similar to feedonfeeds, except that
it is multiuser, supports categories, and is more tolerant of invalid
feeds (thanks to the wonderful feedparser -- feedparser.org). It's
basically functiona
Following up on my original question, now I've read a bit more about
it, the answer is of course to just use the admin interface. :-)
If you run django-admin.py adminindex , it will auto-generate a
copy of the guts of the index page needed to display the admin
interface. You can copy that into yo
Milton Waddams wrote:
> I'm trying to associate multiple users with a team and each user having a
> specific role within that team.
>
> eg. not my situation though easiest way to make it clear what I'm attempting
> to achieve...
> CEO = meta.ForeignKey(User)
> CFO = meta.ForeignKey(User)
>
> w
Suppose a view, handling a POST, has to perform some task that can be
reasonably expected to take a lot of time, long enough that it will
often cause a timeout somewhere in the chain (between browser and
webserver, between webserver and fastcgi server, etc). Suppose the view
(as naively implement
On 9/8/05, Robert Wittams <[EMAIL PROTECTED]> wrote:
> I think this is a bug, but you can work around it using
>
> CEO = meta.ForeignKey(User, verbose_name="CEO" )
> CFO = meta.ForeignKey(User, verbose_name="CFO" )
>
> I don't know why the name of the class is used in preference to the name
> of
Are you familiar with any sort of database? (think of RDBMS as if it
was fancy version of Excel). The django itself doesn't force you to
know anything about SQL. Perhaps the only exception is that you will
need to know how to create and delete databases in
(postgresql/mysql/sqllite/whichever you u
perfect, thanks :)On 9/8/05, Robert Wittams <[EMAIL PROTECTED]> wrote:
I think this is a bug, but you can work around it usingCEO = meta.ForeignKey(User, verbose_name="CEO" )CFO = meta.ForeignKey(User, verbose_name="CFO" )I don't know why the name of the class is used in preference to the name
of t
Jason F. McBrayer wrote:
> Hi. I've more-or-less finished a django app that might be useful to
> other people
> I'd like to package this for other people in a way that is as convenient
> for them as possible, while not requiring too much work from me. So,
> what do people expect from a third-pa
Hello Jakub,
Thanks for the reply.
Jakub Labath wrote:
> Are you familiar with any sort of database? (think of RDBMS as if it
> was fancy version of Excel). The django itself doesn't force you to
> know anything about SQL. Perhaps the only exception is that you will
> need to know how to create
On 9/8/05, Jimmie Houchin <[EMAIL PROTECTED]> wrote:
> I am familiar with and understand the above terms. I have gone half way
> thru the Practical SQL Handbook. I just wanted to make sure I didn't
> have to finish Joe Celko, and C.J. Date before proceeding. :)
In that case, you should be fine. N
23 matches
Mail list logo