Two request.GET on same site

2011-03-09 Thread maciekjbl
Hi, My problem is how can I separate two request on the same site. This situation is caused by text field in base template and form in another template which extends base. My view.py: def search(request): if 'q' in request.GET: term = request.GET['q'] prod = Producent.objects

Failure to execute Transactional unit tests.

2011-03-09 Thread Kartik
Hi Django Gurus, I am trying to execute a transactional test and I see this problem: Error: Database moglog couldn't be flushed. Possible reasons: * The database isn't running or isn't configured correctly. * At least one of the expected database tables doesn't exist. * The SQL was invalid.

Re: Django and an indirect access to the database tables (over stored procedures calls for data retrieval and modification)

2011-03-09 Thread Michael Radziej
On Tue, 8 Mar 2011 22:18:12 -0800 (PST), Vazir wrote: > There is some examples via raw() for data selects, but nothing > about data updates. Any suggestions? If you want to go this path, you can override the save method and do raw SQL instead to interact with the stored procedures. Go into the dj

cannot change the year in the admin datepicker

2011-03-09 Thread Kenneth Gonsalves
hi, a client has pointed out to me that it is not possible to change the year in the admin datepicker. One has to go back month by month or manually do it in the text input. Could this be considered a bug? -- regards KG http://lawgon.livejournal.com Coimbatore LUG rox http://ilugcbe.techstud.org/

Re: Django and an indirect access to the database tables (over stored procedures calls for data retrieval and modification)

2011-03-09 Thread Vazir
Have a clue now, thanks so much! -- 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 django-users+unsubscr...@googlegroups.com. For mo

Sharable permalinks

2011-03-09 Thread Torsten Bronger
Hallöchen! We create a central database for our research institute. One must be logged-in in order to access any pages. Sometimes, however, it is interesting to be able to send a deep link in an email to an external collegue who doesn't have an account. The collegue should then be able to see t

how to write data to csv using DictWriter

