UTF8 character set problem

2006-10-27 Thread PythonistL
I use MySQL database with utf8 character set and utf8_czech_ci collation. It works well on Linux server( with mod_python) but when I try to export the data and import into the same Django application 9but running on XP machine with runserver 0,the utf8 is gone.Instead of a proper coding there ar

SESSION_COOKIE_AGE

2006-10-27 Thread PythonistL
I changed SESSION_COOKIE_AGE value in my settings file to lower value. After an hour or so, I increased the SESSION_COOKIE_AGE value but now I can not log in neither to admin nor to my Django application. When I try to log in to admin it says: Looks like your browser isn't configured to accept co

Setting cookies expiration via SESSION_COOKIE_AGE

2006-10-27 Thread PythonistL
I changed SESSION_COOKIE_AGE to a lower value and now I can not log in to admin site. It says: Looks like your browser isn't configured to accept cookies. Please enable cookies, reload this page, and try again But the bowser does accept cookies. Eventhough I increased SESSION_COOKIE_AGE value ,

Problem with session.

2006-10-27 Thread PythonistL
I changed SESSION_COOKIE_AGE value in my settings file to lower value. After an hour or so, I increased the SESSION_COOKIE_AGE value but now I can not log in neither to admin nor to my Django application. When I try to log in to admin it says: Looks like your browser isn't configured to accept co

Post-after-redirect question

2006-05-04 Thread PythonistL
Is there any difference if I use in my script a post-after-redirect that is HttpResponseRedirect (something like return HttpResponseRedirect("/ChangeProductList/") ) or if a user use REFRESH from his browser? I use my webhosting on Dreamhost and I found out that if I do a post-after-redirect

Is it possible to use render_to_response in a child function

2006-05-08 Thread PythonistL
I have # def Parent(request): print "I am in parent" Child(request) return render_to_response('ParentResponse',) def Child(request): print "I am in child" return render_to_response('ChildResponse',) # >From P

Re: Is it possible to use render_to_response in a child function

2006-05-08 Thread PythonistL
Joey , Thank you for the explanation Best regards, L. --~--~-~--~~~---~--~~ 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

Question

2006-05-08 Thread PythonistL
I have a shop application where a user register the NameOfShop and the new shop is created for him. If he wants to see his shop he must use URL something like http://www.domain.com/shop/NameOfShop Is there a possibility to make the URL shorter that is - to remove shop name-. for example to

Re: Question

2006-05-10 Thread PythonistL
Jorge, Thanks a lot for help.It works. L. --~--~-~--~~~---~--~~ 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

Re: Which is better: dreamhost or bluehost?

2006-05-11 Thread PythonistL
I also use Dreamhost, but recently not running well for me. I noticed that when more users log in, the site is down( timeouts) and I must ask Dreamhost support to correct the problem. Yesterday, it happened again, and I complained that the problem repeats all over and over again so they told me

How to prevent a page from being cached?

2006-05-11 Thread PythonistL
Is there a way how to prevent a page from being cached? I use response= HttpResponseRedirect("/ChangeProductList/") response['Pragma'] = "no cache" response['Cache-Control'] = "no-cache,must-revalidate" response['Pragma'] = "no cache" response['Expires'] = "Wed, 11 Jan 2006 05:00:00 GMT" return re

Re: How to prevent a page from being cached?

2006-05-11 Thread PythonistL
Response looks like this 00:00.437 - server connected] HTTP/1.1 200 OK Date: Thu, 11 May 2006 09:07:37 GMT Server: Apache/1.3.33 (Unix) mod_throttle/3.1.2 DAV/1.0.3 mod_fastcgi/2.4.2 mod_gzip/1.3.26.1a PHP/4.4.2 mod_ssl/2.8.22 OpenSSL/0.9.7e Vary: Cookie Content-Length: 5406 Connection: close Cont

Re: How to prevent a page from being cached?

2006-05-13 Thread PythonistL
Hello Luke, Thank you for your reply.Unfortunatelly I use Python 2.3 so, I can not use decorators as you described. Is it possible to change HTTP headers ,in Django,in this way below? response= HttpResponseRedirect("/ChangeProductList/") response['Pragma'] = "no cache" response['Cache-Control']

