Hello,
Recieving a common error, but have trolled the message boards, and
have not found a solution. My httpd.conf file contains the following
relevant snippet:
SetHandler python-program
PythonPath "['/home/benrawk'] + sys.path"
SetEnv DJANGO_SETTINGS_MODULE mysite.settings
Pyth
On Wed, 2007-03-21 at 23:36 -0700, [EMAIL PROTECTED] wrote:
> > Hmm... if we do it, this feels like something that should be kept
> > separate from the standard manage.py; I can certainly see it being an
> > immense help to developers who are just starting to work with Django,
> > but I can also s
I've been having problems on CentOS as well. Then again I tried to
upgrade to python 2.4, and the server is 64-bit. I was able to find
some RPMs (check
http://rpm.pbone.net/index.php3/stat/3/srodzaj/1/search/MySQL-python)
-- although with that I had to install some dependencies manually.
Anyhow,
> Hmm... if we do it, this feels like something that should be kept
> separate from the standard manage.py; I can certainly see it being an
> immense help to developers who are just starting to work with Django,
> but I can also see more experienced users saying "I just want a blank
> app, without
limodou wrote:
> You can also use PyIf tag(written by me) to do that.
> http://www.djangosnippets.org/snippets/12/
> And it can support any python expression. So it's more general I think.
And it's short and understandable. I like it too.
Thanks
Mike
--
Michael Lake
--~--~-~--~~
On 3/22/07, Michael Lake <[EMAIL PROTECTED]> wrote:
>
> Kenneth Gonsalves wrote:
>
> > On 22-Mar-07, at 9:25 AM, Michael Lake wrote:
> >>>write your own tag - someone has done it, you can see it in this
> >>>file:
> >>>
> >>>http://nrcfosshelpline.in/code/browser/trunk/web/templatetags/
> >>>base_
Kenneth Gonsalves wrote:
> On 22-Mar-07, at 9:25 AM, Michael Lake wrote:
>>>write your own tag - someone has done it, you can see it in this
>>>file:
>>>
>>>http://nrcfosshelpline.in/code/browser/trunk/web/templatetags/
>>>base_utils.py
>>>
>>>class CompareNode near the end
>>
>>But that link a
On 22-Mar-07, at 9:25 AM, Michael Lake wrote:
>> write your own tag - someone has done it, you can see it in this
>> file:
>>
>> http://nrcfosshelpline.in/code/browser/trunk/web/templatetags/
>> base_utils.py
>>
>> class CompareNode near the end
>
> But that link above no longer works.
works
[EMAIL PROTECTED] wrote:
> Hi Michael,
> Have you added "django.contrib.markup" to your INSTALLED_APPS setting?
Ah :-)
I had placed django.contrib.markup into the MIDDLEWARE_CLASSES instead of the
INSTALLED_APPS section in settings.py.
I have fixed that and it's now saying the markdown library
Hi Michael,
Have you added "django.contrib.markup" to your INSTALLED_APPS setting?
--Simon
--~--~-~--~~~---~--~~
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@go
Hi all
I'm wishing for a "less than" and "greater than" in templates.
The mailing list has this on the matter:
On 31-Aug-06
>> Is it possible to make "less than" and "greater than" comparisons in
>> templates?
>> I was trying to do something similar to this, but without success:
>> {% if list|le
On 3/20/07, dbee <[EMAIL PROTECTED]> wrote:
>
> System: Linux 2.6.9-34.0.1.EL #1 Wed May 24 07:40:56 CDT 2006 i686
> athlon i386 GNU/Linux
> OS: CentOS
> Python: 2.3.4
> Mysql: 5.0
>
> I'm having lots of issues trying to get my django server up. It seems
> that mod_python won't work on my system.
On 3/21/07, ZebZiggle <[EMAIL PROTECTED]> wrote:
> I'm going to have to deal with this, so here's what I'm thinking: some
> sort of helper function that will do a filter() but act as a .get() in
> that it only returns 1, but in the event more than 1 comes back notify
> the admin that the integrity
On 3/21/07, Tom Smith <[EMAIL PROTECTED]> wrote:
> This is my very crude attempt, which first calls startapp, then does
> standard stuff that ALWAYS seem to have to do and ALWAYS forget like:
> Add a urls.py for my app...
> Add a URL pattern to load static images
> Create the folder to host the
Hey all!
I run into a problem related to this discussion.
Somehow, someway, I'm getting multiple entries in my data model where
I should only ever have one.
I suspect it's related to the users hitting the back button or double-
clicking a submit button (or something). But it baffles me how it's
Ashwoods, I did also some other business-related modifications so it
would take me some time to prepare that just for a snippet. That
middleware is not worth making it a snippet. I would better suggest
you to use the solution by Derek.
Regards,
Aidas Bendoraitis [aka Archatas]
On 3/21/07, ashw
Hi all
I'm doing something wrong, probably simple too, in trying to get the
contrib.markup
running.
I have in settings.py 'django.contrib.markup'
In a template I have {% load markup %}
I thought the above was all I need.
When the URL is accessed I get a traceback like this:
Traceback (most r
On Wed, 2007-03-21 at 16:47 -0700, Gerard M wrote:
> Hello django community, I have a HUGE problem, and I would like to
> know if some of you guys can help me, the problem is: Im accesing a
> database and there is a big chance of not finding the item im looking
> for, this is the snipplet of code
I am writing an app that makes heavy use of generic views. I have
several forms which include date fields and I want to know how to
attach a widget to the field for entering the date (like the one used
in the admin site).
Am I making sense?
--~--~-~--~~~---~--~~
On Wed, Mar 21, 2007 at 04:47:35PM -0700, Gerard M wrote:
>
> Hello django community, I have a HUGE problem, and I would like to
> know if some of you guys can help me, the problem is: Im accesing a
> database and there is a big chance of not finding the item im looking
> for, this is the snipplet
On Wed, 2007-03-21 at 16:47 -0700, Gerard M wrote:
> Hello django community, I have a HUGE problem, and I would like to
> know if some of you guys can help me, the problem is: Im accesing a
> database and there is a big chance of not finding the item im looking
> for, this is the snipplet of code
Hello django community, I have a HUGE problem, and I would like to
know if some of you guys can help me, the problem is: Im accesing a
database and there is a big chance of not finding the item im looking
for, this is the snipplet of code im using and the "solution" that
I've implemented but it do
On Wed, 21 Mar 2007 18:19:21 -0400, Dan Goldner <[EMAIL PROTECTED]>
wrote:
[snip]
>
> httpd.conf:
>
>
> ServerName projects.mycompany.com
> SetHandler python-program
> PythonInterpPerDirective On
>
> # Turn Off for production, On for dev:
> PythonAutoReload On
> PythonDebug On
>
>
Anyone know of the recommended way to set up user-specific content,
where each user (except the admin) would see only his content,
regardless of the view being used to access it? Assume that content
is associated with users via the threadlocals method (http://
code.djangoproject.com/wiki/CookBook
On Tue, Mar 20, 2007 at 10:18:19PM -0500, Jeremy Dunck wrote:
> How long's the pres? You might just pick some high points and make a
> slide at the end with small font and loads of links to all the other
> stuff you didn't have time form. ;-)
>
I've got an hour and a half. I was planning to onl
Hello,
As noted previously I'm serving two independent, low-traffic django
projects off a single virtual host in order to use SSL without a
single certificate. Since I want static files to be SSL'd as well,
these are served from the same virtual host. This seems to be working,
with one mysterio
Another option for search is to use the google co-op thing- look in
your google services. If your site is public, then it could be all
you need.
I've used it on 2 sites and they're non-commercial so I can switch off
the ads. It took some time for google's indexing to settle down, but
it seems t
On Wed, 2007-03-21 at 15:19 -0700, Dan Goldner wrote:
> Hello,
>
> As noted previously I'm serving two independent, low-traffic django
> projects off a single virtual host in order to use SSL without a
> single certificate. Since I want static files to be SSL'd as well,
> these are served from
Mary,
On 3/21/07, Mary <[EMAIL PROTECTED]> wrote:
>
> I am using 0.95.1 the latest stable version for Django
> --MA
You have to be using the development version of django and not the
0.95.1 release as the fix in changeset [3490] wasn't backported to
0.95.1.
[3490] http://code.djangoproject.com/
On Mar 5, 10:44 am, "Aidas Bendoraitis" <[EMAIL PROTECTED]>
wrote:
...
> 2. installing a BIND (DNS) server locally so that we didn't have to
> put projects under specific directories, but rather under local domain
> names (i.e.http://example.local/).
I just use the hosts file on my development
Matt,
For 'temporary' state which does not need to live beyond an
interactive session with a website, I prefer to use a custom cookie
with an expiration of 12 hours or less.
Many times if it is just a CSS mark of some sort, I will just use 100%
javascript to get the job done, as it means I can ev
Thanks.
The problem is that I then have to record this for each person, and
for each question
if I can find a lightweight way of doing this (in terms of my LOC, as
well as server activity) that would be better.
I thought that perhaps a cookie, which got deleted at the end of the
session woul
On 3/21/07, worksology <[EMAIL PROTECTED]> wrote:
>
> I have the exact same issue, also with Dreamhost. I tried the
> "mysql_old" thing, but still got the same error.
Malcolm has just checked in a fix.
this has saved My_old backend :)
Derek
--~--~-~--~~~---~--~--
I'm guessing that the import statement in mysql_old/introspection.py
should read:
from django.db.backends.mysql_old.base import quote_name
rather than:
from django.db.backends.mysql.base import quote_name
That seems to have worked for me, but probably should be fixed in the
source, eh?
- Josh
I have the exact same issue, also with Dreamhost. I tried the
"mysql_old" thing, but still got the same error. Here's the relevant
part of the stack trace:
File "/django_src/django/db/backends/mysql_old/introspection.py",
line 1, in ?
from django.db.backends.mysql.base import quote_name
I'd love it if someone made an intelligent startapp call for manage.py. At the moment, it looks like Rails... but doesn't DO an awful lot This is my very crude attempt, which first calls startapp, then does standard stuff that ALWAYS seem to have to do and ALWAYS forget like: Add a urls.py for
On Wed, Mar 21, Adam wrote:
>
> This causes a problem with DreamHost...I know they're not the best in
> the world, but I get this error now on any sites on their servers.
> Does anyone have a decent solution to get around this? Can I install
> a local copy somehow and make django use it instead
There is nothing special about that app. The login which is failing is
the standard django one (The app just adds code for new account
creation, e-mailing the registerant, and enabling the account with a
unique key).
I believe the problem you are running into is because the page is
stale. That is
On 3/21/07, Nathan Harmston <[EMAIL PROTECTED]> wrote:
...
> The view could return results if the result was retrieved
> within a specific time period, else it would return a "work in progress".
> Would this kind of thing work? So the "WS client process" and Django both
> share the same models and
This causes a problem with DreamHost...I know they're not the best in
the world, but I get this error now on any sites on their servers.
Does anyone have a decent solution to get around this? Can I install
a local copy somehow and make django use it instead of their version?
Has anyone had luck g
could you post the code on django snippets? :)
On Mar 20, 11:35 pm, "Aidas Bendoraitis" <[EMAIL PROTECTED]>
wrote:
> > have you found any solution?
>
> Yes. I wrote my own FlatPage model with it's own middleware. Now the
> URL can be empty and it represents the relative path counting from the
> w
have you tried contacting the project maintainer? this is third party
code and unless anybody happens to use it, to answer you they would
have to go through his code. on the wiki page it says:
>Questions? Problems?
>If you've got a question that isn't covered here or in the comments and
>docstr
is there any reason you want to process the "webservices" on the
server side? unless there is any special reason to do this, it looks
like kind of redundant and actually that is one of the main reasons to
use webservices (decentralized application model). that means you
would want to spit out clie
hello,
unless i misunderstood the question, you need to maintain some state
across multiple requests. if so, this is what the database is for. :-)
make a model that has your "marked" flag.
konstantin
On Mar 21, 11:36 am, "MattW" <[EMAIL PROTECTED]> wrote:
> Dear All,
>
> More of a design questi
this helped. thanks. i was not importing the default handler.
konstantin
>
> Make sure the module referred to by ROOT_URLCONF has defined 'handler404'.
>
> This is typically provided via
> "
> from django.conf.urls.defaults import *
> " in the URLConf because urls.defaults.py includes this:
> ha
Dear All,
More of a design question than a technical query...
I've got a page with multiple 'areas' - some static text, a wiki bit
and a 'marking' bit (via a form). I'd like to be able to only allow
people to enter a mark once, after which views of the page should say
"Thanks for the feedback".
Filters are unbelievably helpful when you have different people doing
markup and development.
The 'pluralize' filter, for example (as well as the 'humanize'
collection), has saved us developers from having to write templae-side
code to figure out if there should be an 's' at the end of a noun.
Th
On 3/21/07, akonsu <[EMAIL PROTECTED]> wrote:
> thanks for your reply. the error that i am getting seems to indicate
> that it is not 404.html that is the problem. it cannot find the
> handler itself, not the template. and i do have this template, but it
> does not help :-)
I assume you're using
On 3/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Looking at my logs, I saw a gazillion requests from 81.208.31.216,
> which I believe is a malicious bot. I understand there's a way to use
> middleware to block IPs, but could somebody elaborate on that, or
> point me in the right directio
Scott,
thanks for your reply. the error that i am getting seems to indicate
that it is not 404.html that is the problem. it cannot find the
handler itself, not the template. and i do have this template, but it
does not help :-)
konstantin
On Mar 21, 6:46 am, "ScottB" <[EMAIL PROTECTED]> wrote:
"[EMAIL PROTECTED]" <[EMAIL PROTECTED]> writes:
> middleware to block IPs, but could somebody elaborate on that, or
> point me in the right direction? Thanks!
Better use your local firewall or the webserver in front of Django.
Why let an (comparable expensive) application deal with this?
Regard
On Wed, Mar 21, [EMAIL PROTECTED] wrote:
>
> Looking at my logs, I saw a gazillion requests from 81.208.31.216,
> which I believe is a malicious bot. I understand there's a way to use
> middleware to block IPs, but could somebody elaborate on that, or
> point me in the right direction? Thanks!
Check the request.META['REMOTE_ADDR'] in your custom request
middleware. If it equals to the one, you want to block, return an
error page.
Regards,
Aidas Bendoraitis [aka Archatas]
On 3/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Looking at my logs, I saw a gazillion requests from
Looking at my logs, I saw a gazillion requests from 81.208.31.216,
which I believe is a malicious bot. I understand there's a way to use
middleware to block IPs, but could somebody elaborate on that, or
point me in the right direction? Thanks!
--~--~-~--~~~---~--~
When I say Web Services, I am including SOAP aswell as REST. So my django
project actually becomes a portal to various web services hosted by external
entities. So is the best way to do it, to have a job model which holds the
various job data and have a process running which runs the web service an
Hi Simon,
Thanks for your response!
I was more thinking of exceptions raised when something is terribly
wrong like mysql being down when you try to do a :
Models.objects.all()
or maybe also if you try to fetch data filtering with a filter with a
wrong data type. ... basically every excepti
Hi Seb :)
There's no list of exceptions in the docs, but if other people think
it's a good idea, I'll add it as a feature request.
Anyway, Models.objects.all() will return an empty list ([]) if there's
nothing in the database. Something like
Model.objects.get(pk=somevalue) will raise a Models.Do
Hi!
I've recently implemented http://code.google.com/p/django-registration/
to support user registration and authentication on a project.
I've also created a form in a template that extends ALL other
templates on the site.
I'm facing the following problem:
If I fire the django development serv
Hi All,
This is my very first POST. I am looking @ django for a quick project
i have to set up; and so far i must admit i am quite amazed on how
quickly things can be done.
One thing bugs me though i could not find anywhere how to handle
errors : what are the exceptions thrown by django for insta
> Testing is a must have for long term support. Templatetags are great too.
>
I second this. You might want to include the newly introduced support
for Fixtures (XML, JSON, Python and YAML).
Regards,
Manoj
--~--~-~--~~~---~--~~
You received this message because
Hi konstantin.
On Mar 21, 2:38 am, "akonsu" <[EMAIL PROTECTED]> wrote:
> i have no handler404 defined in my application, so when a 404 is
> raised the server returns internal server error and an error message
> saying 'module' object has no attribute 'handler404' is written in to
> the log. how t
Hi Nathan.
On Mar 21, 12:37 am, "Nathan Harmston" <[EMAIL PROTECTED]>
wrote:
> My Project is called pynomics and the app alignments.
> ~/pynomics/alignments/models.py
>
> so in my "Parser.py", I try to import the models file
> from pynomics.alignments.models import *
>
> but I get the following e
Hi Jim.
On Mar 19, 8:41 pm, "JimR" <[EMAIL PROTECTED]> wrote:
> how do I retrieve/store the correct key/id for the
> attribute information? I generate a drop-down with the valid
> selections "home," "mobile," etc.) and then want to store it's
> associated id
...
> FORM:
> class RegistrationForm(f
On Mar 19, 6:00 pm, "tyman26" <[EMAIL PROTECTED]> wrote:
> Where do I set the 'SESSION_EXPIRE_AT_BROWSER_CLOSE = True'? I added
> this to the "settings" file and sync'd the database, but when I close
> the browser the session still stays intact. Do I have to add this
> when the session is create
2007/3/21, Scott Paul Robertson <[EMAIL PROTECTED]>:
> I'm giving a presentation on Django to two local Linux Users Groups in
> the next month. I don't want to rehash the tutorial; I'd rather spend
> time showing off why Django is cool and how to do interesting things
> with it. Currently I want t
I was using the same shell. I also tried shutting down the server,
rebooting the machine and opening everything up again to see if that
would make any difference but it did not.
However, then a few hours later - it started to work again. I still
don't fully understand the reason. I can only
66 matches
Mail list logo