2011-03-09 Thread sushanth Reddy
Hi, How to write below data to csv in below output format ? list of dict data=[{'date': datetime.date(2011, 2, 8), 'user': u'xxx', 'status': u'P'}, {'date': datetime.date(2011, 2, 8), 'user': u'yyy', 'status': u'P'}, {'date': datetime.date(2011, 2, 8), 'user': u'zzz', 'status': u'P'},

Django + WebFaction file: where to place the ie_css3.htc file?

2011-03-09 Thread Sithembewena Lloyd Dube
Hi Folks, Perchance somebody here is hosting Django sites at WebFaction, I need advice on the situation described below: - I have the file ie_css3.htc, which enables Internet Explorer to render CSS3. - The file's functionality can be accessed by adding the attribute * behaviour:url('ie_css3.htc')

What is the best server for Django

2011-03-09 Thread Chen Xu
I am thinking to buy a server, and integrated with Django environment. So could anyone please give me some suggestions, which server is the best for this, amazon ec2 or? Thanks very much Best regards -- ⚡ Chen Xu ⚡ -- You received this message because you are subscribed to the Google Groups "

Re: how to write data to csv using DictWriter

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 01:33 -0800, sushanth Reddy wrote: > How to write below data to csv in below output format ? http://docs.djangoproject.com/en/dev/howto/outputting-csv/ -- regards KG http://lawgon.livejournal.com Coimbatore LUG rox http://ilugcbe.techstud.org/ -- You received this message

Re: Django + WebFaction file: where to place the ie_css3.htc file?

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 11:51 +0200, Sithembewena Lloyd Dube wrote: > - The site is hosted at WebFaction - the setup there isn't like > typical GCI/ > PHP sites, with a root folder and such. > > Any ideas please? what did webfaction support say about this? I would suggest finding out where your fa

Re: how to write data to csv using DictWriter

2011-03-09 Thread sushanth Reddy
I have gone through to that documentation,but output in wired format ,plz add few lines of codes to undersstand better -- 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 unsub

Re: Django + WebFaction file: where to place the ie_css3.htc file?

2011-03-09 Thread Sithembewena Lloyd Dube
Hi Kenneth, I am yet to ask WebFaction. Thanks for the suggestion, I did put the file next to the favicon (in MEDIA_ROOT) and IE still won't execute the VML. Thanks. On Wed, Mar 9, 2011 at 11:55 AM, Kenneth Gonsalves wrote: > On Wed, 2011-03-09 at 11:51 +0200, Sithembewena Lloyd Dube wrote: > >

Re: how to write data to csv using DictWriter

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 02:00 -0800, sushanth Reddy wrote: > I have gone through to that documentation,but output in wired > format ,plz > add few lines of codes to undersstand better https://bitbucket.org/lawgon/fossconf/src/71c974a48f25/web/views.py at line 1022 onwards -- regards KG http://law

Re: What is the best server for Django

2011-03-09 Thread Norberto Leite
What you need is a the proper server for your application needs.If you are looking for managed hosting there are plenty of options to do this, a simple google query will give a lifetime of options. Now if you want to manage your own server instance and you need to define which type of machine you a

Re: What is the best server for Django

2011-03-09 Thread Norberto Leite
PS - You are not buying a server on EC2, google apps engine or any VPS provider, you are renting! On Wed, Mar 9, 2011 at 11:33 AM, Norberto Leite wrote: > What you need is a the proper server for your application needs.If you are > looking for managed hosting there are plenty of options to do th

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Russell Keith-Magee
On Wed, Mar 9, 2011 at 4:43 PM, Kenneth Gonsalves wrote: > hi, > > a client has pointed out to me that it is not possible to change the > year in the admin datepicker. One has to go back month by month or > manually do it in the text input. Could this be considered a bug? Well, it's not a bug, be

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 18:58 +0800, Russell Keith-Magee wrote: > Either way, this is worth a ticket, and it would be a good project to > tackle for 1.4. shall I file a ticket? I am still amazed that it took me 4 odd years to notice this. -- regards KG http://lawgon.livejournal.com Coimbatore LUG

Re: Django + WebFaction file: where to place the ie_css3.htc file?

2011-03-09 Thread Sithembewena Lloyd Dube
Problem solved, thanks to the brilliant folks at WebFaction. *behaviour:url('/site_media/css/ie_css3.htc')* <= MEDIA_URL + rest of path. Gracias. On Wed, Mar 9, 2011 at 12:08 PM, Sithembewena Lloyd Dube wrote: > Hi Kenneth, > > I am yet to ask WebFaction. Thanks for the suggestion, I did put th

The server failed after serving a video file.

2011-03-09 Thread balu
Hi all :) I'm trying to include a video into my webpage. The page is loading fine and the video I embedded is playing properly. But... after loading of page, the server unexpectedly stopped working and it is showing an error message as below. From then it is not serving the requests. Please let m

Re: Django + WebFaction file: where to place the ie_css3.htc file?

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 13:16 +0200, Sithembewena Lloyd Dube wrote: > Problem solved, thanks to the brilliant folks at WebFaction. they are good guys -- regards KG http://lawgon.livejournal.com Coimbatore LUG rox http://ilugcbe.techstud.org/ -- You received this message because you are subscribed

Re: The server failed after serving a video file.

2011-03-09 Thread Tom Evans
On Wed, Mar 9, 2011 at 11:19 AM, balu wrote: > Hi all :) > > I'm trying to include a video into my webpage. The page is loading > fine and the video I embedded is playing properly. > > But... after loading of page, the server unexpectedly stopped working > and it is showing an error message as bel

Re: The server failed after serving a video file.

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 11:26 +, Tom Evans wrote: > These are to be expected in this sort of scenario. If you want to > support this sort of architecture, use a different hosting solution > for development, eg mod_wsgi, mod_fastcgi etc. you could even proxy nginx to devserver and get the best o

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Ramiro Morales
On Wed, Mar 9, 2011 at 8:07 AM, Kenneth Gonsalves wrote: > On Wed, 2011-03-09 at 18:58 +0800, Russell Keith-Magee wrote: >> Either way, this is worth a ticket, and it would be a good project to >> tackle for 1.4. > > shall I file a ticket? I am still amazed that it took me 4 odd years to > notice