Re: How to prevent a page from being cached?

2006-05-16 Thread PythonistL
Malcom, thank you for the reply L. --~--~-~--~~~---~--~~ 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

Dreamhost - does anyone know a better webhosting?

2006-05-16 Thread PythonistL
I have been using Dreanhost for share webhosting service for a few months already but I found out it is very unreliable. If there is a higher traffic my site goes down. From the beginnig I was happy - no problem - but now when more users come to my site - problems repeat all over and over again.

Re: Announcing Tabblo, a Django app

2006-05-18 Thread PythonistL
I wanted to try it out but I can not sing up. --~--~-~--~~~---~--~~ 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,

Django and WSGI

2006-05-19 Thread PythonistL
Does anyone use Django with WSGI ? I have a problem with my script if there is a heavy load.The server stop responding. This week it happens 3 times. Is it a problem of Django running on WSGI? Or is it a problem my webhosting provider ( Dreamhost.com)? Any suggestions? Thank you L. --~--~--

Re: Django and WSGI

2006-05-19 Thread PythonistL
I received a reply from Dreamhost: " However, I have been on the browser and your website is working now. So it doesn't sound like there is a configuration problem on the server, but I suspect that there may be an intermittent high load issue. Normally the system admins correct high load i

NULL vs.None

2006-05-20 Thread PythonistL
Question 1 I noticed in MySQL that if a table field has NULL value, then I can test in Python with that filed with None. In otherwords NULL in MySQL is the same as None. in Python Is it so or am I wrong? Question 2. I also would like to test NULL values in my templates. So I would like to us

Re: NULL vs.None

