Re: Accessing SSL client certificate variables
Look here: http://code.google.com/p/sslauth/ :) On 17 окт, 16:22, lmierzej <[EMAIL PROTECTED]> wrote: > Is there a way to access apache/mod_python's SSL client certificate > variables in django? > > I found only this:http://code.djangoproject.com/ticket/2938- is it > really not possible without patching django source code? --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Javascript including in django's template doesn't work
Hi, guys, I met a problem on including external javascript file in template. My form.html and jquery.js are put under /study/ajax/templates, (study is the project name while ajax is the app name.) In form.html, jquery.js is included by the following code: But it didn't work. In console, I got the following log: [15/Nov/2007 00:09:28] "GET /ajax/register/jquery.js HTTP/1.1" 404 2434 I feel strange about the URL: /ajas/register/jquery.js, but I don't know how to get it right. -- Best regards! -Sting --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
MOD_PYTHON ERROR
Hello all, I'm not for sure what this error is all about. I had django up and running with out flaw for quite a while but last night I decided to svn update my django source and that's when it seemed to flip out giving me this error message. Also I have have a script that I run from time to time that removes pyc file so I don't know if there is some sort of conflict there assuming not. Currently I am using ubuntu 7.10 with apache/django/postgres and python 2.5.1 Help would be aprociated Thanks in advance! MOD_PYTHON ERROR ProcessId: 12752 Interpreter:'django.xyz.net' ServerName: 'django.xyz.net' DocumentRoot: '/htdocs' URI:'/blogger/' Location: '/' Directory: None Filename: '/htdocs' PathInfo: '/blogger/' Phase: 'PythonHandler' Handler:'django.core.handlers.modpython' Traceback (most recent call last): File "/usr/lib/python2.5/site-packages/mod_python/importer.py", line 1537, in HandlerDispatch default=default_handler, arg=req, silent=hlist.silent) File "/usr/lib/python2.5/site-packages/mod_python/importer.py", line 1229, in _process_target result = _execute_target(config, req, object, arg) File "/usr/lib/python2.5/site-packages/mod_python/importer.py", line 1128, in _execute_target result = object(arg) File "/srv/django-0.96-current/django/core/handlers/modpython.py", line 187, in handler return ModPythonHandler()(req) File "/srv/django-0.96-current/django/core/handlers/modpython.py", line 151, in __call__ self.load_middleware() File "/srv/django-0.96-current/django/core/handlers/base.py", line 26, in load_middleware for middleware_path in settings.MIDDLEWARE_CLASSES: File "/srv/django-0.96-current/django/conf/__init__.py", line 28, in __getattr__ self._import_settings() File "/srv/django-0.96-current/django/conf/__init__.py", line 57, in _import_settings self._target = Settings(settings_module) File "/srv/django-0.96-current/django/conf/__init__.py", line 85, in __init__ raise EnvironmentError, "Could not import settings '%s' (Is it on sys.path? Does it have syntax errors?): %s" % (self.SETTINGS_MODULE, e) EnvironmentError: Could not import settings 'django_site.settings' (Is it on sys.path? Does it have syntax errors?): No module named settings --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Django Users every thing
Hi Django Users All International Actress Lingerie in here from USA, Europe, Africa, Rusia, Asia, Arab and Melayu Get it from http://hotmodels.pussyfier.com Cool Bro... --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Send Big File Free and Easy Apply For FREE!!! ( New Service From
Send Big File Free and Easy Send, Receive and Track files with YouSendIt. apply for free. be urgent , there is the time limits. Get Free Code: Limited Time Only! http://www.tkqlhce.com/click-2667396-10501907 --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: UnicodeError in admin in latest django
On 15-Nov-07, at 4:27 AM, Piru wrote: > I don't know how to handle this thing... 1. django version - unicode django or something older, please specify 2. database backend - unicode database or not, please specify 3. paste the model which is causing the trouble -- regards kg http://lawgon.livejournal.com http://nrcfosshelpline.in/web/ --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: learning django and python
On 14-Nov-07, at 8:41 PM, sebey wrote: > ok ok thanks love some more resurces ok, one more resource, but this is the last one: Introspection, which is the greatest python resource ever: do this: type 'python' in a console type import os and press enter type dir(os) and press enter type help(os.walk) and press enter enjoy -- regards kg http://lawgon.livejournal.com http://nrcfosshelpline.in/web/ --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: UnicodeError in admin in latest django
Hi all, it's my first post here;) I have same issue - ... UnicodeEncodeError 'ascii' codec can't encode character u'\u017c' in position 4: ordinal not in range(128) Exception Type: UnicodeEncodeError Exception Value:'ascii' codec can't encode character u'\u017c' in position 4: ordinal not in range(128) Exception Location: /django/utils/encoding.py in force_unicode, line 40 Python Version: 2.4.4 Unicode error hint The string that could not be encoded/decoded was: Pokaż swój Template error In template /django/contrib/admin/templates/admin/change_form.html, error at line 14 Caught an exception while rendering: 'ascii' codec can't encode character u'\u017c' in position 4: ordinal not in range(128) ... I don't know how to handle this thing... --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: MySqldb error:
You do not have the MySQLdb module installed and this can be tricky to setup on a hosted site. If you do not have shell access, contact your administrator and ask for this module. Otherwise either get the package or source from here http://sourceforge.net/projects/mysql-python and install it through the terminal. On Nov 14, 4:02 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I'm receiving this error as I work thru Tutorial 1 > (http://www.djangoproject.com/documentation/tutorial01/): > > [EMAIL PROTECTED] mysite]# python manage.py syncdb > Traceback (most recent call last): > File "manage.py", line 11, in ? > execute_manager(settings) > File "/usr/lib/python2.3/site-packages/django/core/management.py", > line 1672, in execute_manager > execute_from_command_line(action_mapping, argv) > File "/usr/lib/python2.3/site-packages/django/core/management.py", > line 1571, in execute_from_command_line > action_mapping[action](int(options.verbosity), > options.interactive) > File "/usr/lib/python2.3/site-packages/django/core/management.py", > line 486, in syncdb > from django.db import connection, transaction, models, > get_creation_module > File "/usr/lib/python2.3/site-packages/django/db/__init__.py", line > 11, in ? > backend = __import__('django.db.backends.%s.base' % > settings.DATABASE_ENGINE, {}, {}, ['']) > File "/usr/lib/python2.3/site-packages/django/db/backends/mysql/ > base.py", line 12, in ? > raise ImproperlyConfigured, "Error loading MySQLdb module: %s" % e > django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb > module: No module named MySQLdb > > What am I missing or is mis-configured? My site is hosted by > mediatemple, and it's a dv3 plan... if that helps. --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
MySqldb error:
I'm receiving this error as I work thru Tutorial 1 (http:// www.djangoproject.com/documentation/tutorial01/): [EMAIL PROTECTED] mysite]# python manage.py syncdb Traceback (most recent call last): File "manage.py", line 11, in ? execute_manager(settings) File "/usr/lib/python2.3/site-packages/django/core/management.py", line 1672, in execute_manager execute_from_command_line(action_mapping, argv) File "/usr/lib/python2.3/site-packages/django/core/management.py", line 1571, in execute_from_command_line action_mapping[action](int(options.verbosity), options.interactive) File "/usr/lib/python2.3/site-packages/django/core/management.py", line 486, in syncdb from django.db import connection, transaction, models, get_creation_module File "/usr/lib/python2.3/site-packages/django/db/__init__.py", line 11, in ? backend = __import__('django.db.backends.%s.base' % settings.DATABASE_ENGINE, {}, {}, ['']) File "/usr/lib/python2.3/site-packages/django/db/backends/mysql/ base.py", line 12, in ? raise ImproperlyConfigured, "Error loading MySQLdb module: %s" % e django.core.exceptions.ImproperlyConfigured: Error loading MySQLdb module: No module named MySQLdb What am I missing or is mis-configured? My site is hosted by mediatemple, and it's a dv3 plan... if that helps. --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Form Field Question from python noob
Python does not have static/public/private objects like java does. Whats happening is that self.date_form is referencing date_form and that happens in the __init__ method On Nov 14, 2:31 pm, johnny <[EMAIL PROTECTED]> wrote: > I have seen forms without the "self" in front of the fields, eg. more > like this date_from = forms.DateField() and never self.date_form > =forms.DateField(). If you include self.date_form, then date_form > becomes an attribute of an instance rather than a attribute of a > class. > > What confusing me is that, when you define form field without self, > like date_from = forms.DateField() , then are you creating only one > date_from field as in java static class or java static variable? --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Form Field Question from python noob
I have seen forms without the "self" in front of the fields, eg. more like this date_from = forms.DateField() and never self.date_form =forms.DateField(). If you include self.date_form, then date_form becomes an attribute of an instance rather than a attribute of a class. What confusing me is that, when you define form field without self, like date_from = forms.DateField() , then are you creating only one date_from field as in java static class or java static variable? --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: how to get auto recoder id?
Do a select statement on the values > > i just use this code: > > cursor = connection.cursor() > > sql = "insert into popo_status( author_id , body , time, type ) VALUES > > (%s, %s, now(), '2')" > > cursor.execute( sql,(str(row[0]),msg) ) cursor.execute("select id from popo_status where author_id = '%s' and body = '%s' and type='%s'") print cursor.fetchone()[0] > > connection.commit() That should do it, if author_id,body and type are not enough to distinguish the record you will have to muck with the datetime stuff. Im not sure what module you are using, but some return the ids from an insert statement upon execution. like when you do this > > cursor.execute( sql,(str(row[0]),msg) ) --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Multi Engine Template System (Django/Cheetah/Mako/Myghty/Genshi)
I am not talking about replacing the whole builtin template system so that framework wide requires changes. Django is the default rendering system, but others should be enabled. Django should continue to ship its template system, which is a great system and has loads practical tools for web design. I am learning to like it despite the fact that I learned Cheetah first. But Django should also have the easy option of using another system, even if it does not have to enable them by default. At the very least I am interested in doing this on my sites and will want to further investigate the differences in usage and performance of these engines in a Django environment. I will implement what I am proposing which is not meta-template API based, but instead a set of replacements to the Template class and render_to_response shortcut. Each engine will require its own particular syntax for rendering, since the APIs are slightly different among them. As far as integrating them into the main trunk? Not so sure now, still trying to think of the best way to easily allow authors access to the component replacements. Of course you can always just import the engine in your views and template away from there; these changes I am making are merely an easy way to integrate Django's template loaders and contexts with the other rendering engines. The end goal is not to have to muck with steps like: from django.template.loaders import find_template_source import engine module response = HttpResponse() template = template(find_template_source('index.tmpl')[0]) template.render(context, out_file=response) return response Instead that all would become: return render_to_response('index.tmpl', context, engine='cheetah') See? Much nicer, no mucking with template loaders, search directories, or rendering On Nov 14, 1:18 pm, "Marty Alchin" <[EMAIL PROTECTED]> wrote: > I'm generally with James on this, that users are already able to use > whatever they like; after all, it's just Python. > > The one potential concern I have is, what about generic views? As far > as I can tell, if you want to change template systems, you'd have to > abandon the existing generic views. Either just go with custom views > or rewrite the existing ones to use the new engine, but the shipped > ones become useless. > > Of course, I don't really see that as a bad thing, since I don't plan > on switching template engines, but it's at least a bigger problem than > just importing your own in your custom views. That said, if speed is > really that big of a concern, most sites can safely cache the rendered > output and avoid the overhead of the template engine *and* all the > database queries. > > And if you need that speed and you *can't* cache the output (live data > view, for example), then you're probably in a special enough case that > it's worth abandoning generic views anyway, since custom views could > be written to work a lot faster than generic ones. > > -Gul --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Multi Engine Template System (Django/Cheetah/Mako/Myghty/Genshi)
I'm generally with James on this, that users are already able to use whatever they like; after all, it's just Python. The one potential concern I have is, what about generic views? As far as I can tell, if you want to change template systems, you'd have to abandon the existing generic views. Either just go with custom views or rewrite the existing ones to use the new engine, but the shipped ones become useless. Of course, I don't really see that as a bad thing, since I don't plan on switching template engines, but it's at least a bigger problem than just importing your own in your custom views. That said, if speed is really that big of a concern, most sites can safely cache the rendered output and avoid the overhead of the template engine *and* all the database queries. And if you need that speed and you *can't* cache the output (live data view, for example), then you're probably in a special enough case that it's worth abandoning generic views anyway, since custom views could be written to work a lot faster than generic ones. -Gul --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: how to get auto recoder id?
can somebody help me, thansk! On 11月14日, 下午9时21分, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > i just use this code: > cursor = connection.cursor() > sql = "insert into popo_status( author_id , body , time, type ) VALUES > (%s, %s, now(), '2')" > cursor.execute( sql,(str(row[0]),msg) ) > connection.commit() > > it is successful, how can i get recoder id which i just inserted? > thanks --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: German django forum
Danke Jan! Ich mach mit. CU, Oliver On 13 Nov., 20:57, Jan Meier <[EMAIL PROTECTED]> wrote: > Hi, > > there is a new Forum for django help/support in german, if you speak german > check it out: > > http://www.django-resource.de/ > > See you there, > > Jan --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: block.super returning html character codes - NOT html
On Wed, Nov 14, Josh wrote: > > Hi Michael, > > > This should only be needed if you did not do what Malcolm called "Simple > > backwards compatibility", i.e. to set {% autoescape off %}. > > > > So, am I right that you didn't put such a {% autoescape off %} tag in your > > root template? Then you have to examine whether you use any html fragments > > in your template variables. > > You're right, I didn't. OK, I just was checking. > In my particular case, it is a better option to use autoescape off, so > I've switched to that instead of using safe. > > Here's my base.html now: > > {% autoescape off %} > {% block breadcrumbs %} > Home > {% endblock %} > {% endautoescape %} > > I guess a "DRY-alert" didn't go off in my head when I thought of > adding safe to all those block.super's. Ah, it's probably better that django marks each block.super automatically as safe (see my posting to django-developers with an *untested* patch), but I'm waiting for Malcolm's response. Anyway, thanks for your report! Michael -- noris network AG - Deutschherrnstraße 15-19 - D-90429 Nürnberg - Tel +49-911-9352-0 - Fax +49-911-9352-100 http://www.noris.de - The IT-Outsourcing Company Vorstand: Ingo Kraupa (Vorsitzender), Joachim Astel, Hansjochen Klenk - Vorsitzender des Aufsichtsrats: Stefan Schnabel - AG Nürnberg HRB 17689 --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Multi Engine Template System (Django/Cheetah/Mako/Myghty/Genshi)
Recently I have been in search of an alternative to the Django templating engine. Sure the engine is well produced and has many features, but it lacks certain functionality that other engines provide, like direct python syntax and parameter passing. Allowing Django to use these other engines would increase its extensibility beyond custom templatetags and filters. The author of a website might be more comfortable with a template system that they are already familiar with instead of Django's, however handy it may be. That being said, I have investigated the implementation and efficiency of rendering templates with different engines inside the Django environment. I conducted a set of trials to examine rendering speed for each of five engines; Django/Cheetah/Mako/Myghty/Genshi. The tests were run in a timed thread and the resulting speed of rendering was measured. For each engine a template was created that contained 1) a string variable ('hello world') 2) iteration over a list (range(100)) 3) a random number 4) iteration over a Django model, yielding the attributes. This template was loaded and rendered using the appropriate Django context. Time was measured with the timeit module and only represents the rendering time of the engine. For this simple test Django did OK, coming in 3rd at the middle of the pack. Genshi did horribly mostly because it is XML based which does not conform to the Django design philosophies. The one that was consistently the best by a noticeable amount was Cheetah. Here are the average times (in milliseconds) for 100 trials of 5 sets of measurement. cheetah 0.827 mako 1.328 django 2.207 myghty 2.712 genshi 8.212 I also used pylab and the chart is available here http://i239.photobucket.com/albums/ff209/justquick/template_bench.png Email me if you wish to see the raw csv output or source code for this test. These results mean that in some cases Django does not render templates the fastest. Developers should have the option to use whatever engine they want for their template system. At the same time it should still have all the compatible functionality of Django so that the extensibility of the templatetags and filters can transfer over. I am currently working on a project like this to adapt the winner (Cheetah) into a Django compatible templating engine which is available here http://code.google.com/p/django-cheetahtemplate/. What are peoples' thoughts on the issue of having a multi engine template system for Django? Does it violate the design philosophies? Is it worth trying to make this adaption now? --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Time estimation for a Django project
I've found that the only problems I encountered on my first couple of Django projects were the following: 1. Unix problems due to not being very experienced with Unix shell stuff. 2. Spending way too long trying to customize the admin because I didn't realise how easy it would be to write my own CRUD using newforms 3. Doing everything in a slightly roundabout way and then discovering too late there was a much more elegant way to do it. Look at other people's code as much as possible including the Django source. It's much less scary than you would think. A few other tips: 1. Learn to love the manage.py shell. A combination of that and the lovely django traceback (hint - raise your own exceptions "raise: Foo": and you can have a traceback whenever you want) have convered all my debugging needs. All my django projects have been finished much quicker than expected. My second Django site was a paid gig and the client was very happy. Good luck! On Nov 14, 3:39 pm, Sun Wukong <[EMAIL PROTECTED]> wrote: > Hello, > > I may get my first Django-based project soon and that's quite an > exciting news. But besides tutorials and some tests, I'm still a newbie > willing hard to get the job done right. > > And I'm running in a well-known problem : how to estimate the required > time to develop a Django based project ? Are there somewhere any rule of > thumb, based on SGBDr tables number and web-pages and newbie/pro-factor > and so on ? At least just to get an raw idea of a project size ? > > Thanks for your help > > -- > SunWukong > > Linux User #354048 > GPG Key available : 0xF4DD0AD2 on keyserver.ubuntu.com > > signature.asc > 1KDownload --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
bulk modify in the admin?
I was just curious: has anyone fooled around with extending the admin to do a sort of "bulk modify"? For example: update update multiple entries (like an article) in the database to now have the same author ? I know that making the application/html and such wouldn't be too bad for each particular use case, but just thought it would be pretty neat if I there existed a way to extend/hack the admin interface to do something similar in a more generic fashion. Thanks! Kevin --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Time estimation for a Django project
that's a very bold move. I'd say that if you can't estimate the time required, you're not ready to take on that project. But you've got to start somewhere, good luck with it. and once you guess about the time, be sure to at least triple it. -h On Nov 14, 10:39 am, Sun Wukong <[EMAIL PROTECTED]> wrote: > Hello, > > I may get my first Django-based project soon and that's quite an > exciting news. But besides tutorials and some tests, I'm still a newbie > willing hard to get the job done right. > > And I'm running in a well-known problem : how to estimate the required > time to develop a Django based project ? Are there somewhere any rule of > thumb, based on SGBDr tables number and web-pages and newbie/pro-factor > and so on ? At least just to get an raw idea of a project size ? > > Thanks for your help > > -- > SunWukong > > Linux User #354048 > GPG Key available : 0xF4DD0AD2 on keyserver.ubuntu.com > > signature.asc > 1KDownload --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: learning django and python
I don't know about the Instant Django on OSX, but Django itself is very easy. I use the python universal binary from http://www.python.org/download then download Django, untar it, and go into the extracted Django directory, run "sudo python setup.py install" That's it, Django is installed and ready to go. On Nov 14, 2007 8:49 AM, sebey <[EMAIL PROTECTED]> wrote: > > yes thats cool but one problem; I''m a mac guy so if anyone can find a > mac version of this please post > > On Nov 13, 7:37 pm, cjl <[EMAIL PROTECTED]> wrote: > > > Sebey: > > > > You may want to check out a tutorial I am working on: > > > > http://www.instantdjango.com > > > > It provides a 'newbie-friendly' introduction to Django, even if you're > > not familiar with Python yet. > > > > I haven't finished the second chapter yet, but I think the first > > chapter will help get you started, or at least help you figure out if > > Python and Django is right for you. > > > > -CJL > > > > > -- Omnem crede diem tibi diluxisse supremum. --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: learning django and python
is there anyway to download the documentation on the django site? On Nov 14, 3:11 pm, sebey <[EMAIL PROTECTED]> wrote: > ok ok thanks love some more resurces > > On Nov 14, 2:10 pm, cjl <[EMAIL PROTECTED]> wrote: > > > Buy me a mac and I'd be happy to create an OSX version of Instant > > Django for you! > > > Just kidding, but there are many websites explaining Django > > installation on OSX. You can still follow along with my tutorial after > > you have installed it. > > > Sorry I can't be of more help. I actually tried a 'hackintosh' > > installation of Tiger under vmware so I could create an OSX version, > > but it ran so slow it was unusable. > > > -CJL --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: block.super returning html character codes - NOT html
Hi Michael, > This should only be needed if you did not do what Malcolm called "Simple > backwards compatibility", i.e. to set {% autoescape off %}. > > So, am I right that you didn't put such a {% autoescape off %} tag in your > root template? Then you have to examine whether you use any html fragments > in your template variables. You're right, I didn't. In my particular case, it is a better option to use autoescape off, so I've switched to that instead of using safe. Here's my base.html now: {% autoescape off %} {% block breadcrumbs %} Home {% endblock %} {% endautoescape %} I guess a "DRY-alert" didn't go off in my head when I thought of adding safe to all those block.super's. - Josh --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: block.super returning html character codes - NOT html
Hi Josh, On Wed, Nov 14, Josh wrote: > > Fixed it. > > New feature in django-dev is HTML escaping for any template tags (good > against cross-site scripting problems). > > Had to apply the safe filter to any template tags I don't want auto- > escaped. > > OLD: {{ block.super|safe }} > > NEW: {{ block.super|safe }} This should only be needed if you did not do what Malcolm called "Simple backwards compatibility", i.e. to set {% autoescape off %}. So, am I right that you didn't put such a {% autoescape off %} tag in your root template? Then you have to examine whether you use any html fragments in your template variables. Michael -- noris network AG - Deutschherrnstraße 15-19 - D-90429 Nürnberg - Tel +49-911-9352-0 - Fax +49-911-9352-100 http://www.noris.de - The IT-Outsourcing Company Vorstand: Ingo Kraupa (Vorsitzender), Joachim Astel, Hansjochen Klenk - Vorsitzender des Aufsichtsrats: Stefan Schnabel - AG Nürnberg HRB 17689 --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Time estimation for a Django project
Hello, I may get my first Django-based project soon and that's quite an exciting news. But besides tutorials and some tests, I'm still a newbie willing hard to get the job done right. And I'm running in a well-known problem : how to estimate the required time to develop a Django based project ? Are there somewhere any rule of thumb, based on SGBDr tables number and web-pages and newbie/pro-factor and so on ? At least just to get an raw idea of a project size ? Thanks for your help -- SunWukong Linux User #354048 GPG Key available : 0xF4DD0AD2 on keyserver.ubuntu.com signature.asc Description: OpenPGP digital signature
block.super returning html character codes - NOT html
block.super was working great before i did an svn up this morning.. All of my block.super template tags are returning the HTML character codes instead of the actual HTML - so instead of getting proper HTML links, i get the text of the HTML link. Has anyone come across this? New bug? - Josh --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: learning django and python
I think the best way now is to try and post specific question when you encounter deadends. I run django on a mac, but if you need help you better start by yourself (and you will learn more). It is easier if you use sqlite and to learn, sqlite is more than enough. So follow the instruction on the doc page and install the svn version. If you're using Tiger you need to install svn first, if you're running Leopard, svn is builtin. svn : http://subversion.tigris.org/project_packages.html install : http://www.djangoproject.com/documentation/install/ Have fun! Francis On Nov 14, 10:11 am, sebey <[EMAIL PROTECTED]> wrote: > ok ok thanks love some more resurces > > On Nov 14, 2:10 pm, cjl <[EMAIL PROTECTED]> wrote: > > > Buy me a mac and I'd be happy to create an OSX version of Instant > >Djangofor you! > > > Just kidding, but there are many websites explainingDjango > > installation on OSX. You can still follow along with my tutorial after > > you have installed it. > > > Sorry I can't be of more help. I actually tried a 'hackintosh' > > installation of Tiger under vmware so I could create an OSX version, > > but it ran so slow it was unusable. > > > -CJL --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Abstracting choices
Malcolm Tredinnick napisał(a): >> In my app I have one pretty generic model that handles few (not so >> different) types of content. One of the things that make these types >> different is choice of possible states. I'd like to keep the choices >> as choices, not as separate model. Currently I have moved the choices >> out of my models.py file and import them dynamically into module's >> scope depending on the "mode" application is actually running but it >> seems a hackish by nature, I'd like to have them imported/injected >> (into module or model class scope) in more elegant way. Is this >> possible at all? >> >> I was looking at class_prepared signal, but it's fired too late... > > The "choices" attribute can be a callable. So you can determine the > choices in a function if you like. This might be of interest: > http://www.pointy-stick.com/blog/2007/03/26/django-tips-variable-choice-lists/ Thanks, I'll try this approach. -- Jarek Zgoda Skype: jzgoda | GTalk: [EMAIL PROTECTED] | voice: +48228430101 "We read Knuth so you don't have to." (Tim Peters) --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: learning django and python
ok ok thanks love some more resurces On Nov 14, 2:10 pm, cjl <[EMAIL PROTECTED]> wrote: > Buy me a mac and I'd be happy to create an OSX version of Instant > Django for you! > > Just kidding, but there are many websites explaining Django > installation on OSX. You can still follow along with my tutorial after > you have installed it. > > Sorry I can't be of more help. I actually tried a 'hackintosh' > installation of Tiger under vmware so I could create an OSX version, > but it ran so slow it was unusable. > > -CJL --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
launch python script from template by a form
Hello, I have just a really simple question: i just want to add to a template I created in my app, a form like this one: Chemin my first aim is to launch a python script (ingestion.py) which his argument is the handling result of the input type="text" value of my form The problem is that django need a good url pattern to match and screen the result of the query I tried to add (r'^spica/cgi-bin/$',''). it doesn't work because i don't know which function i could write to do it well... i don't know how to launch this script from django by apache server with mod-python go on http://optix.iap.fr/spica/test there is a text field you can enter a path (like /home/user/images/) and by pressing the button the path becomes the arg of my script ingestion.py and the script is launch after pressing... i used apache with mod-python my configuration of http.conf is this one SetHandler python-program PythonHandler django.core.handlers.modpython SetEnv DJANGO_SETTINGS_MODULE terapix.settings PythonDebug On PythonPath "['/home/semah'] + sys.path" Hope could somebody understand and answer me.. --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Time zone issue
I'm sorry, please disregard. It turns out I just needed to restart the service. I have to remember that restarting the webserver does not restart the service. Thanks. On Nov 14, 9:25 am, Justin <[EMAIL PROTECTED]> wrote: > After migrating a new site to it's future production server I seem to > be experiencing a weird error. I have a windows service (in python) > that reads phone data in through the serial port, writes the data to a > file and sets up a Django environment to write that data to the > database. Here's the catch, when saved to the database the time of the > call records is being increased by an hour. The offset in the database > is right (EST-5) and on the flat file the time is correct. > > Deployed on Windows > Postgresql 8.2 > TIME_ZONE = 'America/Detroit' > > When I pull up a vanilla python shell and a djano shell datetime.now() > is the same. Another clue may be the fact the I had to change the > timezone after setting up the app, (I forgot to change the default > "America/Chicago" to the correct zone) but have of course restarted > the web server since then. Any help would be appreciated. Thanks. > > - Justin --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Time zone issue
DO you have automatic daylight saving time? We had the same problem here, using Java and Postgres. It seems that this Windows feature have strange side-effects... On Nov 14, 2007 11:25 AM, Justin <[EMAIL PROTECTED]> wrote: > > After migrating a new site to it's future production server I seem to > be experiencing a weird error. I have a windows service (in python) > that reads phone data in through the serial port, writes the data to a > file and sets up a Django environment to write that data to the > database. Here's the catch, when saved to the database the time of the > call records is being increased by an hour. The offset in the database > is right (EST-5) and on the flat file the time is correct. > > Deployed on Windows > Postgresql 8.2 > TIME_ZONE = 'America/Detroit' > > When I pull up a vanilla python shell and a djano shell datetime.now() > is the same. Another clue may be the fact the I had to change the > timezone after setting up the app, (I forgot to change the default > "America/Chicago" to the correct zone) but have of course restarted > the web server since then. Any help would be appreciated. Thanks. > > - Justin > > > > > -- Miguel Galves - Engenheiro de Computação Já leu meus blogs hoje? Para geeks http://log4dev.com Pra pessoas normais http://miguelcomenta.wordpress.com "Não sabendo que era impossível, ele foi lá e fez..." --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Time zone issue
After migrating a new site to it's future production server I seem to be experiencing a weird error. I have a windows service (in python) that reads phone data in through the serial port, writes the data to a file and sets up a Django environment to write that data to the database. Here's the catch, when saved to the database the time of the call records is being increased by an hour. The offset in the database is right (EST-5) and on the flat file the time is correct. Deployed on Windows Postgresql 8.2 TIME_ZONE = 'America/Detroit' When I pull up a vanilla python shell and a djano shell datetime.now() is the same. Another clue may be the fact the I had to change the timezone after setting up the app, (I forgot to change the default "America/Chicago" to the correct zone) but have of course restarted the web server since then. Any help would be appreciated. Thanks. - Justin --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: learning django and python
Buy me a mac and I'd be happy to create an OSX version of Instant Django for you! Just kidding, but there are many websites explaining Django installation on OSX. You can still follow along with my tutorial after you have installed it. Sorry I can't be of more help. I actually tried a 'hackintosh' installation of Tiger under vmware so I could create an OSX version, but it ran so slow it was unusable. -CJL --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: learning django and python
yes thats cool but one problem; I''m a mac guy so if anyone can find a mac version of this please post On Nov 13, 7:37 pm, cjl <[EMAIL PROTECTED]> wrote: > Sebey: > > You may want to check out a tutorial I am working on: > > http://www.instantdjango.com > > It provides a 'newbie-friendly' introduction to Django, even if you're > not familiar with Python yet. > > I haven't finished the second chapter yet, but I think the first > chapter will help get you started, or at least help you figure out if > Python and Django is right for you. > > -CJL --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
how to get auto recoder id?
i just use this code: cursor = connection.cursor() sql = "insert into popo_status( author_id , body , time, type ) VALUES (%s, %s, now(), '2')" cursor.execute( sql,(str(row[0]),msg) ) connection.commit() it is successful, how can i get recoder id which i just inserted? thanks --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Backwards-incompatible change: automatic HTML escaping
For everybody who updates frequently: revision [6671] -- which was committed about five minutes ago -- contains a change that is possibly more disruptive than most if you're displaying HTML via template variables. So I'm taking the slightly unusual step of drawing your attention to it. So read the backwards incompatible changes wiki page ([1]) before panicking. [1] http://code.djangoproject.com/wiki/BackwardsIncompatibleChanges#Auto-escapingintemplates Thanks, Malcolm -- The hardness of butter is directly proportional to the softness of the bread. http://www.pointy-stick.com/blog/ --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Abstracting choices
On Wed, 2007-11-14 at 04:47 -0800, Jarek Zgoda wrote: > Hello, all. > > In my app I have one pretty generic model that handles few (not so > different) types of content. One of the things that make these types > different is choice of possible states. I'd like to keep the choices > as choices, not as separate model. Currently I have moved the choices > out of my models.py file and import them dynamically into module's > scope depending on the "mode" application is actually running but it > seems a hackish by nature, I'd like to have them imported/injected > (into module or model class scope) in more elegant way. Is this > possible at all? > > I was looking at class_prepared signal, but it's fired too late... The "choices" attribute can be a callable. So you can determine the choices in a function if you like. This might be of interest: http://www.pointy-stick.com/blog/2007/03/26/django-tips-variable-choice-lists/ Regards, Malcolm -- Two wrongs are only the beginning. http://www.pointy-stick.com/blog/ --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Abstracting choices
Hello, all. In my app I have one pretty generic model that handles few (not so different) types of content. One of the things that make these types different is choice of possible states. I'd like to keep the choices as choices, not as separate model. Currently I have moved the choices out of my models.py file and import them dynamically into module's scope depending on the "mode" application is actually running but it seems a hackish by nature, I'd like to have them imported/injected (into module or model class scope) in more elegant way. Is this possible at all? I was looking at class_prepared signal, but it's fired too late... Cheers J. --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: binding data with imageupload in newforms
On 14-Nov-07, at 4:07 PM, Thejaswi Puthraya wrote: >> file_data = {'mugshot': {'filename':'face.jpg' >> ... 'content': }} > > f = open("somefile.jpg","r") > image_data = f.read() > > file_data = {'mugshot': {'filename': 'face.jpg', 'content': > image_data}} yes, I got that far. But how do I make the filename (if there is already a file) appear on the edit form. I am doing it manually at present - but looks like an ugly hack -- regards kg http://lawgon.livejournal.com http://nrcfosshelpline.in/web/ --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: binding data with imageupload in newforms
> file_data = {'mugshot': {'filename':'face.jpg' > ... 'content': }} f = open("somefile.jpg","r") image_data = f.read() file_data = {'mugshot': {'filename': 'face.jpg', 'content': image_data}} Cheers Thejaswi Puthraya --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Bug? - model with property + objects.values()
On Wed, 2007-11-14 at 10:15 +0100, Jens Diemer wrote: > > I would like to escape the data from a model attribute... > > Here a example: > > > > Old model: > - > class Page(models.Model): > ... > name = models.CharField() > ... > - > > > I have changed the model to this: > - > class Page(models.Model): > ... > __name = models.CharField( > db_column='name' > ) > def __get_name(self): > return escape(self.__name) > > def __set_name(self, data): > self.__name = data > > name = property(__get_name, __set_name) > ... > - > > > > Now, i have a problem :( > > This works, fine: > page = Page.objects.all()[0] > print page.name > > > But here i get a 'FieldDoesNotExist' Traceback: > print Page.objects.values("name") > [...] > > Why? > Is this a bug? Everything is behaving normally. You just can't do what you're trying to do. When the class is constructed (when the __new__ method is called), Django doesn't know (and has no way of possibly knowing) that the "name" property is simply a proxy for the "__name" Field object. And Django does special initialisation processing for Field objects, including creating a list of fields on the model. So, when you are trying to use your field in a queryset, you must refer to it using it's true name ("__name" in your case). Malcolm -- Atheism is a non-prophet organization. http://www.pointy-stick.com/blog/ --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Verticity
On Nov 14, 11:16 am, "jhon.bowl" <[EMAIL PROTECTED]> wrote: > On Nov 13, 2:33 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> > wrote: > > > > > > >http://www.verticity.com > > > On Nov 13, 2:26 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> > > wrote: > > > > Verticity is currently hiring software enginers and programmers > > > specialy dot net developers in thier regional office Karachi. > > > little about verticity inc: > > > > VertiCity was founded on the premise that through the medium of the > > > internet geographic barriers could be broken down and a truly global > > > city, where IT services could be provided for clients throughout the > > > world, would be created. Our REMS (Remote Employee Management System) > > > allows our clients to take advantage of a pool of highly talented and > > > cost effective IT professionals. Our services enable IT Application > > > Development process to become efficient and cost effective. Not only > > > have our services reduced our clients IT costs by up to 80%, but by > > > providing them highly qualified professionals, VertiCity has also > > > saved them immeasurable hours of search time and have made offshore > > > outsourcing seamless and without borders. > > > > Verticity, Inc is a privately held and funded conglomeration of web/ > > > software technologies and services -first started in 2001. We are > > > rooted in product and have produced innovations in distinct and > > > growing B2B spaces. Many of our professionals are experts in their > > > fields and by tapping into our resources, clients are able to take > > > advantage of Verticity's outsourcing model which has proved to be > > > highly effective and cost-saving. > > > > At Verticity, we help clients innovate their businesses to achieve > > > extraordinary results from their customer relationships, business > > > operations, and technology. Verticity's promise to our clients: to do > > > whatever it takes to deliver the right business results, on time and > > > on budget. We have consistently delivered on this promise, achieving > > > success for our clients. Not happy? > > > > Clients choose Verticity for our commitment to their success, our > > > dedication to delivering our promise, and the straightforward and > > > collaborative way we work with them. Not many companies give their > > > clients complete control over their offshore team. Verticity prides > > > itself on that.- Hide quoted text - > > > - Show quoted text -+ > > Well Silver glad to see this news tht verticity inchttp://www.verticity.com > has several openings in their company. Verticity inchttp://www.verticity.com > is a largest software House in the IT world and peoples recomend > verticity for development. thnx for sharing such nice knowledgement.- Hide > quoted text - > > - Show quoted text - hi silver and john Verticity inc is a name of success. some sites are using http://www.verticity.com name for bad publicity --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Bug? - model with property + objects.values()
I would like to escape the data from a model attribute... Here a example: Old model: - class Page(models.Model): ... name = models.CharField() ... - I have changed the model to this: - class Page(models.Model): ... __name = models.CharField( db_column='name' ) def __get_name(self): return escape(self.__name) def __set_name(self, data): self.__name = data name = property(__get_name, __set_name) ... - Now, i have a problem :( This works, fine: page = Page.objects.all()[0] print page.name But here i get a 'FieldDoesNotExist' Traceback: print Page.objects.values("name") The complete traceback: - Traceback (most recent call last): File "./PyLucid_shortcuts_test.py", line 24, in print Page.objects.values("name") File "./django/db/models/query.py", line 108, in __repr__ return repr(self._get_data()) File "./django/db/models/query.py", line 482, in _get_data self._result_cache = list(self.iterator()) File "./django/db/models/query.py", line 597, in iterator fields = [self.model._meta.get_field(f, many_to_many=False) for f in self._fields] File "./django/db/models/options.py", line 131, in get_field raise FieldDoesNotExist, '%s has no field named %r' % (self.object_name, name) django.db.models.fields.FieldDoesNotExist: Page has no field named 'name' - Why? Is this a bug? -- Mfg. Jens Diemer A django powered CMS: http://www.pylucid.org --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---
Re: Using Django Template Engine
Hello Malcolm, thank you for your reply. Sorry, that I explained my problem too bad. In the meantime I found the solution for my problem and It's really simple. And it's a embarrassing situation for me, because the solution is documented: http://www.djangoproject.com/documentation/templates_python/#rendering-a-context Bernd On 14 Nov., 01:45, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Mon, 2007-11-12 at 23:04 -0800, Brot wrote: > > Hello, > > > I found a code example for "Using Markup" in the django wiki: > >http://code.djangoproject.com/wiki/UsingMarkup > > I need a similar solution, but with the internal django template > > library. Is there any solution for this requirement? > > > I would like to store little html/template chunks in a database and > > use them in a "normal" django template. I wouldn't use a markup- > > language. The reason is, that I would like to use the template > > functionality (e.g: url tag). > > I don't think you have explained your problem very well. Perhaps a (very > short) example might help you to illustrate what's going wrong. > > You can store whatever you like in the database and use the model fields > in a template directly, so I'm not really sure what you are asking that > goes beyond that. > > Malcolm > > -- > Always try to be modest and be proud of it!http://www.pointy-stick.com/blog/ --~--~-~--~~~---~--~~ 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 PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~--~~~~--~~--~--~---