Re: cannot change the year in the admin datepicker

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 08:33 -0300, Ramiro Morales wrote: > > shall I file a ticket? I am still amazed that it took me 4 odd years > to > > notice this. > > There is already a [1]ticket for this. I've just tried the latest > patch, it > applies (with some fuzz) and works. Souyou can use that one >

Re: The server failed after serving a video file.

2011-03-09 Thread Tom Evans
On Wed, Mar 9, 2011 at 11:29 AM, Kenneth Gonsalves wrote: > On Wed, 2011-03-09 at 11:26 +, Tom Evans wrote: >> These are to be expected in this sort of scenario. If you want to >> support this sort of architecture, use a different hosting solution >> for development, eg mod_wsgi, mod_fastcgi e

Re: What is the best server for Django

2011-03-09 Thread william ratcliff
For hosted, I rather like webfaction. On Wed, Mar 9, 2011 at 5:34 AM, Norberto Leite wrote: > PS - You are not buying a server on EC2, google apps engine or any VPS > provider, you are renting! > > > On Wed, Mar 9, 2011 at 11:33 AM, Norberto Leite wrote: > >> What you need is a the proper server

Logging raw sql

2011-03-09 Thread Dave Sluder
I need to log all insert/update/delete queries such that the database could be rebuilt from the log. I know I can do this at the database level, but I need to log selectively for certain models. The statements captured from db.connection.queries still contain parameters so they won't work. Does an

Job on Django + python

2011-03-09 Thread Prashant C
Hi , We are looking for developers looking to work on a Django + python project, job location is mumbai, Salary is not an issue for a right candidate you can send me an email at prashantchaudha...@gmail.com Regards Prashant chaudharry -- You received this message because you are subscribed to

Multiple Servers and Authentication Sessions Breaking

2011-03-09 Thread Matthew Roy
I'm running a site with 2 front end servers (lighttpd with django in fcgi daemons) and one database server (MySQL). The two front end servers are in DNS round-robin so a user might get some content from one and some from the other in any given session. All this works fine and has had no problems fo

Re: What is the best server for Django

2011-03-09 Thread Bruce Dou
Linode or EC2. On Wed, Mar 9, 2011 at 5:53 PM, Chen Xu wrote: > I am thinking to buy a server, and integrated with Django environment. So > could anyone please give me some suggestions, which server is the best for > this, amazon ec2 or? > > Thanks very much > Best regards > > -- > ⚡ Chen Xu ⚡ >

Re: Multiple Servers and Authentication Sessions Breaking

2011-03-09 Thread Tom Evans
On Wed, Mar 9, 2011 at 8:24 AM, Matthew Roy wrote: > I'm running a site with 2 front end servers (lighttpd with django in > fcgi daemons) and one database server (MySQL). The two front end > servers are in DNS round-robin so a user might get some content from > one and some from the other in any g

Re: Job on Django + python

2011-03-09 Thread spawgi
Hello Prashant, Can you please send detailed JD. Thanks and Regards, Sumod On Wed, Mar 9, 2011 at 12:38 PM, Prashant C wrote: > Hi , > > We are looking for developers looking to work on a Django + python > project, job location is mumbai, > Salary is not an issue for a right candidate > > you c

Re: Logging raw sql

2011-03-09 Thread krzysiekpl
Hi, if you are using postgresql you can use logger_collector. Try this: http://www.postgresql.org/docs/8.3/static/runtime-config-logging.html. On 9 Mar, 05:04, Dave Sluder wrote: > I need to log all insert/update/delete queries such that the database > could be rebuilt from the log. I know I can

RE: Re: Multiple Servers and Authentication Sessions Breaking

2011-03-09 Thread Henrik Genssen
and do you use the same SECRET_KEY on both servers? regards Henrik >reply to message: >date: 09.03.2011 13:33:17 >from: "Tom Evans" >to: django-users@googlegroups.com >subject: [] Re: Multiple Servers and >Authentication Sessions Breaking > >On Wed, Mar 9, 2011 at 8:24 AM, Matthew Roy wrote:

automated query if already exists

2011-03-09 Thread Szabo, Patrick (LNG-VIE)
Hi, Since django is able to do so much so easy i was wandering if there was some kind of possibility to check if an entry with the same values already exists. I've tried unique_together but this only does the job on the database end and if i want to store an not unique object i get an erro

Re: Job on Django + python

2011-03-09 Thread Prashant C
Hi, JOB DESCRIPTION The vacancy is for a large Mumbai-based media house which has incubated a media-focused private equity fund, focusing on India and other emerging markets. DESIGNATION: Manager – Software Development REPORTING TO:

Re: automated query if already exists

2011-03-09 Thread Casey Greene
Hi Patrick, Does get not do what you want? http://docs.djangoproject.com/en/dev/topics/db/queries/#retrieving-a-single-object-with-get Hope this helps, Casey On 03/09/2011 08:03 AM, Szabo, Patrick (LNG-VIE) wrote: Hi, Since django is able to do so much so easy i was wandering if there was so

AW: automated query if already exists

2011-03-09 Thread Szabo, Patrick (LNG-VIE)
Hi, So easy :-) Thanks i just didn't think of that hat. Kind regards . . . . . . . . . . . . . . . . . . . . . . . . . . Patrick Szabo XSLT Developer LexisNexis Marxergasse 25, 1030 Wien mailto:patrick.sz...@lexisnexis.at Tel.: +43 (1) 534 52 - 1573 Fax: +43 (1) 534 52 - 146 -Urspr

Re: Sharable permalinks

2011-03-09 Thread urukay
Hi, one way is to do it like google docs when you want to share your doc with other people for viewing only..generate link with unique key e.g. www.whatever.com/page/321fg6h4fgh321fdh654fh654fh/ You store the key in your DB and verify validity of the link. Then you can also restrict access to it,

Re: Why does Django Fail on Date Field?

2011-03-09 Thread octopusgrabbus
This is a MySQL 5.0+ database. I can manually insert using Query Browser. On Mar 8, 12:34 pm, octopusgrabbus wrote: > Sorry. The error is Exception Type: > ValidationError > Exception Value: > [u'Enter a valid date in -MM-DD format.'] > > I have printed out for myself to prove that my date is

Re: Two request.GET on same site

2011-03-09 Thread Norberto Leite
Rule number one of any html: Only one form per page! I would recommend the usage of template_tags / include tag to control the usage of only one form or the usage of 2 different base.html. Since I'm a strong supporter of DRY I wouldn't 2 different types of base.html but would control the encoding

redirect and still pass dict

2011-03-09 Thread Szabo, Patrick (LNG-VIE)
Hi, I want to redirect to a certains url, but still pass a dict like in render_to_response...is that possible ?! Kind regards . . . . . . . . . . . . . . . . . . . . . . . . . . Patrick Szabo XSLT Developer LexisNexis Marxergasse 25, 1030 Wien mailto:patrick.sz...@lexisnexis.at Tel.:

CSRF Cookie in IE

2011-03-09 Thread cootetom
I am experiencing some off behaviour with CSRF but only in IE browsers. Using Django 1.2.5 (final). I have a page that has no form and no use of {% csrf_token %} but it does make a POST request using JavaScript. I have implemented the jQuery code to grab the CSRF cookie value for all AJAX requests

Re: CSRF Cookie in IE