2006-05-20 Thread PythonistL
ith HTTP; Sat, 20 May 2006 16:28:02 + (UTC) From: "PythonistL" <[EMAIL PROTECTED]> To: "Django users" Subject: Re: NULL vs.None Date: Sat, 20 May 2006 09:28:02 -0700 Message-ID: <[EMAIL PROTECTED]> In-Reply-To: <[EMAIL PROTECTED]> References: <[E

What server configuration to use

2006-05-26 Thread PythonistL
I am going to setup a server to use it with Django. I am going to use: Trustix Linux (http://www.trustix.org) mod_Python with Apache Is 1GB memory enough? Regards, L. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Is Django suitable for a big numbers of visitors??

2006-05-29 Thread PythonistL
I use Django with FastCGI ( via WSGI) and have problems with downtime when more visitors come to my website. Did anyone test Django apps for high numbers of visitors(hits)? If so, what configurations would you reccomend? Thank you for reply L. --~--~-~--~~~---~--~--

Re: Is Django suitable for a big numbers of visitors??

2006-05-29 Thread PythonistL
Thank you for your reply Now I have in my settings.py file: DEBUG = False MIDDLEWARE_CLASSES = ( "django.middleware.common.CommonMiddleware", "django.middleware.sessions.SessionMiddleware", "django.middleware.doc.XViewMiddleware", "django.middleware.cache.CacheMiddleware", ) CA

Databases from different projects

2006-05-31 Thread PythonistL
Let's suppose I have project1 that has TableProject1 and project2 that has TableProject2 Is it possible to use in project2 data from TableProject1 ? Thank you for reply L. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Goog

How to do this with Django?

2006-05-31 Thread PythonistL
I have two independent sites written in Django. Each requires login. And users must login in separately. I would like to make things easy for users and if a user signs in one site he will be also signed automatically into the other. Is it possible? L. --~--~-~--~~~

Mod_python and Django - PROBLEM

2006-06-09 Thread PythonistL
I am going to setup Django with mod_python and Apache on Linux but when I try to use a script from a browser I will get the error: ## Mod_python error: "PythonHandler django.core.handlers.modpython" Traceback (most recent call last): File "/usr/lib/python2.3/site-packages/mod_p

Re: Mod_python and Django - PROBLEM

2006-06-10 Thread PythonistL
Hello Michael, thank you for help.It solved that problem. But now it says File "/home/django_src/django/core/db/__init__.py", line 23, in ? raise ImproperlyConfigured, "Could not load database backend: %s. Is your DATABASE_ENGINE setting (currently, %r) spelled correctly? Available options a

Re: Mod_python and Django - PROBLEM

2006-06-10 Thread PythonistL
My settings.py looks like this: # Django settings for mimiproject project. DEBUG =True TEMPLATE_DEBUG = DEBUG SESSION_COOKIE_AGE=259200 ADMINS = ( # ('Your Name', '[EMAIL PROTECTED]'), ) MANAGERS = ADMINS SERVER_EMAIL='[EMAIL PROTECTED]' DEFAULT_FROM_EMAIL='[EMAIL PROTECTED]' EMAIL_HOST='loc

Re: Mod_python and Django - PROBLEM

2006-06-10 Thread PythonistL
Simon, On Apache I use Apache/2.0.55 (Trustix Secure Linux/Linux) mod_python/3.2.8 Python/2.3.5 PHP/5.0.5 mod_perl/2.0.0 Perl/v5.8.7 Do you think there can be a problem? Thank you for help regards, L --~--~-~--~~~---~--~~ You received this message because you are

Re: Mod_python and Django - PROBLEM

2006-06-10 Thread PythonistL
Malcom. Thank you for help. I followed http://www.modpython.org/live/current/doc-html/inst-trouble.html so i added to my httpd.conf SetHandler mod_python PythonHandler mod_python.testhandler but when I point my browser to the /mpinfo URL I will get Mod_python err

Re: Mod_python and Django - PROBLEM

2006-06-12 Thread PythonistL
Malcom, Thank you for the help. You were right. Permissions were the problem L. --~--~-~--~~~---~--~~ 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.co

Mod_python and Django - AGAIN

2006-06-12 Thread PythonistL
I installed Django on Apache but still not successfully. When I try to open a view/page that normaly works (e.g on Dreamhost where I use FastCGI), on Linux box with Mod_python and Django I will get Mod_python error: "PythonHandler django.core.handlers.modpython" Traceback (most r

Re: Mod_python and Django - AGAIN

2006-06-13 Thread PythonistL
No, it can not be that problem. I use the same models and source on Dreanhost and it works. But now I want to use my Linux box with mod_python and the code does not work. So, any other idea how to solve the problem? Thank you. L --~--~-~--~~~---~--~~ You receiv

Re: Mod_python and Django - AGAIN

2006-06-13 Thread PythonistL
Yes, it uses the same source that runs on Dreamhost - both Django and my project. I had to make only some different settings in settings.py file because I installed the project in a different directory and also installed PIL and MySQLdb by myself. So, how to find the cause of the problem? L.

Re: Cutting output of flup's FastCGI server

2006-06-19 Thread PythonistL
Hello Ivan, It is intereresting. But why do you use/prefer FastCGI to mod_python ? I am asking because I used for my Django apps FastCGI with Dreamhost but a lot of problems - Apache server used to hang when there were a lot of visitors. Now I switched to mod_python and it works great. regards, L

Is it possible to do this from templates?

2006-06-27 Thread PythonistL
Hi, Is it possible to test ,if an image exists, from a template? To explain: Let's suppose in my template I use and {{ImageName}} is a picture that can exists but it needn't. But if it does not exist, then I will receive an ugly picture in my view (HTML)result. So, I test that in my view but it

Re: Django & Apache 1.x

2006-07-05 Thread PythonistL
Gabor, what trafic do you have at your website and what server configuration do you use? I am asking that because you use FastCGI and I had big problems with FastCGI when there was highload.So I decided to move to mod_python and no problem since Regards, L --~--~-~--~~~-

How to ?

2006-07-15 Thread PythonistL
I have the following model # class User(meta.Model): Login=meta.CharField(maxlength=50,unique=True) Password=meta.CharField(maxlength=30,blank=True) class Gallery(meta.Model): Title = meta.CharField( maxlength=80) Description = meta.TextField(_("Description"), bla

Re: How to ?

2006-07-15 Thread PythonistL
NikI, thank you for your help. I tried >>>p=photos.get_object(id__exact='18') then >>> p.gallery_id.created_id Traceback (most recent call last): File "", line 1, in ? AttributeError: 'long' object has no attribute 'created_id' Where is a problem? When I tried >>> p.gallery_id I received 27

Re: How to ?

2006-07-15 Thread PythonistL
Not sure I fully understand. Can you please explain a little more? Do you mean that p.gallery.created should work( where p is my photo object)? Thank you for help L. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: How to ?

2006-07-18 Thread PythonistL
No, it does NOT work for me. Finally I found a reason. I use old Django version and I must use get_gallery() and not gallery.Similarly get_created() and not created, so wanted_user = photos.get_object(id__exact='3').get_gallery().get_created() --~--~-~--~~~---~--~

Best idea?

2006-07-22 Thread PythonistL
I am creating an application in Django where users can insert photos and I would like each owner of the photo(s) to be able to grant/revoke access to this photo(s) to other visitors. What could be the best idea how to do that? Thank you for replies L. --~--~-~--~~~---

Re: Best idea?

2006-07-24 Thread PythonistL
Thanks a lot for help L. --~--~-~--~~~---~--~~ 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 [EMAIL

How to read parameters

2006-07-24 Thread PythonistL
Let's suppose a user click on a URL something like this http://www.server.com/ListTradeLeads/?page=6&userId=admin . So some parameters( page and userId) are sent to the server but how can I find out ,in Django,values of these parameters , that is the page is 6 and userId is admin? I would like

Re: How to read parameters

2006-07-24 Thread PythonistL
>From outside but also can be sent from inside Django application --~--~-~--~~~---~--~~ 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 unsubscri

Is possible to have ManyToMany relation....

2006-07-25 Thread PythonistL
Is possible to have ManyToMany and OneToMany relation like this? class User(meta.Model): Login=meta.CharField(maxlength=50,unique=True) Email=meta.EmailField(_('e-mail address'),blank=True) class Gallery(meta.Model): Title = meta.CharField(_("title"), maxlength=80) created =

Re: Is possible to have ManyToMany relation....

2006-07-25 Thread PythonistL
Aidas, Thank you for your help. I checked http://www.djangoproject.com/documentation/models/m2m_and_m2o/ but I can not find if it works with 0.91 version, that I use. Do you know that? Thank you for the reply L, --~--~-~--~~~---~--~~ You received this message bec

Where can be a problem??

2006-07-26 Thread PythonistL
I have the following models class User(meta.Model): Login=meta.CharField(maxlength=50,unique=True) Email=meta.EmailField(_('e-mail address'),blank=True) class Gallery(meta.Model): Title = meta.CharField(_("title"), maxlength=80) created = meta.ForeignKey(User) access=me

Re: Where can be a problem??

2006-07-27 Thread PythonistL
Chris, Thank you for help L. --~--~-~--~~~---~--~~ 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 [E

Auction in Django

2006-07-27 Thread PythonistL
Has anyone tried to implement an auction application in Django? L. --~--~-~--~~~---~--~~ 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 unsubscr

DateTimeField

2006-07-27 Thread PythonistL
Is it possible to use a DateTimeField from a model definition as an input field in a form? I have class MyTest(meta.Model): Subject=meta.CharField( maxlength=90) Description=meta.TextField() CurrentBid=meta.IntegerField(maxlength=6,blank=True,null=True) StartTime=meta.Date

Re: DateTimeField

2006-07-27 Thread PythonistL
jrs, I tried to use {{form.EndTime.time}} and {{form.EndTime.date}} in a form but still NO input field is shown. Do you have any suggestion why? Thank you L --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django u

Re: DateTimeField

2006-07-28 Thread PythonistL
I found the solution. It must be {{form.EndTime_date}} {{form.EndTime_time}} --~--~-~--~~~---~--~~ 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

How set a Date and Time format for an input field

2006-07-28 Thread PythonistL
Is it possible to set a Date and Time format for an input field in a form? For example instead of 2006-7-27 for Date I would like to use 27-7-2006 and istead of 10:21 for Time field I would like to use 10/21 Thank you for help L. --~--~-~--~~~---~--~~ You receiv

Question about tags

2006-08-01 Thread PythonistL
I have this very simple tag # from django.core.template import Library, Node from django.core import template register = Library() class FirstTestNode(Node): def __init__(self, num): self.num = num def render(self, context): context['print_results'] = self.num

Re: Question about tags

2006-08-01 Thread PythonistL
Thanks a lot.It works! L. --~--~-~--~~~---~--~~ 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 [EMAIL

How to get a subset of records from a subset?

2006-08-08 Thread PythonistL
To explain: Let's suppose we have a command HistoryList=historys.get_list(id__exact='2',order_by=['-PostedDate']) that command extracts a few records and from them I would like to use for further processing all without the first or last record. How can I do that in Django version 0.91? Thank yo

Re: How to get a subset of records from a subset?

2006-08-08 Thread PythonistL
Thank you David and John for help L. --~--~-~--~~~---~--~~ 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 em

Datetime and a template tag

2006-08-11 Thread PythonistL
Im my template tag I use something like this if resolve_variable(EndTime, context)>datetime.datetime.now(): ... ... ... where in a table EndTime is 2006-08-10 12:56:00 and say datetime.datetime.now() is about datetime.datetime(2006, 8, 11, 13, 35, 14, 312000) from that said above, should be r

Re: Datetime and a template tag

2006-08-11 Thread PythonistL
Hello Malcom, Thank you for your reply. The value of resolve_variable(EndTime, context) is 2006-08-10 12:56:00 but how can I find out the type in template tag? When I try something like this context['Type']=type(resolve_variable(self.EndTime, context)) im my tag and in template I use {{Type}} i

Re: Datetime and a template tag

2006-08-11 Thread PythonistL
Malcom, Thanks a lot for help So, to sum up type ofresolve_variable(EndTime, context)-datetime.datetime.now() is 'datetime.timedelta' type of resolve_variable(EndTime, context) is 'datetime.datetime' type ofdatetime.datetime.now() is 'datetime.datetime' and value ofresolve_varia

Re: Datetime and a template tag

2006-08-11 Thread PythonistL
And here is the tag from django.core.template import Library, Node,resolve_variable from django.core import template import datetime register = Library() class TimedifNode(Node): def __init__(self, EndTime): self.EndTime = EndTime def render(self, context): Difference=re

Re: Datetime and a template tag

2006-08-12 Thread PythonistL
Malcom, Thank you very much for your time and help. I found the reason of my problem. I had two different template tags but in both the same context variable and one overwrote the other. Best regards, L. --~--~-~--~~~---~--~~ You received this message because yo

Model & Views

2006-08-15 Thread PythonistL
In my model definition I have a field like this: Category = meta.CharField(choices=Categorylist,maxlength=30,blank=True) where Categorylist is defined in the models definition file like this: Categorylist=( ('1','Children clothes'), ('17','Dresses'), ('18','shoes'), ... ... ('20','suits'), (. I

Re: Model & Views

2006-08-15 Thread PythonistL
Malcom, Thanks a lot for help L. --~--~-~--~~~---~--~~ 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

What relating model should I use?

2006-08-17 Thread PythonistL
In my project I have a user class that represents user's information. Now I would like to give users a possibility to set their favourite users. That means a user will set some his favourite users What model shall I use? Relating an object to itself, many-to-one or another model? Thank you reply

Re: What relating model should I use?

2006-08-17 Thread PythonistL
Maciej, Thank you for help. L --~--~-~--~~~---~--~~ 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 [E

Re: Problems with "import settings"

2006-08-26 Thread PythonistL
I had a similar problems because I did not set up proper permissions on files. If your Django runs under Linux too, you can check the permissions if it helps Regards, L --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Group

How to correct this error?

2006-09-05 Thread PythonistL
Hello , I use MySQL with Django and it works great untill I try to insert non-English characters.Then I get (1267, "Illegal mix of collations (utf8_czech_ci,IMPLICIT) and (latin1_swedish_ci,COERCIBLE) for operation '='") How can I correct this error? Thank you for help L. --~--~-~--~-

Re: How to correct this error?

2006-09-05 Thread PythonistL
Limodou, Thank you for your reply. Is it possible to "convert" the field in MySQL instead of converting characters? Thank you for reply L --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post

Re: How to correct this error?

2006-09-05 Thread PythonistL
Thank you for the reply I still use Django 0.91 and I could not find django/db/backends/mysql/base.py I found only C:\Python23\Lib\site-packages\django\core\base.py and C:\Python23\Lib\site-packages\django\core\db\mysql.py Which file should I change with if self.connection.get_server_info() >=

Re: How to correct this error?

2006-09-06 Thread PythonistL
Corey, Thank you for your reply. The exception Value (1267, "Illegal mix of collations (utf8_czech_ci,IMPLICIT) and (latin1_swedish_ci,COERCIBLE) for operation '='") is from this command: gallerys.get_list(Title__exact=new_data['Title']) So, I would guess that Title field or new_data['Title']

Re: How to correct this error?

2006-09-06 Thread PythonistL
Hello Corey, Thank you for your reply. I do not like PHP and I prefer comand line. So, after some testing I finally found out the command ALTER TABLE `tablename ` CHANGE `fieldname` `fieldname` VARCHAR( 10 ) CHARACTER SET utf8 COLLATE utf8_czech_ci. Regards, L. --~--~-~--~~

Re: Downloading the djangoproject.com site code

2005-08-05 Thread PythonistL
I use http://tortoisesvn.tigris.org/ It seems much more better for my XP

Why this error?

2005-08-16 Thread PythonistL
I defined my model like this from django.core import meta class Registration(meta.Model): fields = ( meta.CharField('ID_', maxlength=50,unique=True), meta.CharField('Password', maxlength=50), meta.EmailField('Email', maxlength=50), meta.CharField('InvoicingNam

Problem

2005-08-19 Thread PythonistL
After I finished tutorials I wanted to start playing with my own application. So I created my new project called shopproject and defined my model like this shop.py# from django.core import meta class Registration(meta.Model): fields = ( meta.CharField('Logi

Re: Problem

2005-08-20 Thread PythonistL
Problem solved. The reason was that DJANGO_SETTINGS_MODULE variable had to be set up globally. In other words if I set up DJANGO_SETTINGS_MODULE in one command console and try following command: from django.models.shop import * from Python shell opened in a new command console (without setting

How to set up a directory for images?

2005-09-03 Thread PythonistL
I have images( that I want to use on my web pages) in a directory C:\Django\Pictures so in main.py ( settings subdirectory ) I changed MEDIA_ROOT = 'C:\Django' MEDIA_URL = '' and in my template index.html I use but it does not work and I do not know what is wrong. Can you please help? Thank y

Why this view does NOT work

2005-09-07 Thread PythonistL
From http://www.djangoproject.com/documentation/forms/ I copied an example and only little changed it for my model. My model is like this ## class Registration(meta.Model): Login= meta.CharField( maxlength=50,unique=True) Password= meta.CharField( maxlength=50)

Generic views - problem(s)

2005-09-17 Thread PythonistL
A docs about generic views say that all date-based generic views have the following optional arguments: ## template_name - Overrides the default template name used for the view. extra_lookup_kwargs - A dictionary of extra lookup parameters extra_context - A dictionary of ex

Re: Generic views - problem(s)

2005-09-17 Thread PythonistL
Jacob, thanks a lot for help. I have one more question: You advised extra_lookup_kwargs = { 'order_by' : ['Email'], 'limit': 15, } ( with equal sign ) but it also works with ' : ' like this 'extra_lookup_kwargs' : { 'order_by' : ['Email'], 'limit': 15,} is there any difference? Th

Problem/questions about generic views

2005-09-24 Thread PythonistL
I use the generic view django.views.generic.list_detail.object_list In my main.py url I have ##main.py### info_dict = {'template_name':'shop/MyOwnTemplate', 'app_label': 'shop', 'module_name': 'registrations', 'paginate_by':10,

How to find details if HTTP 500 - Internal server error

2005-09-30 Thread PythonistL
I use mod_python with Apache and it works Django ok, until there is an error in my Django code. Then I get HTTP 500 - Internal server error without any details. Is it possible to get some debug info that could help me find the reason of HTTP 500 - Internal server error ? In my httpd.conf I have

Re: How to find details if HTTP 500 - Internal server error

2005-10-01 Thread PythonistL
Hello Adrian, Thank you for your reply. I checked my Apache error log but I could not see the traceback that could help. It ended up with [notice] mod_python: (Re)importing module 'django.core.handlers.modpython' For this particular error of yesterday I found out that the reason, for HTTP 500 -

Joins - a problem

2005-11-04 Thread PythonistL
I have the following model class User(meta.Model): Login= meta.CharField( maxlength=50,unique=True) Password= meta.CharField( maxlength=50) Email= meta.EmailField(blank=True) InvoicingAddress= meta.CharField( maxlength=200,blank=True) Date_joined=meta.DateTimeFiel

Re: Joins - a problem

2005-11-05 Thread PythonistL
Thank you Jeff for the explanation. Regards, Lad.

HTTP_REFERER

2005-11-05 Thread PythonistL
I use the following view for user's log in ### def MyLogin(request): WrongID=0 AllGood=1 if request.POST: print "Refferer1 from POST",Refferer1 try: u=users.get_object(Login__exact=request.POST['Login']) except users.UserDoesNotExist:

Re: HTTP_REFERER

2005-11-07 Thread PythonistL
Thank you Andreas and Luke for help and explanation Regards, L.

Why it doesn't work in Django

2005-11-18 Thread PythonistL
I have a following problem with CSS file. My template Test.html looks like this ## TEST ONLY ### where Test.css looks like this ### body { background: #00; color: #FF; font: 10pt verdana, geneva, lucida, 'lucida grande', arial

Re: Why it doesn't work in Django

2005-11-19 Thread PythonistL
Thank you ALL for the explanation. I checked http://code.djangoproject.com/ticket/810 to try django.views.static.serve and it worked with CSS. . But I found out that in CSS file I can not use p. EntryField {... ... ... } but must use p.EntryField {... ... ... } I also tried django.views.stati

Re: Why it doesn't work in Django

2005-11-20 Thread PythonistL
Yes, I use XP windows Regards, L.

Re: Why it doesn't work in Django

2005-11-21 Thread PythonistL
Eugene, Thank you. If I download the latest development version, will be the change already present? Or where can I find the file in Django installation to apply the patch by myself? thank you regards, L.

Finding numbers of visitors

2005-11-21 Thread PythonistL
Hello, Is there a way how to find out ( via Django) all visitors at my website at one time( both signed and guests)? Would it be possible by using request.session? Or is there a better way? Regards, L.

Re: Why it doesn't work in Django

2005-11-21 Thread PythonistL
Thank you, Adrian. I downloaded the latest version and now images work well. Regards, L

Re: Finding numbers of visitors

2005-11-22 Thread PythonistL
Adrian, thank you for your reply. I checked http://www.djangoproject.com/documentation/sessions/ and you say:``Session dictionary keys that begin with an underscore are reserved for internal use by Django. `` So, I expect some to be exist. Is there a list of such session dictionary keys that beg

A question

2005-11-26 Thread PythonistL
Hello, In my web application I would like to separate admin interface from the rest. In other words I would like users to login to my web application via my own interface not via admin.Is it possible? (I think it should be but then I do not know how to use things such as request.user (to find

Session

2005-11-26 Thread PythonistL
Hi, Is it possible to do the following with the sessions? In my web application I would like to tell a user ,when he is doing shopping to cart, that he is login. So, in the login page ( where user insert his ID and password) I used request.session['UserIsLogged'] = UserID and on a page, where

Re: Session

2005-11-26 Thread PythonistL
Hello David, Thank you for your reply. I tried the demo but I think it has the same problem I described. I registered ( as La ) and was logged in( so far so good). But when I start another web browser window from and just open your address again, (http://da.textdriven.com:8027/welcome/) the demo a

Re: Session

2005-11-28 Thread PythonistL
Thank you ALL for the explanation. Now I know something more but yet not sure whether the following procedure will work for different users.The procedure is like this: In my web application I would like to tell a user (when he is doing shopping to a shopping cart), that he is signed with his ID. T

Uploading a file

2005-12-03 Thread PythonistL
Hi, Did anybody try to upload a file via Django? Can provide any working example? Thank you Regards, L.

  1   2   >