ascript }}{{ block footer_javascript_site
}}{{ endblock
footer_javascript_site }}{{ block footer_javascript_section
}}{{ endblock
footer_javascript_section }}{{ block footer_javascript_page }}{{
endblock
footer_javascript_page }}
{{ endblock footer
k dtd }}
>
> the properly syntax (for last Django version) would be:
>
> {% block dtd %} ... {% endblock %}
>
> Notice you should not include 'dtd' in the endblock tag.
>
> -f
>
>
>
>
>
>
> On Apr 27, 3:51 pm, Jonathan Hayward
> wrote:
&g
It gives a "file not found" error, either this way or if I add a trailing
slash.
How can I serve up static content from /media/* to a URL of
/media/* from the development server?
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, lite
'^%s(?P.*)$' % (settings.MEDIA_URL[1:],), 'serve', {
> 'document_root':
> settings.MEDIA_ROOT,
> 'show_indexes': True }),)
>
>
> To answer your question, you should
> use os.path.abspath(o
s for accessing it with the
> user that runs the dev server.
>
> Regards,
> Xavier.
>
> Le 28 avr. 2010 à 01:00, Jonathan Hayward a écrit :
>
> Thank you!
>
> Right now, I have, in settings.py:
>
> MEDIA_ROOT = os.path.join(os.path.abspath(os.path.dirname(__file__
> Use this FILE_UPLOAD_PERMISSIONS = 0600
> and you have to give permissions to apache to read the file upload
> directory.
>
>
>
>
> Jonathan Hayward wrote:
>
>> The file permissions are right AFAIK; the directory is mode 755 and the
>> file 644, owned by the user running
I found the problem; I was trying to serve static (non-admin) media from a
'media/', and that was apparently being overridden by admin media use of the
same URL.
On Tue, Apr 27, 2010 at 7:53 PM, Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> Thank you; right
th, or use TEXT
instead of VARCHAR so that a field of indefinite length is accommodated,
resources permitting?)
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, literature, et cetera.
→ My award-winning collection is available for free reading o
Thanks!
On Wed, May 26, 2010 at 5:32 AM, Daniel Roseman wrote:
> On May 25, 10:49 pm, Jonathan Hayward
> wrote:
> > For CharField, EmailField, URLField, etc., is VARCHAR implementation
> > (meaning a fixed limit on length) absolutely non-negotiable, or there a
> way
> &g
Alex
>
> On May 26, 8:24 am, Jonathan Hayward
> wrote:
> > Thanks!
> >
> > On Wed, May 26, 2010 at 5:32 AM, Daniel Roseman >wrote:
> >
> >
> >
> > > On May 25, 10:49 pm, Jonathan Hayward
> > > wrote:
> > > > For CharF
d run into errors with the first. Does this mean that I should go with the
second, or is there another way that is preferred?
I'm using 1.2.
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, literature, et cetera.
→ My award-winning col
Thanks, Dan and Daniel.
On Tue, Jun 22, 2010 at 3:45 PM, Daniel Roseman wrote:
> On Jun 22, 9:11 pm, Jonathan Hayward
> wrote:
> > What is the preferred way to make e.g. a TextField that will pass
> validation
> > if it is left empty? I've seen two approaches appa
hon2.6/lib-dynload', '/usr/lib/python2.6/dist-packages',
'/usr/lib/python2.6/dist-packages/PIL',
'/usr/lib/python2.6/dist-packages/gst-0.10', '/usr/lib/pymodules/python2.6',
'/usr/lib/python2.6/dist-packages/gtk-2.0',
'/usr/lib/pymodules/
es/python2.6/gtk-2.0',
'/usr/local/lib/python2.6/dist-packages']Server time:Fri, 25 Jun 2010
14:56:26 -0500
I have an Entity class/model defined in my models.py and want to manually
create some dummy data in the table. Any suggestions?
--
→ Jonathan Hayward, christos.jonathan.ha
10 at 3:00 PM, Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I received the error below from the admin interface; I thought it was
> because I needed to run a syncdb, but stopping the server, running a syncdb,
> and restarting has generated the same error:
>
> Op
uldn't tell.
On Fri, Jun 25, 2010 at 5:35 PM, Oleg Lomaka wrote:
>
> Did you add your application to INSTALLED_APPS before running syncdb?
>
> On Jun 26, 2010, at 12:09 AM, Jonathan Hayward wrote:
>
> > P.S. Renaming the (SQLite) database file and running syncdb again
&g
model changes, just
> running syncdb will not make the appropriate changes to your tables. You
> probably need to look into south migrations.
>
> On Fri, Jun 25, 2010 at 2:09 PM, Jonathan Hayward <
> christos.jonathan.hayw...@gmail.com> wrote:
>
>> P.S. Re
ur PYTHONPATH. syncdb scans all modules from
> INSTALLED_APPS looking for models.py in them to populate database. So if you
> access you Entity model (for example at views.py) as
> from directory.models import Entity
> then add 'directory' to INSTALLED_APPS.
>
>
> O
ackages',
'/usr/lib/python2.6/dist-packages/PIL',
'/usr/lib/python2.6/dist-packages/gst-0.10', '/usr/lib/pymodules/python2.6',
'/usr/lib/python2.6/dist-packages/gtk-2.0',
'/usr/lib/pymodules/python2.6/gtk-2.0',
'/usr/local/lib/python2.6/dist-
P.S. This problem did not resurface after I made other changes discussed
elsewhere in the thread; it seems to be secondary damage.
On Mon, Jun 28, 2010 at 2:46 PM, Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> Thanks for pointing me to South. I've glanced over
Thank you! Solved.
On Mon, Jun 28, 2010 at 4:14 PM, Jeff Green wrote:
> You need to also state that null=True. Also, you want to have ensure that
> the field defined in your db
> allows null values.
>
> On Mon, Jun 28, 2010 at 3:19 PM, Jonathan Hayward <
> christos.jonat
ns to a file or equivalent? The
test server has no MTA so I can't really ask it to email me exceptions.
TIA,
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, literature, et cetera.
→ My award-winning collection is available for free reading onlin
easily enough create JSON manually, but is there a
preferred way to take dicts, lists, strings, numbers, etc. and render a
structure as JSON?
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, literature, et cetera.
→ My award-winning collection is
Thank you!
On Wed, Jul 7, 2010 at 5:35 PM, elijah rutschman wrote:
> You could implement a middleware class with a process_exception
> method. See:
> http://docs.djangoproject.com/en/dev/topics/http/middleware/#process_exception
>
> -Elijah
>
> On Wed, Jul 7, 2010 at 4:35
Never mind; I found:
import json
def view(request):
...
my_result = ...
return HttpResponse(json.dumps(my_result), mimetype="application/json")
On Wed, Jul 7, 2010 at 6:05 PM, Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
ther way I should be going about this given the id field
beforehand?
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, literature, et cetera.
→ My award-winning collection is available for free reading online:
☩ I invite you to visit
>
> If you'd like the code for it, I can ask my company whether they'd be
> happy with me publishing it.
>
> Cheers, Euan
>
> On Jul 7, 10:35 pm, Jonathan Hayward
> wrote:
> > I'm working on a view made to output JSON for Ajax use. My log has:
> >
(note id__exact rather than id__equals)
>
>
>
> On Jul 14, 3:18 pm, Jonathan Hayward
> wrote:
> > How do I look up a model instance by id (its primary key)? I have:
> >
> > entity = directory.models.Entity.objects.filter(id__equals = id)[0]
> >
> > an
,
line 127, in patch_vary_headers
if response.has_header('Vary'):
AttributeError: 'SafeUnicode' object has no attribute 'has_header'
This wasn't the usual format for a Django traceback, and the traceback is
only in Django code, no reference to my project.
Thank you; noted; that fixed it.
On Thu, Jul 15, 2010 at 5:51 AM, Tom Evans wrote:
> On Wed, Jul 14, 2010 at 8:48 PM, Jonathan Hayward
> wrote:
> > I am working on debugging a basic template, and after correcting some
> other
> > error, I got:
> >
> >
ty" and "description" are effectively replaced by dynamically
provided values?
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, literature, et cetera.
→ My award-winning collection is available for free reading online:
☩ I
Thank you! Let me play with it.
On Thu, Jul 15, 2010 at 10:41 AM, Daniel Roseman wrote:
> On Jul 15, 4:19 pm, Jonathan Hayward
> wrote:
> > I'm looking at a problem and see how to solve it, probably badly, with
> > eval(), but don't see what the right soluti
>> # ...or you could leave off app_label, if there are no conflicting model
>> names
>> my_ct.get_object_for_this_type(pk=my_pk)
>>
>> That way you could use get_object_or_404() in your view.
>>
>> Ben
>>
>>
>> On Thu, Jul 15, 2010 at 10:21 AM, Jonathan Hayward <
r/local/lib/python2.6/lib-dynload',
'/usr/local/lib/python2.6/site-packages']Server time:Thu, 22 Jul 2010
16:26:04 -0500
--
→ Jonathan Hayward, christos.jonathan.hayw...@gmail.com
→ An Orthodox Christian author: theology, literature, et cetera.
→ My award-winning collection i
Would it make sense to make
A: A TextEmailField which does not have the ForeignKey, and
B: A model which has the foreign key and a TextEmailField
as a better and more standard approach?
On Thu, Jul 22, 2010 at 3:13 PM, Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
Thank you!
On Fri, Jul 23, 2010 at 1:44 AM, Daniel Roseman wrote:
> On Jul 22, 9:55 pm, Jonathan Hayward
> wrote:
> > Would it make sense to make
> >
> > A: A TextEmailField which does not have the ForeignKey, and
> >
> > B: A model which has the foreign k
Q: How many Django developers does it take to change a light bulb?
A: *NONE.* (There's an application for that that comes standard with any
Django installation.)
--
→ Jonathan Hayward, a Senior Web Developer who cares deeply about usability
→ www.linkedin.com/in/jonathanhayward • jonathan
e named satchmo_skeleton
Do people have suggestions, including going to a Satchmo-specific list if
this list is not intended to discuss Django add-ons like Satchmo or Pinax?
--
→ Jonathan Hayward, a Senior Web Developer who cares deeply about usability
→ www.linkedin.com/in/jonathanhayward • jon
tionProcess>Hope
> it helps
>
> lzantal
>
>
>
> On Mon, Mar 22, 2010 at 12:14 PM, Andrew wrote:
>
>> Go to:
>> http://groups.google.com/group/satchmo-users
>>
>> On 15 мар, 20:10, Jonathan Hayward
>> wrote:
>> > I'm trying to g
second
request to another core?
If this isn't the default, can it be enabled, and are there race conditions
or other risks?
Thanks,
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Jonathan Hayward, an Orthodox Christian author.
*Amazon* <https://www.ama
t.
Part of my problem is that I haven't found mod_fcgi examples. Could I have an
example of a .fcgi file that says to connect to this port on this IP, with
indicators of any additional information needed (like the project path or the
deploy subdirectory.)
Jonathan Hayward, Author, Django Ja
/?next=/, which presents the Django
debug mode 404 page.
I am running Django 1.2.1. How can I glue things together so a
@login_required decorator finds a logged-in user, and I can build on top of
that?
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward,
FastCGIExternalServer directive.
Is there a way I can leverage the /fcgi-bin/ directory and httpd.conf so
that requests for /shop/foo/ are serviced by Django?
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian author.
Auth
hen I go through and comment out the docstring and __str__() and
__unicode__() methods.
What are the likely causes, and what can I do to fix this?
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian author.
Author Bio &
86_64/lib/python2.7/lib-tk',
'/tools/python/2.7/Linux_x86_64/lib/python2.7/lib-old',
'/tools/python/2.7/Linux_x86_64/lib/python2.7/lib-dynload',
'/tools/python/2.7/Linux_x86_64/lib/python2.7/site-packages',
'/tools/python/2.7/Linux_x86_64/lib/python2.7/site-packag
l the
tables created for the Django admin interface to work? For another project,
I couldn't save objects because an admin interface table didn't exist.)
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian auth
I found the problem. I needed to put 'foo' (and 'django.contrib.admin') in
settings.INSTALLED_APPS.
On Sat, Apr 9, 2011 at 2:29 PM, Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I am missing a step in configuration, I believe, in getting a sync
rsions/2.6/lib/python2.6/lib-dynload',
'/Library/Python/2.6/site-packages',
'/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/PyObjC',
'/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode']Server
time:T
admin.py file for the app that contains the Entity model.
>
> On 18 August 2010 10:57, Christos Jonathan Hayward <
> christos.jonathan.hayw...@gmail.com> wrote:
>
>> I am trying to migrate from one server to another: I tarred it up on the
>> Linux server, untarred on a M
on/PyObjC',
'/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/wx-2.8-mac-unicode']Server
time:Tue, 17 Aug 2010 21:20:53 -0500
On Tue, Aug 17, 2010 at 8:39 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
&g
error looks like an import error in disguise. (
> http://code.djangoproject.com/browser/django/tags/releases/1.2.1/django/utils/importlib.py
> )
>
> Fire up the python interpreter shell, and trying importing the
> django.contrib.admin module manually and see if you get
ere the text field equals a
name I am testing against.
--
[image: Christos Jonathan Hayward] <http://JonathansCorner.com>
Christos Jonathan Hayward, an Orthodox Christian author.
Author Bio <http://JonathansCorner.com/author/> • Books<http://CJSHayward.com/>
•
I think I found the problem; for the record, I wanted text__exact, not
text__equals.
On Wed, Aug 25, 2010 at 1:27 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I am trying to get a many-to-many tagging setup working, and I am getting
> an error whic
ecified.
>
> Alex
>
> On Aug 25, 1:37 pm, Christos Jonathan Hayward
> wrote:
> > I think I found the problem; for the record, I wanted text__exact, not
> > text__equals.
> >
> > On Wed, Aug 25, 2010 at 1:27 PM, Christos Jonathan Hayward <
> >
> &g
.objects.get(id =
int(search.group(2
entity.save()
Is the code above, with the .tags.remove() code, enough, or do both the
Entity and the Tag need to have a call to break the link?
--
[image: Christos Jonathan Hayward] <http://JonathansCorner.com>
Christos Jonathan
I finally pinned down the problem; it was in an unrelated area.
Thanks,
On Tue, Aug 31, 2010 at 5:59 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I have an Entity which has a many-to-many field "tags" to Tags. I'm trying
> to pin down
How can I filter for instances having a NullBooleanField that is not True
(i.e. is either False or a null)?
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian author.
Author Bio <http://jonathanscorner.com/author/>
P.S. Setting:
.filter(is_invisible__in = [False, None])
is not working as intended; I seem to be getting no matches when I should be
getting matches.
On Fri, Sep 10, 2010 at 4:19 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> How can I filter for instanc
Thanks, and noted for the future. I went with a regular BooleanField
defaulting to False.
On Sat, Sep 11, 2010 at 7:08 AM, Preston Holmes wrote:
>
>
> On Sep 10, 2:43 pm, Christos Jonathan Hayward
> wrote:
> > P.S. Setting:
> >
> > .filter(is_invisible__in
= models.TextField(null = True, blank = True)
def format_timestamp(self):
return directory.functions.format_timestamp(self.timestamp)
Any comments on how either I am misunderstanding how to use
GenericForeignKeys, or how I might otherwise be clobbering one model type
with another?
self.validate(value)
self.run_validators(value)
return value
def get_internal_type(self):
return u'TextField'
def __init__(self, *arguments, **keywords):
models.URLField.__init__(self, *arguments, **keywords)
Any suggestions?
--
[image: Christos
alled.
On Mon, Sep 13, 2010 at 3:44 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I have a TextURLField defined below, and I am trying to get the clean() to
> prepend http:// to all entries that do not contain a ':'. In other words,
> if someo
Thank you.
On Tue, Sep 14, 2010 at 3:01 AM, Daniel Roseman wrote:
> On Sep 13, 10:50 pm, Christos Jonathan Hayward
> wrote:
> > Other attempts to write a clean that would run a print statement and then
> > call to_python(), validate(), and run_validators() did not result
tely you need to change the
> "models" in AUTH_PROFILE_MODULE to the name of your app.
>
> Let us know if that works for you.
>
> Toodle-lo..
> creecode
>
>
> --
> You received this message because you are subscribed to the Google G
n Tue, Feb 14, 2012 at 12:32 PM, Kevin Anthony
wrote:
> Did you include the module in your settings.py?
>
> Kevin
> Please excuse brevity, sent from phone
> On Feb 14, 2012 1:27 PM, "Christos Jonathan Hayward" <
> christos.jonathan.hayw...@gmail.com> wrote:
>
&g
I forgot to specify where. The traceback is on a '''python manage.py
syncdb''', and happens immediately after the password is entered twice.
On Wed, Feb 15, 2012 at 3:39 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I'm
P.S. The source is at http://JonathansCorner.com/project/pim.tgz.
On Wed, Feb 15, 2012 at 3:40 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I forgot to specify where. The traceback is on a '''python manage.py
> syncdb''
views to
lessen the load of spam?
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian author.
Author Bio <http://jonathanscorner.com/author/> • Books<http://cjshayward.com/>
• *Email * •
Facebook<http://w
Breadcrumb note: someone on the list pointed out the middleware described at
the bottom of django-honeypot's homepage. That was what I wanted.
On Thu, Sep 8, 2011 at 1:21 PM, Christos Jonathan Hayward <
christos.jonathan.hayw...@gmail.com> wrote:
> I would like to incorporate d
te_base.html.
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian author.
Author Bio <http://jonathanscorner.com/author/> • Books<http://cjshayward.com/>
• *Email * •
Facebook<http://www.facebook.com/c
f the directories
> specified in your TEMPLATE_DIRS variable in settings.py.
> They are considered in the order they are written, so the base.html you are
> extending is the first you find in this sequence.
>
> Hope this helps, feel free to reply
>
> 2011/9/9 Christos J
to my question: *How can I tell Django to use the VPS's
regular sendmail to power send_mail, retry_deferred, and emit_notices?*
*
*
Thanks in advance.
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian
system whose features are best showcased in what
happens to be a social network, but I have more easily gotten a social
network running on 0.5 than more recent releases.
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian author.
*
ndering if you could
give me any help to load static content appropriately (it doesn't work to
copy the line that loads media and change it to point to static values).
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox C
e out of it. I'm
ignorant on that point. How can I cure my ignorance? What resources are out
there so I can get what was so easily in reach in older versions of Pinax?
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian aut
omething about Django and
something about older, fully assembled versions of Pinax, but not how to
take a starter Pinax project and make a finished site out of it. I'm
ignorant on that point. How can I cure my ignorance? What resources are out
there so I can get what was so easily in reach in old
I
was wondering if people could help me with what I hope is a winning
approach, installing 0.7 and dependencies.
Thanks,
--
[image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
Christos Jonathan Hayward, an Orthodox Christian author.
*Amazon <http://amazon.com/author/cjsha
77 matches
Mail list logo