2011-03-09 Thread krzysiekpl
Did you try add custom header X-CSRFToken ? Try this solution if youre using jquery $.ajaxSetup({ beforeSend: function(xhr, settings) { if (!(/^http:.*/.test(settings.url) || / ^https:.*/.test(settings.url))) { // Only send the token to relative URLs i.e. locall

Re: CSRF Cookie in IE

2011-03-09 Thread David Markey
If its not too much trouble for you, I've switched to GETs instead of POSTs for my AJAX calls, so i wont have to think about CSRF again. On 9 March 2011 14:12, krzysiekpl wrote: > Did you try add custom header X-CSRFToken ? Try this solution if youre > using jquery > > $.ajaxSetup({ >b

Re: CSRF Cookie in IE

2011-03-09 Thread cootetom
I have got the jQuery that does the ajaxSetup. However the problem is when #csrfmiddlewaretoken isn't on the page. My jQuery is as the Django documentation suggests which is to read the cookie value which is meant to be set at every request. If the user hasn't visited a page that has #csrfmiddlewa

Re: CSRF Cookie in IE

2011-03-09 Thread Casey Greene
Everything makes sense about this except for: > If the user hasn't visited a page that has #csrfmiddlewaretoken on it > then there is also no cookie, in IE only. I am looking in firefox as well and I cannot see that cookie until I visit a page that has the csrf_token on it -- afterwards it pers

Re: Django + WebFaction file: where to place the ie_css3.htc file?

2011-03-09 Thread Sithembewena Lloyd Dube
Yep, they are. Thanks to you Kenneth, for pointing me in the right direction! Had spent a lot of time wrecking my head over this one. On Wed, Mar 9, 2011 at 1:20 PM, Kenneth Gonsalves wrote: > On Wed, 2011-03-09 at 13:16 +0200, Sithembewena Lloyd Dube wrote: > > Problem solved, thanks to the bril

How to delete ONLY m2m relation?

2011-03-09 Thread galgal
model: class Province(models.Model): user = models.ManyToManyField(User, blank=True) name = models.CharField(max_length=30, unique=True) How can I delete relation when I know user_id and province_id? If i user delete() method it also removes province and I want to avoid it. -- You recei

Re: What is the best server for Django

2011-03-09 Thread Sithembewena Lloyd Dube
I guess it all depends on what one's needs are. For Django, I only have WebFaction experience and I second William Ratcliff on that note. They have been brilliant, offering a very user-friendly setup process as well as great turnaround times on support. They also - stay very current on software up

Re: What is the best server for Django

2011-03-09 Thread Sithembewena Lloyd Dube
P.S: by "custom modules", I really meant long-running processes. They also limit the number of users allocated per shared machine to maintain decent performance. On Wed, Mar 9, 2011 at 4:47 PM, Sithembewena Lloyd Dube wrote: > I guess it all depends on what one's needs are. For Django, I only hav

Re: What is the best server for Django

2011-03-09 Thread James Abel
+1 webfaction -- 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 django-users+unsubscr...@googlegroups.com. For more options, visit t

Re: Bug in Django admin?

2011-03-09 Thread Martin Tiršel
Hi Michael, On Tue, 08 Mar 2011 11:05:40 +0100, Michael Radziej wrote: Hi Martin! Args--you're right. Stupid fingers :-) I meant .../admin/appname/booltest/?completed__exact=0 Does it work that way for you with 0 instead of False? Yes, if I rewrite URL to ?completed__exact=0, then I

Re: How to delete ONLY m2m relation?

2011-03-09 Thread Casey Greene
If you are using django 1.2 or lower you will have to override delete. http://docs.djangoproject.com/en/dev/topics/db/models/#overriding-predefined-model-methods For 1.3 you can use the new on_delete: http://docs.djangoproject.com/en/dev/ref/models/fields/#django.db.models.ForeignKey.on_delete H

Re: How to delete ONLY m2m relation?

2011-03-09 Thread galgal
Thanks, but I don't want to delete any "main" objects. I want to delete ONLY 1 specific relation - I know user and province, and want to unlink the user from province. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send

Re: How to delete ONLY m2m relation?

2011-03-09 Thread Casey Greene
In that case, I believe you can remove it with user.province_set.remove(province) user.save() if you have the user and province objects. I am going from memory here. I tried to find this in the docs to make sure but couldn't. Hope this helps, Casey On 03/09/2011 10:02 AM, galgal wrote: Th

Re: CSRF Cookie in IE

2011-03-09 Thread cootetom
I think I can only get it working in IE because IE forgets the cookie when the browser closes and the other browsers on my machine aren't. I think the fact that I have only found this in IE is not really related. I guess I'm miss understanding the use of CSRF. Perhaps the correct way is to place {

Re: Two request.GET on same site

2011-03-09 Thread bruno desthuilliers
On 9 mar, 14:58, Norberto Leite wrote: > Rule number one of any html: > Only one form per page! I have quite a few sites (django or whatever) with many forms per page. It's just a matter of being careful with forms actions and fields names. -- You received this message because you are subscri

Re: Two request.GET on same site

2011-03-09 Thread Tom Evans
On Wed, Mar 9, 2011 at 4:34 PM, bruno desthuilliers wrote: > > > On 9 mar, 14:58, Norberto Leite wrote: >> Rule number one of any html: >> Only one form per page! > > I have quite a few sites (django or whatever) with many forms per > page. It's just a matter of being careful with forms actions a

Re: Two request.GET on same site

2011-03-09 Thread bruno desthuilliers
On 9 mar, 09:01, maciekjbl wrote: > Hi, > > My problem is how can I separate two request on the same site. This > situation is caused by text field in base template and form in another > template which extends base. (snip) > > My base template : >   >   Strona G³ówna • >   Wyszukaj Producenta:

Queryset using group_by on different fields than the ones in the aggregation function

2011-03-09 Thread Massimiliano della Rovere
We have this model in module X: class A(models.Model): when = models.DateTimeField() type = models.CharField(max_length=10) subtype = models.CharField(max_length=10) data = models.CharField(max_length=100) I am trying to do something like: SELECT MAX(when), type, subtype, data FROM x_a GR

Re: Logging raw sql

2011-03-09 Thread Dave Sluder
Thanks krzysiekpl, I actually have to use mysql. Having browsed through the django source, I don't think there is anyway to intercept the query unless it were done for example in mysqldb, since the library actually generates the raw sql. I've discovered the general_log to table feature of mysql 5.1

Error 503 Service Unavailable from 127.0.0.1

2011-03-09 Thread pjstunna
Hi, I just recently discovered Django and I'm following the Django tutorial as it is written on the website ( http://docs.djangoproject.com/en/dev//intro/tutorial01/ ) but when i start the development server and view http://127.0.0.1:8000 from my browser I get this error Error 503 Service Unavai

Re: Bug in Django admin?

2011-03-09 Thread Michael Radziej
Hi Martin! On Wed, 09 Mar 2011 15:58:54 +0100, Martin Tiršel wrote: > NO = False > YES = True > YES_NO_CHOICES = ( > (NO, 'no'), > (YES, 'yes') > ) > > to > > > NO = 0 > YES = 1 > YES_NO_CHOICES = ( > (NO, 'no'), > (YES, 'yes') > ) > > Then I get 0 or 1 for filter instead

Template Referencing Dictionary By Name

2011-03-09 Thread octopusgrabbus
This is for Django 1.2 and MySQL 5.x How does a template know a dictionary's name, if a dictionary is supplied in render_to_response? totals_dict['TotalActiveAccounts'] = ret_list[0] totals_dict['TotalBillableAccounts'] = ret_list[1] totals_dict['TotalNon-BillableAccounts'] = int(ret_l

Re: Error 503 Service Unavailable from 127.0.0.1

2011-03-09 Thread Casey Greene
Do you have DEBUG = True in your settings.py? If not, set it to true and that should provide additional information. Hope this helps, Casey On 03/09/2011 12:35 PM, pjstunna wrote: Hi, I just recently discovered Django and I'm following the Django tutorial as it is written on the website ( ht

Re: Two request.GET on same site

2011-03-09 Thread maciekjbl
On 9 Mar, 17:41, bruno desthuilliers wrote: > On 9 mar, 09:01, maciekjbl wrote: > > My base template : > >   > >   Strona G³ówna • > >   Wyszukaj Producenta: > name="q"> > > Is that the full (relevant) code ? If yes, the closing tag is > missing, and you don't have any submit in it (and

Introducing Site Deploy, a GUI-based tool for web site deployment (with Django support!)

2011-03-09 Thread Andreas Sommer
Hello everyone! In the last weeks, I've been working on a PyGTK-based tool that eases the deployment of web sites to remote servers. It is cross-platform, tested on Windows and Linux, and comes with support for Django sites. I tried to make usage as easy as possible, but there's also documentation

Re: jquery toggle in form from model

2011-03-09 Thread Andres Lucena
El mié, 09-03-2011 a las 12:17 -0500, Rich Wilson escribió: > Hello all, I was wondering if I could get some guidance using jquery. > > I have a form from model in which I would like to display certain form > fields based on a check box being checked or unchecked. Could also be > done using a but

authentication

2011-03-09 Thread Tony
I have been looking into django-socialauth and am wondering how well it works. Another question I have about it is, if these users log in with their accounts from other sites, what is the best way for me to store their data and keep track of them? Thanks for the help. -- You received this messa

Re: Weird behaviour in Django logging (Django 1.3 RC)

2011-03-09 Thread Edwin
I've had help from SO: http://stackoverflow.com/questions/5249265/strange-behaviour-in-django-logging-django-1-3-rc/5250829#5250829 The solution is simply to explicitly call self.format(record) on my emit() method under DatabaseHandler. Hope this helps whoever face a similar problem. -Edwin On

Re: Two request.GET on same site

2011-03-09 Thread Tom Evans
On Wed, Mar 9, 2011 at 6:35 PM, maciekjbl wrote: > On 9 Mar, 17:41, bruno desthuilliers > wrote: >> (and is misspelled FWIW). > What do you mean is misspelled ? Compare/contrast. Cheers Tom -- You received this message because you are subscribed to the Google Groups "Django users" group.

Re: What is the best server for Django

2011-03-09 Thread Andy
It really depends on your needs. If you are also running a DB on the server and have significant traffic, virtual servers such as EC2 or Linode might not work well because they tend to have poor IO performance. On Mar 9, 4:53 am, Chen Xu wrote: > I am thinking to buy a server, and integrated wit

#PgEast 2011: Session Schedule Up, registration open (Django Training)

2011-03-09 Thread Joshua D. Drake
Hey, #PgEast has its schedule up. Register: https://www.postgresqlconference.org/register Schedule: https://www.postgresqlconference.org/ There is a Django training available on the 22nd. Sincerely, Joshua D. Drake -- PostgreSQL.org Major Contributor Command Prompt, Inc: http://www.commandpr

Re: Customizing how the elements are listed in admin change_list.html

2011-03-09 Thread MrMuffin
If anybody else finds this post and wonders how it went. Follow these instructions. Works great! http://stackoverflow.com/questions/4794528/extending-django-admin-templates-altering-change-list Thomas On 8 Mar, 23:59, Thomas Weholt wrote: > My app handles photos and the admin shows these photos

Re: What is the best server for Django

2011-03-09 Thread Kenneth Gonsalves
On Wed, 2011-03-09 at 16:47 +0200, Sithembewena Lloyd Dube wrote: > I guess it all depends on what one's needs are. For Django, I only > have > WebFaction experience and I second William Ratcliff on that note. They > have > been brilliant, offering a very user-friendly setup process as well as > gr

database connection from long lasting script

2011-03-09 Thread Brian Craft
I have a script that sits in a loop, doing occasional queries, something like while 1: wait.for.some.event() object=get.some.django.db.object() do.something.with(object) transaction.commit_unless_managed() The last line is required so the script will see updates to the database from other

Re: What is the best server for Django

2011-03-09 Thread Huy Ton That
+1 for Rackspace. On Wed, Mar 9, 2011 at 8:25 PM, Kenneth Gonsalves wrote: > On Wed, 2011-03-09 at 16:47 +0200, Sithembewena Lloyd Dube wrote: > > I guess it all depends on what one's needs are. For Django, I only > > have > > WebFaction experience and I second William Ratcliff on that note. They

Re: When do we stop using Django admin?

2011-03-09 Thread ajaishankar
Thanks everyone for your valuable suggestions! On Mar 8, 3:23 am, Michael Radziej wrote: > On Mon, 7 Mar 2011 21:49:45 -0800 (PST), ajaishankar > wrote: > > I do know we can tweak the admin to restrict querysets etc. and also > > override admin templates - but is admin preferable in this situat

Re: Template Referencing Dictionary By Name

2011-03-09 Thread Karen Tracey
On Wed, Mar 9, 2011 at 1:30 PM, octopusgrabbus wrote: > This is for Django 1.2 and MySQL 5.x > > How does a template know a dictionary's name, if a dictionary is > supplied in render_to_response? > > It doesn't. > totals_dict['TotalActiveAccounts'] = ret_list[0] >totals_dict['TotalBillabl

Django app and Amazon AWS (beginner)

2011-03-09 Thread nai
Hi guys, I've been lurking on the forums and groups for a while now but I've recently ran into some problems I couldn't figure out whilst learning to code. Basically, I have a simple working webapp on my local machine. I've signed up for the free Amazon tier and have been messing around with it s

Re: Django app and Amazon AWS (beginner)

2011-03-09 Thread Huy Ton That
Well, if you are just doing a development test, as it seems below foregoing apache, you can do sudo nohup python manage.py runserver 0.0.0.0:8000 It will keep on running after you close the terminal. -H On Wed, Mar 9, 2011 at 9:46 PM, nai wrote: > Hi guys, > > I've been lurking on the forums

Re: Django app and Amazon AWS (beginner)

2011-03-09 Thread Brian Bouterse
I recommend running your runserver inside screenand leaving it detached when you are logged out. Brian On Wed, Mar 9, 2011 at 9:50 PM, Huy Ton That wrote: > Well, if you are just doing a development test, as it seems below foregoing > apache, you can do >

Re: Django app and Amazon AWS (beginner)

2011-03-09 Thread nai
Ok, this is where I start running into the limitations of my knowledge. Does installing a webserver like Apache 'persist' the website then? Is that what I should be doing if I want to do things 'properly'? Also, when I run nohup, I get: nohup: ignoring input and appending output to `nohup.out' On

Re: Django app and Amazon AWS (beginner)

2011-03-09 Thread nai
According to djangoproject, deploying Django with apache and mod_wsgi is the way to go. I keep seeing these terms over and over again but I've had it explained to me over and over but I still don't get it. I know this is getting a bit off topic but it would be great if someone could take another st

Re: Django app and Amazon AWS (beginner)

2011-03-09 Thread CLIFFORD ILKAY
On 03/09/2011 10:37 PM, nai wrote: According to djangoproject, deploying Django with apache and mod_wsgi is the way to go. I keep seeing these terms over and over again but I've had it explained to me over and over but I still don't get it. I know this is getting a bit off topic but it would be g

Re: Re: Multiple Servers and Authentication Sessions Breaking

2011-03-09 Thread Matthew Roy
@Tom: I'm not configuring SESSION_ENGINE so it should be the default django.contrib.sessions.backends.db @Henrik: That may well be the problem, I have a cron job to generate a random secret key on each server weekly. I will try setting them statically. Thanks for your responses, I'll let you know

Re: PLEASE HELP ME IN ADDING A CATEGORY IN THE ADMIN SITE

2011-03-09 Thread Sneaky Wombat
Ronny is right. South is the way to go. no pun intended. On Mar 8, 6:30 pm, ronny wrote: > Ignore the rest of these guys, and go here: > > http://south.aeracode.org/docs/tutorial/part1.html#tutorial-part-1 > > It's called django-south, all the cool kids are using it. > > Enjoy.  :D > > -ron > >

Any clue what this error could mean

2011-03-09 Thread ydjango
[Errno 2] No such file or directory: '/home/xyz/webapps/prodxyz/temp/ tmpn2C5Lk.upload' I see it in logs. Any clue what this error could mean or be related to? -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: Any clue what this error could mean

2011-03-09 Thread delegbede
The error message is straight forward. You are referring to a file or directory that doesn't exist. Check the name of the file and be sure you've spelt it correctly or you actually saved it in the directory from where you're tryin to access it. Sent from my BlackBerry wireless device from MTN

Re: how to write data to csv using DictWriter

2011-03-09 Thread sushanth Reddy
thanks you for the link ,KG -- 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 django-users+unsubscr...@googlegroups.com. For more op