What database is it? What are the database and database tables/columns
locales? You should give some more details so we can help. As a general idea,
check my questions above, and make suer the locale is unicode/utf-8.
--- Amit
ביום שישי 21 ספטמבר 2007, 19:07, נכתב על ידי drackett:
>
> I am tr
You can change your template, eg. in change_list_results.html I did
something like this:
{% for result in results %}
{% for item in result %}{% ifequal
item "(None)" %}{% else %}{{ item }}{% endifequal %}
{% endfor %}
{% endfor %}
--~--~-~--~~~---~--~~
You rece
hi greg -
you're looking for this:
http://www.djangoproject.com/documentation/generic_views/#django-views-generic-simple-direct-to-template
best
jake
Greg wrote:
> Ok,
> Very easy question here. Is there anyway that I can directly call
> my .htm file from within my urls.py file?
>
> Now, I ha
Ok,
Very easy question here. Is there anyway that I can directly call
my .htm file from within my urls.py file?
Now, I have the following:
(r'^customer_care/$', 'mysite.rugs.views.customer_care'),
def customer_care(request):
return render_to_response('customer_care.html', {})
Ok, if you are like me you have heard so much about the FreeIpods and
FreeFlatScreens websites on different forums, blogs, IM's, etc, you
are about to puke. So am I. But yet the draw of getting an Ipod for
doing basically nothing is pretty strong. I dismissed all the
"stories" of people getting
Thanks a lot for the explanation. Now it is much clearer for me...
On 21 Eylül, 19:18, "Jeremy Dunck" <[EMAIL PROTECTED]> wrote:
> On 9/21/07, omat <[EMAIL PROTECTED]> wrote:
> This:
>
> > class TagManager(models.Manager)
> > # ...
> > def get_query_set(self):
> > return TagQuer
Hi everyone, Im new here.
I needed to write a query similar to
News.objects.filter(publish_date__hour = 12)
and found out that some query terms (namely hour,minute and second)
are not supported by filter but are supported by all database
backends. (unless im terribly wrong, just looked at the c
JOIN THE HOTTEST GROUP ON THE NET OVER 10,000 JOIN WEEKLY FREE
SIGN UP!
http://www.blpurl.com/al42
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
Greetings,
I would like to reference a model in another database. I see that the
TODO list on MultipleDatabaseSupport in the code wiki has the
following:
When validating models, warn user if a model references
another model that is configured to use a different connection DONE
I started t
I don't see how it would break on your production server as long as
you have a trailing slash in the server's media_url too.
On Sep 21, 5:05 pm, Dave Lowe <[EMAIL PROTECTED]> wrote:
> I agree by the way, MEDIA_URL should always have a trailing slash.
> Does anyone know why the documentation says
Hi Jacob,
On Sep 22, 3:51 am, jacoberg2 <[EMAIL PROTECTED]> wrote:
> Hey quick question, what exactly is the media_url setting and what do
> you have to do to get the right url?
>From http://www.djangoproject.com/documentation/settings/#media-url:
MEDIA_URL
Default: '' (Empty string)
URL that
Hi, I'm running currently django from svn version 6399 on FC7 with
postgresql. With every request I'm getting this error (it's happening
for the last few svn updates):
Traceback (most recent call last):
File
"/usr/lib/python2.5/site-packages/django/core/servers/basehttp.py", line
279, in run
Hi Linan,
On Sep 22, 3:38 am, Linan <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I just wrote a decorator to validate if an object(say Blog) exists:
>
> def require_blog_item_exists(func):
> def _decorated_func(request, blog_id, *args, **kwargs):
> try:
> blog = Blog.objects.g
Learn how to repair, speed up and tweak your Windows XP
http://windowsxpsp2pro.blogspot.com/
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@goog
I tried using the file upload methods like using a filefield in a
model, and i got it to work on a test program but i can't sem to get
it to work on my real site and I get a few different errors when it
comes up. this is my code:
class BulkDataRegFile(models.Model):
user = models.ForeignK
You don't need view for you flatpages. View is provided by the
fratpages application.
On Sep 21, 6:30 am, AniNair <[EMAIL PROTECTED]> wrote:
> Hi...
> Can someone help me with flat pages? I tried exactly what they say
> in the pagehttp://www.djangoproject.com/documentation/flatpages/
> I get
Thanks! I added your suggestions in the following way since i am
running on windows
Alias /media/ "C:\Python25\Lib\site-packages\django\contrib\admin\media
\"
Order deny,allow
Allow from all
Am i slashing wrong?
On Sep 21, 4:57 pm, Kenneth Gonsalves <[EMAIL PROTECTED]> wrote
After more research, I've found out that the problem existed because
of the bug reported in the ticket #2438.
http://code.djangoproject.com/ticket/2438
That is, under certain circumstances, not all the modules where
registered in the application cache.
To solve the problem, I had to eliminate all
I tried to clear sessions but it didn't help.
I used:
#!binsh
# clear django_session table
DJANGO_SETTINGS_MODULE=Intranet.settings
python -c 'from django.contrib.sessions.models import Session;
Session.objects.all().delete()'
On Sep 20, 3:07 pm, beck917 <[EMAIL PROTECTED]> wrote:
> Ther
Hi...
Can someone help me with flat pages? I tried exactly what they say
in the page http://www.djangoproject.com/documentation/flatpages/
I get the html template to render but the contents are missing. Plz
advice. Thank you
my template code is
{{ flatpage.title }}
Privacy
{{ flatpage.conte
Hi all,
I just wrote a decorator to validate if an object(say Blog) exists:
def require_blog_item_exists(func):
def _decorated_func(request, blog_id, *args, **kwargs):
try:
blog = Blog.objects.get(id = blog_id)
return func(request, blog_id, *args, **kwargs)
I am trying to parse a last.fm xml file to get the artists, tracks,
etc. into a django database. I am having an issue where foreign
characters (Japanese, etc.) are being stored in the database as
"?" and not the correct values. I feel like I've tried everything,
and am getting pretty frustrate
Yes, same behaviour here
On 9/21/07, Joseph Kocherhans <[EMAIL PROTECTED]> wrote:
>
> On 9/21/07, A. Reppel <[EMAIL PROTECTED]> wrote:
> >
> > I'm using newforms-admin, and i've put into the model option class a
> > function:
> >
> > def has_add_permission(self,req): return False
> >
> > but I s
On 9/21/07, A. Reppel <[EMAIL PROTECTED]> wrote:
>
> I'm using newforms-admin, and i've put into the model option class a function:
>
> def has_add_permission(self,req): return False
>
> but I still see the "add' button in the admin index page and in other places.
>
> Are these options actually wo
On 9/21/07, omat <[EMAIL PROTECTED]> wrote:
This:
> class TagManager(models.Manager)
> # ...
> def get_query_set(self):
> return TagQuerySet
Should be this:
def get_query_set(self):
return TagQuerySet(Tag)
And you'll obviously need to implement "my_filter" on Tag
Optimize your operating system http://windowsxpsp2pro.blogspot.com
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscri
Ok, I solved the recursive import problem and tried to improve my
understanding of what is going on.
Now I have:
class TagManager(models.Manager):
def get_query_set(self):
return TagQuerySet
class Tag(models.Model):
# ...
objects = TagManager()
class TagQuerySet(models.quer
On 9/21/07, patrickk <[EMAIL PROTECTED]> wrote:
> when I do "svn update" within the django_src directory, I´m getting
> this error:
> svn: PROPFIND request failed on '/'
> svn: PROPFIND of '/': 200 OK (http://code.djangoproject.com)
It's working fine for me. Double-check that things are working o
On Sep 20, 7:39 pm, "Ben Ford" <[EMAIL PROTECTED]> wrote:
> It would be a good time wouldn't it?! ;-)
>
> Sorry I didn't add my 2c worth yesterday, I was extremely busy and will
> remain so for the next week or 2. I've sent a message to the list regarding
> the latest patch to the branch and also
On 9/20/07, Arnold Chen <[EMAIL PROTECTED]> wrote:
> I don't know why the developers change like that, and if there any one
> can, please tell me the consequences of using GET (by modifying the
> set_language function by myself)
The HTTP specification says that GET requests should not take any
ac
I'm using newforms-admin, and i've put into the model option class a function:
def has_add_permission(self,req): return False
but I still see the "add' button in the admin index page and in other places.
Are these options actually working?
--~--~-~--~~~---~--~~
I had more or less the same situation to solve and I think
http://www.djangosnippets.org/snippets/371/ should come quite close
:-)
2007/9/21, erik <[EMAIL PROTECTED]>:
>
>
> Me, too, I stumbled over this change lately.
>
> My understanding of the HTTP spec is that there shouldn't be
> different c
I tried the following in my httpd.conf and it still is not serving any
admin media
SetHandler python-program
PythonHandler django.core.handlers.modpython
SetEnv DJANGO_SETTINGS_MODULE satchmo.settings
PythonDebug On
Alias /media/ "C:/Python25/Lib/site-packages/django/contrib/ad
Hi group,
I would like to ask you for a feedback about this small piece of code
which I make for testing this behaviour. Put the function
test_ifequal() as a view into your app, mount it as a URL and see the
page and then click the button.
The problem I see in this code is - when I access this pa
Me, too, I stumbled over this change lately.
My understanding of the HTTP spec is that there shouldn't be
different content for a given URL without having to use a POST
request. The solution for our problem (having links to switch
languages) might be to use unique URLs for each translation
Hi Amit,
thanks for your reply. This is how I do it now, but it requires to
assign all choices from model definitions to template. I would like to
have this list automatically assigned in the object. I don't know how
it should work, my idea is
{% for choice in item.get_status_choices %}
{{ choic
Assuming your choices type is defined as:
LANGUAGES = (
('he', 'Hebrew'),
('en', 'English'),
)
You have to pass it through the context, and then you can access the list as
follows:
{% for lang in LANGUAGES %}
{{ lang.0 }} {{ lang.1 }}
{% endfor %}
Hope this helps,
--- Amit
ב
Hi group,
I have read the documentation, searched this mailing list and still
don't have the answer for my question.
Is there a way how to access choices in a template? I know there's a
function get_foo_display() [1] but it displays only one value, not the
choice list.
Does anybody have any advi
How do i show empty ForeignKey relation as a empty string instead of
"(None)" ? I think it is more readable. (newforms-admin r6399)
Sorry for the flood...
Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Djang
Google ate my previous post, so I'm re-posting...
I solved the recursive import problem and tried to improve my
understanding of what is going on.
Now I have:
class TagManager(models.Manager):
def get_query_set(self):
return TagQuerySet
class Tag(models.Model):
# ...
object
Hi,
Is it possible to show in an object edit page some informative fields
(I mean, fields you cannot modify)
Thanks
P.S.: using newforms-admin r6399
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" gro
Hi,
I'm using newforms-admin r6399 and don't understand how sorting by
ForeignKey works in the admin site.
consider this:
class Box(models.Model):
serial = models.CharField(max_length=25, primary_key=True)
group = models.ForeignKey(Group)
force_fw = models.ForeignKey(release.Firmware
> Obviously the Django field types provide more semantics than the basic
> database datatypes. Thus I assume that whenever there is a new type of
> field which does not fit in the given categories, it is a good idea to
> define such a new datatype. Correct?
most likely.
> Example: I would like t
On 21-Sep-07, at 5:13 PM, Anurag wrote:
> However my admin interface is all garbled up and what i did was i
> copied the media directory from /admin/media into the htdocs of my
> Apache setup. But i am still unable to see the admin interface
> correctly.
coming from php? Never put anything in
hello,
i am a new user of django and would like some simple worded
instructions on how to serve
the admin interface with Apache and mod_python.
With my current set up i have the following in my httpd.conf:
SetHandler python-program
PythonHandler django.core.handlers.mod
Dear Django Users,
I have a newbie queston about extending Djangos Field Types.
Obviously the Django field types provide more semantics than the basic
database datatypes. Thus I assume that whenever there is a new type of
field which does not fit in the given categories, it is a good idea to
def
Earn upto $5000
IF YOU WANT NON-STOP INCOME
NOTE: THIS MESSAGE IS SENT TO INTERESTED MEMBERS OTHERS PLEASE IGNORE
For more details please log on to
http://www.ezinfocenter.com/9844946/CB
Instead of 9844946 you can use your Own ID
PLEASE COMPLETE THE FOUR STEPS TO STEP UP YOUR FUTURE
(ONLY O
we have some sites with older versions of django which I´d like to
update:
when I do "svn update" within the django_src directory, I´m getting
this error:
svn: PROPFIND request failed on '/'
svn: PROPFIND of '/': 200 OK (http://code.djangoproject.com)
svn info gives me this:
Path: .
URL: http://
Hi,
I have a custom manager for a Tag model and I want to apply its
methods also to Tag querysets, not just to "Tag.objects".
There has been a discussion on this here:
http://groups.google.com/group/django-users/browse_thread/thread/3d00660409d277da/
but what Malcolm suggested is not very clear
49 matches
Mail list logo