Re: Views & Template issue

2018-09-12 Thread Mikko Meronen
Thank you, works well now :) ke 12. syysk. 2018 klo 11.37 Andréas Kühne (andreas.ku...@hypercode.se) kirjoitti: > Hi Mikko, > > It works correctly the way you have written it. Look at the code you have > written: > t = time.time() > > def index(request): > newstest = NewsData.objects.filter(c

Re: Views & Template issue

2018-09-12 Thread Andréas Kühne
Hi Mikko, It works correctly the way you have written it. Look at the code you have written: t = time.time() def index(request): newstest = NewsData.objects.filter(created__gt= t - 300).order_by('-created') newstest1 = NewsData.objects.filter(created__lt= t - 300).order_by('-created')

Re: Views & Template issue

2018-09-11 Thread Mikko Meronen
Hi, I still have a small issue here and couldn't figure it out. I want to divide my items based on the time created. The division point is 5 minutes and I want that point to be seen in my webpage. However when I made the division point, Django doesn't update it (the items that become older than 5

Re: Views & Template issue

2018-09-09 Thread Mikko Meronen
Thank you. -Mikko su 9. syysk. 2018 klo 16.49 Jason (jjohns98...@gmail.com) kirjoitti: > You've defined two views which pass in different querysets to be rendered. > > so if you hit index, you get the first queryset rendered but not the > second because newstest1 is not rendered at all. and vic

Re: Views & Template issue

2018-09-09 Thread Jason
You've defined two views which pass in different querysets to be rendered. so if you hit index, you get the first queryset rendered but not the second because newstest1 is not rendered at all. and vice versa. solution is to add newstest1 to index and pass both querysets as context to the rende

Views & Template issue

2018-09-09 Thread Mikko Meronen
Hi again, I'm trying to include two views in one html template, however the latter(bolded) view doesn't work. The first one works well and I can see the items created within last 15 minutes in my webpage. However when I want to see the older items (bolded html part and index1 in views.py), I don'

Re: password_reset email template issue

2012-03-11 Thread Bolang
You need to configure your 'sites'. You can configure it in admin page On 03/12/2012 05:30 AM, Scott Macri wrote: I'm having an issue with my email template for the password_reset view. For some reason I keep getting the following instead of my template text: You're receiving this e-mail becaus

Re: password_reset email template issue

2012-03-11 Thread hack
GOT IT. admin - sites Also, you have to be careful to edit the existing example.com site and not delete it. Deleting it and creating will cause pk to be incremented and accessing the reset page will fail. On Sunday, March 11, 2012 6:30:28 PM UTC-4, hack wrote: > > I'm having an issue with my

password_reset email template issue

2012-03-11 Thread Scott Macri
I'm having an issue with my email template for the password_reset view. For some reason I keep getting the following instead of my template text: You're receiving this e-mail because you requested a password reset for your user account at example.com. Please go to the following page and choose a

Re: Template issue, maybe?

2010-06-07 Thread Tim Walter
This turned out to be an issue in my settings.py, I had to point the media (jss/css/etc) to the correct directory. On 6/4/10, Vectar wrote: > > Hello all, > > New to Django, I have been through all the tutorials and verified > things appeared to be working. I am running a windows server 2003 > li

Re: Template issue, maybe?

2010-06-05 Thread Dmitry Dulepov
Hi! Venkatraman S wrote: > Admin media is not being loaded. Yes, looks like that. In FireFox/Firebug or Safari or Chrome it is possible to use a corresponding web developer console and see what is not loading (Network or Resource tabs). > On Fri, Jun 4, 2010 at 11:59 PM, Vectar

Re: Template issue, maybe?

2010-06-04 Thread Bill Freeman
People are more likely to have ideas if you give us your Apache configuration stanzas, particularly the WSGIScriptAlias and, if used your WSGIDaemonProcess and WSGIProcessGroup directives, any directory stanzas you have for serving the media, admin-media, and any other static content trees. All pr

Re: Template issue, maybe?

2010-06-04 Thread Venkatraman S
Admin media is not being loaded. -V- http://twitter.com/venkasub On Fri, Jun 4, 2010 at 11:59 PM, Vectar wrote: > Hello all, > > New to Django, I have been through all the tutorials and verified > things appeared to be working. I am running a windows server 2003 > license, with Apache 2.1.2 I

Template issue, maybe?

2010-06-04 Thread Vectar
Hello all, New to Django, I have been through all the tutorials and verified things appeared to be working. I am running a windows server 2003 license, with Apache 2.1.2 I think It is 2 something anyhow. I have Python 2.6 installed and I have The latest version available to me of the mod_wsgi int

wierd template issue with perms (django auth)

2010-05-10 Thread zweb
I have {% if perms.core.add_project %} which is expected to be false but it is returning true. I am running it on webfaction (mod_wsgi, python 2.5 , django 1,1,1). I do {{perms.user}} in my html on webfaction and I get - perms: set([u'core.view_project']) which is correct. and {{perms.core.add_

Re: Basic 404.html template issue

2009-09-07 Thread Peter Coles
In your example, when testing the 404 page, you wrote that you're no longer visiting a url under http://localhost:8000, but now you're visiting a url under http://fairware:8000 – was this an error in your post or were you actually checking the wrong server? The testserver will handle 404 pages pr

Re: Basic 404.html template issue

2009-09-06 Thread cootetom
Have you tried this through a proper server? You've stated that your project isn't running in DEBUG but the django development server is still just that and may be causing this issue. I'm not sure but can't see any harm in seeing if you get the same result if you run through apache to see if it wo

Basic 404.html template issue

2009-09-06 Thread moreeon
Hi everyone, I'm struggling with an issue my girlfriend says is "ironic". I can't get my custom 404 page to show. I've broken this down to the simplest possible case. Here's what I did: Create a new project called "experiment" in /home/me/experiment and add a directory to that called templates.

Re: Template issue

2009-05-07 Thread Colin Bean
On Thu, May 7, 2009 at 2:13 AM, 83nini <83n...@gmail.com> wrote: > > Hi guys, > > I have a template.surf which i'm trying to style with CSS external > file, but it's not working! any idea how to deal with .surf templates? > and how to style them with the CSS external files? > internally working, e

Template issue

2009-05-07 Thread 83nini
Hi guys, I have a template.surf which i'm trying to style with CSS external file, but it's not working! any idea how to deal with .surf templates? and how to style them with the CSS external files? internally working, externally...NOT! cheers. --~--~-~--~~~---~--~

Re: XML Rendering. Template issue - sub cats

2008-01-07 Thread Collin Grady
Of course it's listing the same clients, you looked up the full list, instead of, say, using the relations to category to get only those clients which belong to that category :) If a client has an fkey to category, then you need to be doing something like {% for client in category.client_set.all

XML Rendering. Template issue - sub cats

2008-01-06 Thread shocks
Hello I've been using Django for a week. Really liking its flexibility. I'm using it to create a CMS for an ActionScript 3 app. The Flash will read an XML file outputed from Django and maintained through the admin interface. It's all working well but I have a problem structuring the XML output