Basically, I have a colon delimited variable being passed into my template that I would like to loop through to display each individual element.
I would like to be able to extract each of these names and then perform logic on them within my template.
If I could use python, I would do something like (note: file_type is the variable I h...
Hi,
I want to fill a table with a list of results. But not sure how to tell the template that it's time to close current and start a new one, after 3 products was already displayed in current tr....
Would be happy if somebody could advice on it. I am running django 1.1.1
...
Hey, I want to add custom buttom to the django admin site, and the users must be administrators, I do not expect you tell me how to do in each step, but please brief write the right approach, if you also can provide some reading URLs, that's gonna be awesome.
...
Hello, I seem to have a problem displaying work orders. in my app. The clients does not have the same problem so why does the work orders not show up. Actually it is as almost as a black space appears rather than text that should appear from my database.
The problem seems to be because work orders have a many-to-many field. If I have {{...
hi, I've already configured the necessary things to work the extends template function in django. here's my codes:
in settings.py
def my_dir():
import os.path
return os.path.abspath(os.path.dirname(__file__))
TEMPLATE_DIRS = ( my_dir() + '/app/templates', ) #dynamic template directory
in base.html - located in app/templates/s...
Hello All,
I started to code in Django quite recently, so maybe my question is a bit wierd.
Recently I needed to render the CharField fields from the model into simple static text in html , but I figured out that it seems it's not that simple in this case as I could think, or I am doing something wrong...
I have this model:
class Tag(...
I am writing a template for my first django website.
I am passing a list of dictionaries to the template in a variable. I also need to pass a few other lists which hold boolean flags. (Note: all lists have the same length)
The template looks something like this:
<html>
<head><title>First page</title></head><body>
{% for it...
I'm running Python 2.6.1 and Django 1.2.1 on Windows XP SP3. I'm using JetBrains PyCharm 1.0 to create and deploy my Django apps.
I'm relatively inexperienced with Python, and I'm starting to learn Django by following along with "Writing Your First Django App" from the web site - the poll application. I'm stuck on part 3.
Everything ...