I am making a photo gallery as a project from school and I got stuck
on the uploading picture part of it. Initially I started with the
oldforms and I successfully uploaded pictures. But I have 2 questions.
So I have this code:
if request.method == 'POST':
# If data was POSTed, we're tryin
On 12-May-07, at 12:00 PM, [EMAIL PROTECTED] wrote:
> United States. I've had troubles in the past with foreign developers,
please avoid comments like this - it is sufficient to specify the
geographical area
--
regards
kg
http://lawgon.livejournal.com
http://nrcfosshelpline.in/web/
--~-
Hi,
I'm new to django and programing. I was following the tutorial and get
to the following:
Wait a minute. is, utterly, an unhelpful
representation of this object. Let's fix that by editing the polls
model (in the polls/models.py file) and adding a __str__() method to
both Poll and Choice:
cl
You'll add it inside your Poll class, maybe you should first read a
python tutorial, it'll be helpful,
good luck
class Choice(models.Model):
question = models.CharField(maxlength=200)
pub_date = models.DateTimeField('date published')
def __str__(self):
return self.choice
--~--~-
On May 11, 4:20 pm, Maxim Bodyansky <[EMAIL PROTECTED]> wrote:
> Hmmm. It just works. And i18n for module names works too :)
> Many-many thanks, Ivan :)
Это не Иван, это - Vinay
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the G
http://www.cantblockme.info is a free anonymous proxy which allows you
to unblock myspace, bebo, facebook, youtube and other websites from
your school, workplace or home!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Grou
В сообщении от Суббота 12 мая 2007 12:36 Vinay Sajip
написал(a):
> On May 11, 4:20 pm, Maxim Bodyansky <[EMAIL PROTECTED]>
wrote:
> > Hmmm. It just works. And i18n for module names works
> > too :) Many-many thanks, Ivan :)
>
> Это не Иван, это - Vinay
Извиняюсь, померещилось :) Всё равно спасиб
Hi,
I'm trying to get some basic i18n support going but I'm get some weird
errors.
1) I had to include the project in INSTALLED_APPS before anything
would happend at all, but I've since removed that and I'm trying to
translate a single app.
2) I've been digging around the django code to figure o
On 12 Maj, 11:25, Psamathos <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I'm trying to get some basic i18n support going but I'm get some weird
> errors.
>
> 1) I had to include the project in INSTALLED_APPS before anything
> would happend at all, but I've since removed that and I'm trying to
> translat
Hi all,
I released Strippers Remoting Classes which enables
you to invoke remoting service from Flash CS3 application.
The example code was added to the user manual.
http://djangoamf.sourceforge.jp/index.php?UserManual_en#RemoteServiceInvocationFromFlashCS3
http://djangoamf.sourceforge.jp/inde
On Sat, 2007-05-12 at 02:25 -0700, Psamathos wrote:
> Hi,
>
> I'm trying to get some basic i18n support going but I'm get some weird
> errors.
>
> 1) I had to include the project in INSTALLED_APPS before anything
> would happend at all, but I've since removed that and I'm trying to
> translate a
On 12 Maj, 11:39, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote:
> On Sat, 2007-05-12 at 02:25 -0700, Psamathos wrote:
> > Hi,
>
> > I'm trying to get some basic i18n support going but I'm get some weird
> > errors.
>
> > 1) I had to include the project in INSTALLED_APPS before anything
> > would
> If you don't want to go down that path, we do have built in support
> for JSON, XML, and YAML; so you will need to get your CSV data into
> one of these formats.
I've been using YAML for this purpose before, when using Symfony, and it's a
quite natural way to describe data, only tied by indent
Hello Nic,
On 11 май, 13:23, Nic James Ferrier <[EMAIL PROTECTED]>
wrote:
> def user_alerts(request, user_name):
> me = get_object_or_404(User, username=user_name)
> alerts = Alert.objects.filter(user=me, seen=False)
> return tfxslt.send_json(HttpResponse(),
>
Hi there, folks!
I've been "playing" (actually shooting out projects like a printer) with
Django for some time now, although I've joined the list far after.
To the point. My hosting is a mess. I have a superb dedicated virtual server.
This, of course, means that I've set up everything myself,
Hi there,
In a previous mail, I said something about missing something from Symfony.
It's the environment. You where able to set up a front controller (basically,
the file you're calling in the url, and that calls the rest of the app), for
say a staging environment, let your client access the
Eugene Morozov <[EMAIL PROTECTED]> writes:
> On 11 май, 13:23, Nic James Ferrier <[EMAIL PROTECTED]>
> wrote:
>> def user_alerts(request, user_name):
>> me = get_object_or_404(User, username=user_name)
>> alerts = Alert.objects.filter(user=me, seen=False)
>> return tfxslt.send_json(Ht
On 5/12/07, Christian M Hoeppner <[EMAIL PROTECTED]> wrote:
>
> The environment is a neat thing I've been missing in Django so far. Depending
> on the way you call your app, you get a different set of settings loaded.
> Neat for development/production/staging/else.
I don't know much about Symfony
> You are correct - initial_data fixtures is the preferred mechanism for
> loading data.
Okay...things are starting to make a bit more sense.
I'll post a few more questions and hopefully this thread can
become the foundation for the documentation you describe.
One of the questions coming to min
> You'll add it inside your Poll class, maybe you should first read a
> python tutorial, it'll be helpful,
> good luck
>
> class Choice(models.Model):
>question = models.CharField(maxlength=200)
>pub_date = models.DateTimeField('date published')
>def __str__(self):
>return sel
I could live with doing multiple checks. In fact, I may want to check
every URL in the redirecting chain to make sure the flow is just what
I wanted.
Then, I can just hard code the URLs in the chain:
response = self.client.get('/page')
self.assertRedirects(response, '/first/') # no need to retu
Hi,
I've developed a site that worked locally, but when I put it onto
Dreamhost I started having problems with some areas. If you go to
http://haircrazy.info/Tags/ and select a tag. You should go to a list
of articles/posts etc. for that tag. Instead you are re-directed to
the front page, the erro
> I don't know much about Symfony, but as I understand what you are
> saying, the Django approach to achieving this would be to have
> multiple fixtures, one for each 'environment'.
This one was more of an off-topic comment. Environments in Symfony are about
settings, not about fixtures. You're a
Anybody has any suggestion?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMA
On 5/12/07, Christian M Hoeppner <[EMAIL PROTECTED]> wrote:
>
> > I don't know much about Symfony, but as I understand what you are
> > saying, the Django approach to achieving this would be to have
> > multiple fixtures, one for each 'environment'.
> This one was more of an off-topic comment. Env
On 5/12/07, Tim Chase <[EMAIL PROTECTED]> wrote:
>
> > You are correct - initial_data fixtures is the preferred mechanism for
> > loading data.
>
> Okay...things are starting to make a bit more sense.
>
> I'll post a few more questions and hopefully this thread can
> become the foundation for the
On 5/12/07, Jiri Barton <[EMAIL PROTECTED]> wrote:
>
> I could live with doing multiple checks. In fact, I may want to check
> every URL in the redirecting chain to make sure the flow is just what
> I wanted.
That was my point - the fact that /second redirects to /third is just
as important as th
On 5/10/07, sandro dentella <[EMAIL PROTECTED]> wrote:
>
> hi,
>
> I'm trying to play with initial_data fixture. I dumpdata (json
> format)
> and reload it cleanly if there are no foreign key contraints on the
> table.
> If the tables i'm dumping have foreign keys (in my case holydays/
> nat
On 5/7/07, Mark Jarecki <[EMAIL PROTECTED]> wrote:
>
> Hi Russ,
>
> Thank you for all your help, I renamed my app name and it works fine
> at the moment.
>
> I posted a ticket (I hope its ok, my fist one) #4231.
Ticket description was fantastic.
FYI, I've fixed the problem in [5204]. The problem
I use python 2.5
I get the following error in the admin "string index out of range"
Why do I get this error?
The model classes are in question are:
12 class Work(models.Model):
13 datum = models.DateTimeField()
14 omschrijving = models.CharField(maxlength=255)
15 def __str__(sel
On Sat, 2007-05-12 at 17:55 +0200, Enquest wrote:
> I use python 2.5
Are you really using a Python 2.5 final release, or a pre-release of,
say, Python 2.5.1 that came with the recent Ubuntu release? The reason
I'm asking is because there was a regression in 2.5.1 pre-releases that
was fixed just
On May 11, 2007, at 9:40 PM, Malcolm Tredinnick wrote:
> More information is definitely needed here. You've just done the
> equivalent of "I've had a car accident." "Where should we send the
> auto
> service?" "There's a traffic light here."
Thanks for the reply, Malcolm.
--~--~-~--~
On 5/4/07, Patrick Anderson <[EMAIL PROTECTED]> wrote:
>
> Below is my view function to retrieve month values from a QuerySet:
>
> def year_get_months(request, year, template_name):
>
> months = Letter.objects.filter(
> date_published__year = year
> ).dates('date_published', 'm
I have a table containing the fields "original_price" and
"discounted_price". I want to order the results of an SQL statement
according to the relative discount which is: (original_price-
discounted_price)/original_price.
So I wrote the following SQL statement:
SELECT id, name FROM offers_offer O
On Sat, 2007-05-12 at 16:12 +, checco wrote:
> I have a table containing the fields "original_price" and
> "discounted_price". I want to order the results of an SQL statement
> according to the relative discount which is: (original_price-
> discounted_price)/original_price.
>
> So I wrote the
I am working on my first "real" django project which includes a weblog.
I would like to create an Archives page that lists each year and
month of that year, dynamically.
ie,
May, 2007
April, 2007
November, 2006
etc..
Is this possible to generate quickly from a model containing a
DateT
I think a dict contain queryset and extra info should be passed in url
patterns as third parameter.
maybe this will work in your urls.py
myObj_dict = {
'queryset': myObj.objects.all(),
'paginate_by': 10,
}
(r'^list/$', 'django.views.generic.list_detail.object_list', entry_dict),
--~--~-
I am sorry for the typo.
(r'^list/$', 'django.views.generic.list_detail.object_list', entry_dict),
should be: (r'^list/$', 'django.views.generic.list_detail.object_list',
myObj_dict),
--~--~-~--~~~---~--~~
You received this message because you are subscribed to th
I hope I can provide enough information to allow someone to point me
in the right direction.
When I start apache 1.3, the error log contains these message:
[error] (22)Invalid argument: FastCGI: access for server (uid 70,
gid 70) failed: write not allowed
[notice] FastCGI: pro
> Interesting. The "installed n fixtures" message is printed before the
> transaction is commited, which might be causing the confusion, but if
> the commit isn't succeeding, you should be seeing other errors (i.e.,
> db failures). Is it possible that stderr is getting redirected
> somewhere other
On May 12, 2007, at 6:02 AM, Anthony Batchelor wrote:
>
> Hi,
> I've developed a site that worked locally, but when I put it onto
> Dreamhost I started having problems with some areas. If you go to
> http://haircrazy.info/Tags/ and select a tag. You should go to a list
> of articles/posts etc. f
Hello!
Ok, this is the scenario:
An album contains several images. The user can click on "manage
album", and get a list of all the images contained inside the specific
album.
The user should then be able to edit information on each individual
image on one page, and click a "Submit"-button at the
You stated you got a python traceback and yet you only show us the
error message. What Malcolm was trying to say was that it would be
helpful to print out that traceback, rather than your Apache
configuration, at least to start with.
When debugging a problem it's always best to start with t
Ok, I've run upon another stumbling block. I did as you recommended
and created a Relation model. I'd like to be able to edit/create a
Relation inline with a Part in the django admin.
The example provided in the tutorial for editing inline doesn't work
in this situation. Is it doable at all?
Hi all,
I'm going bananas looking for a ERD tool that was available on the
www.djangoproject.com site a year ago. I think it was mentioned together
with a link in one of the comments on one of the pages soewhere (yeah,
that's vague:). I remember trying it out and it worked just fine, taking
the d
On 12 май, 17:08, Nic James Ferrier <[EMAIL PROTECTED]>
wrote:
> Eugene Morozov <[EMAIL PROTECTED]> writes:
> > Sorry, I don't get the point. I think that XSLT is a way to separate
> > presentation from data. But your json looks like some kind of HTML. I
> > don't understand how this is better tha
--
Mohamed Hussein
http://www.unixgarage.com
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group
Thank you, Don. I understand what Malcolm wrote. I didn't include the
trace back and that was indeed a mistake.
After walking through the set up and making some adjustments
to .htaccess, I stopped getting a trace back in the browser. Thus, I
didn't have much to share with Malcolm.
This mor
Eugene Morozov <[EMAIL PROTECTED]> writes:
>> - there is proper separation between data and style, my JSON doesn't
>> include any stylistic information, only stuff that describes the data
>
> I still think that your example is not the best. "div" and "span" has
> no semantic meaning, they're ju
I'm new to Django and I'm using Django's Free Comments described here:
http://code.djangoproject.com/wiki/UsingFreeComment
The comments are posted correctly, except on this page
("posted.html"):
Thanks for contributing.
View your comment.
The link generated by "object.get_absolute_u
On 5/12/07, Nic James Ferrier <[EMAIL PROTECTED]> wrote:
>
> Eugene Morozov <[EMAIL PROTECTED]> writes:
>
> >> - there is proper separation between data and style, my JSON doesn't
> >> include any stylistic information, only stuff that describes the data
> >
> > I still think that your example i
I am trying to build an archives page for my already existing Django
powered blog. Now it's really nothing fancy. I want it to list the
months under a year heading that things are posted on, and the user
should be able to click on the month, the month goes to a url
something like /2007/jan
Hi all,
For those who don't follow the Django community aggregator I thought
I'd send this out to the lists. I'm arranging an informal get-together
of Django folks next month here in Northampton, MA.
http://open.e-scribe.com/wiki/DjangoDotJune
Here's a condensed version of the info from that p
I believe you are referring to http://code.djangoproject.com/wiki/DjangoGraphviz
On May 12, 3:08 pm, Lars Stavholm <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I'm going bananas looking for a ERD tool that was available on
> thewww.djangoproject.comsite a year ago. I think it was mentioned together
Nowell wrote:
> I believe you are referring to
> http://code.djangoproject.com/wiki/DjangoGraphviz
That's the one!
Thanks
/Lars
> On May 12, 3:08 pm, Lars Stavholm <[EMAIL PROTECTED]> wrote:
>> Hi all,
>>
>> I'm going bananas looking for a ERD tool that was available on
>> thewww.djangoprojec
I am trying to upload a file using the newforms library. So far from
reading other posts and googling around it appears I have to copy the
request.POST dictionary and update it with request.FILES. Then I
would do a "model.save__file(, )" to
actually save the file.
Here's the code where I try to
On 5/13/07, jonathan_ou <[EMAIL PROTECTED]> wrote:
>
> I am trying to upload a file using the newforms library. So far from
> reading other posts and googling around it appears I have to copy the
> request.POST dictionary and update it with request.FILES. Then I
> would do a "model.save__file(,
On 5/13/07, C <[EMAIL PROTECTED]> wrote:
>
> Ok, I've run upon another stumbling block. I did as you recommended
> and created a Relation model. I'd like to be able to edit/create a
> Relation inline with a Part in the django admin.
>
> The example provided in the tutorial for editing inline doe
I want to make a generic object_list view and for some reasons I can't
directly generate the QuerySet (which is a necessary parameter of the
object_list) but I can retrieve the list of objects I want to display
using a raw SQL statement. As I still want to use the object_list
view, which needs a Q
You ca use:
Entry.objects.all().dates('pub_date','month','DESC')
lookup the dates function of the QuerySet.
On May 12, 7:18 pm, Peter Sanchez <[EMAIL PROTECTED]> wrote:
> I am working on my first "real" django project which includes a weblog.
>
> I would like to create an Archives page that lis
On 5/12/07, checco <[EMAIL PROTECTED]> wrote:
> into a QuerySet? Or maybe there is a way to pass to the object_list
> view directly the list of objects as returned by the SQL statement
> (with cursor.fetchall())?
If you've got the list of ids, you can use an 'id__in' lookup to get a
QuerySet out
James Bennett wrote:
> On 5/11/07, Nic James Ferrier <[EMAIL PROTECTED]> wrote:
>> Something needs to be done though... or ongoing maintenance of Django
>> apps is going to be really hard.
>
> I haven't found it terribly hard with a little coding discipline; the
> way we've handled it is to write
I've sent this to Jacob to be included in the blog roll, but since he
hasn't responded still, maybe the email somehow went missing.
So, drop by my blog:
http://orestis.gr/
and leave a comment. I plan to have a lot of write-ups about the
making of it, and as I discover more features of Django I'
On Sat, 2007-05-12 at 13:29 -0700, Mark Phillips wrote:
> Thank you, Don. I understand what Malcolm wrote. I didn't include the
> trace back and that was indeed a mistake.
>
> After walking through the set up and making some adjustments
> to .htaccess, I stopped getting a trace back in the br
64 matches
Mail list logo