Django email setup on Hostgator

On Hostgator it is possible to run Django applications with FastCgi, but it has only sendmail as email back-end which is not included in Django.

Hopefully there is a snipets to resolve this limitation. You just needed to change the path of the sendmail file and it was ready to run. The location of sendmail is "/usr/sbin/sendmail" on our Hostgator server.

And the email backend should be configured in your by adding the following line:

EMAIL_BACKEND = 'sendmail.EmailBackend'

Dajngo app unicode JSON repsonse

If your django application has unicode data, and your view uses jquery and JSON response, do not forget to specify the encoding for the mimetype:

return HttpResponse(simplejson.dumps(your_data),
mimetype='application/json; charset=utf-8')

Open OpenOffice documents from a network share using nautilus

Under my gnome desktop, I had a problem when tired to open documents from a network share with OpenOffice. When I tired the spalsh screen appeared, but the document did not open.

After some searching I found the debian squeze has a package I was curious what is the difference between the standard package and this one. Soon I found it's home page:

Almost the first line said:

Gnome-VFS - G/OO.o allows transparent access to allow documents to be loaded / saved from a range of Gnome VFS backends, eg. Samba shares.

I installed and the problem went away.

django-expense v0.2.0

Django-expense, a simple personal expense tracker application for Django.

Version 0.2.0 has just released with the following new features:

  • Charts, using flot jQuery library.

  • Updated documentation with screen shoots.

  • Fixed expense screen appearance with django 1.3.

  • Added test application into the source tree to make trying/testing easier.
  • Added initial data.

Source code is available on bitbucket.

If you have any question, feel free to open a ticket or send a message.

Have fun!

Resize files using one command

Using ImageMagick it is easy to resize multiple images by the following command:

for i in `ls *.JPG`; do convert -resize 1024 $i $i; done

A bit detailed version of this script can be found in my bitbucket repository:


About two years ago I tired Dajngo, the popular python web framework. I was impressed how easy and logical is the usage of it. I started to create some simple apps only for personal usage. One of these apps was django-expense, a simple personal/family expense tracker application.

Now I refactored a bit and put the source to bitbucket.

From the user view: It is uses the default Dajngo admin site and you can record expenses and check them in monthly or yearly view.

From technical view, you can find examples to the following django specific areas:

  • Aggregation

  • Customized ChangeList view

  • Custom filterspec

If you interested you can get the source using mercurial from bitbucket or download the latest version.