Readed all these topic http://stackoverflow.com/search?q=django.views.static.serve
And it not helped :(
OS: Windows XP
Python: 2.7
Django: 1.2.3
Media in
D:\bugtracker\static
With files:
docicons-note.gif
style.css
In settings.py i set:
MEDIA_ROOT = 'D:/bugtracker/static/'
MEDIA_URL = '/static/'
In urls.py i set:
urlpatterns = pa...
Hi,
I've written a custom admin filter, now I'm looking for tests of the builtin filterspecs...where can I find those? A
jmoritz@laptop:~/workspace/django/django$ grep -ir testcase . | grep -ir admin
returned only the admindocs tests...
...
Hi folks,
I can't seem to find how to generate the classic Facebook Connect button:
all I can find how to generate is the following:
I'm using the documentation here http://developers.facebook.com/docs/guides/web
Any ideas? :)
...
I have finally got my admin part of my django site working.
I am now beginning the tedious part of manually entering the initial data into the database. Obviously, I want this to be a one time affair.
Can anyone suggest to me how I can create fixtures data from my manually entered data, so that I can reload the data (automatically?) wh...
Hello, I have set up TinyMCE to work with the Admin panel (as per the instructions in the Django Docs http://code.djangoproject.com/wiki/AddWYSIWYGEditor )
The problem is that I have Inlines and other text areas within my model for which I don't want TinyMCE to render
Does anyone know how to set TinyMCE to only load for particular fiel...
Hi folks,
I'm building a web app with Django using Facebook authentication.
Now I have encountered a problem with the logout.
Do developers usually hide the default logout link?
It is quite tricky coming up with the logic of implementing a logout while a user is connected to a facebook acount, which is still logged in.
Any ideas?...
I'm trying to upload files for an article model. Since an object can have multiple images, I'm using a foreign-key from file model to my article model. However, I want all the files to have unique titles. Herez the code snippet.
class Article(models.Model):
name = models.CharField(max_length=64)
class Files(models.Model):
titl...
Hi all,
I want to add a custom button near 'Add model_name'. When i click on the newly created button i should like to show a custom form where I cans elect a model out of a select box. When i click on save I want to save this model and chance some parameters so it's a 'add' but without selecting all options again. I give a clear exampl...
I have a Django project which uses django-tagging and is supposed to run in German. So I looked into the sources and found that django-tagging does indeed use gettext_lazy and is thus completely translatable. However, there are no translations available in the package. So I assume there must be a way for me to translate it from within my...
Hello,
I have a table with a few thousands records (products). Each product has a 4 different categories:
CAT1 CAT2 CAT3 CAT4
I wonder if is there a method, or what is the best practice, to dynamically retrive the available categories based on the categories already selected (using Ajax).
Example:
if CAT1 = green all the products wit...
My site has two types of users; customers and suppliers. I have ended up with the following class structure:
class Customer(models.Model):
# stuff specific to customers
class Supplier(models.Model):
# stuff specific to suppliers
class Profile(models.Model): # returned by Django's User.get_profile()
user = models.ForeignKe...
i want to populate django_site table when i run after syncdb initially
how can i do that
i have one site only
...
Some how some way I'm trying to get out of Ruby because things are just working and I don't necessarily know why. I'm taking the forest for the trees approach by which I mean I'm trying to get perspective by learning a new language; Python/Django seems to be the right way to go.
The first application I built in Rails was from the 5 min ...
If a model's field is a choice or foreign key, the widget on the page is a select input or radios if you specify that. Django places "---------" in the first item as an unselected value. How can I override it or even remove it? I remember reading the way to do it but can't find it any more.
...
I have a django web application that's running on apache 2.2.14 and I want to run the admin application over https.
Having read considerable discussions on using a proxy, writing middleware, running alternative wsgi scripts, the chaps in #httpd came to my rescue. The solution is so simple, I was surprised I didn't find it online, so ...
I want incorporate a timed based reminder email of the events for the day in django. Basically I have a model which has all the events (including the date of the event). I want to send emails to concerned people at around 8.00 AM in the morning of each day about the events for the day. How do I incorporate this is django?
Thanks
...
For a number of reasons^, I'd like to use a UUID as a primary key in some of my Django models. If I do so, will I still be able to use outside apps like "contrib.comments", "django-voting" or "django-tagging" which use generic relations via ContentType?
Using "django-voting" as an example, the Vote model looks like this:
class Vote(mod...
I have a GenericForeignKey in an inline on an admin page. Being a GenericFK there are 2 fields involved in it: The ContentType FK and the object_id integer field. The GenericFK can, of course, point to a variety of models and objects, some that have image fields and some that don't. My goal is to customize one of the widgets (it can be e...
Using the following related models (one blog entry can have multiple revisions):
class BlogEntryRevision(models.Model):
revisionNumber = models.IntegerField()
title = models.CharField(max_length = 120)
text = models.TextField()
[...]
class BlogEntry(models.Model):
revisions = models.ManyToManyField(BlogEntryRevision...
Something like
my_model.data_dict['my_field']
Which would give you the current value for that field? Need something like that to interface with my other code.
...