`

Best Wordpress Hosting Providers - 2010

All three hosts offer FREE 1-click Wordpress installs making them the best Wordpress hosting providers. For more web hosting reviews be sure to check out AlreadyHosting.com.

 #1
#2 
 #3
#1 - Bluehost 
Bluehost Review
#2 - Hostmonster 
Hostmonster Review
#3 - iPage 
iPage Review

Sep 25

Webfaction logoLast week, I signed up an account with Webfaction, for my latest Django (sounds like Jungle) adventure. So far, it's one of the few web hosting companies out there that offer support for Django framework and they did a superb job at it. I love them.

A few days back, I wrote my first Django app, Tweeeter, after following a few tutorials. With the app, I think it will be great to get it deployed to have a full experience from programming to deployment. So I followed the tutorial from Webfaction's knowledgebase.

However, I felt the approach has messed up the normal structure that I usually used, which is having apps folder and includes folder in the django project folder. The tutorial shows how to server static files by creating Webfaction's app. So if you have 10 static folders, you will have to create 10 Webfaction's app, which I can't understand why I must do it. So, after hours of trying, with the help of Webfaction's support, it finally works the way I wanted.

So how do I setup my own django app in Webfaction?

I followed exactly what the tutorial said except the part of setting up the static files. Instead of creating multiple apps, I just add the following to the apache/httpd.conf in the djangoproject.

Alias /includes/ /home/username/webapps/webfactionapp/djangoproject/includes/
 
    SetHandler None
Alias /media/ /home/username/webapps/webfactionapp/lib/python2.5/django/contrib/admin/media/
 
    SetHandler None

I hope it's clear enough. If there is any questions, feel free leave it in the comments.

written by mangoorange \\ tags: , , , , ,

Sep 18

I'm so proud of myself. I finally put together my very own, first Django project, FakeTwitter. I just created a simple wall to post with a timestamp. Simple stuff, but I have a wonderful time doing it.

Here's the screenshot of FakeTwitter.

The fake version of Twitter

written by mangoorange \\ tags: , ,

Sep 17

Practical Django ProjectsDjango has been my thing for the past few weeks. It's been a lot of fun reading the James Bennett's Practical Django Projects. Unfortunately, on Sept 3, the release of Django v1.0 has made many of the codes not compatible.

The new release of Django has given me a headache while I was trying to setup django-registration. The problem lies in the upgrading of Django to the latest build. The old Django codes cause a problem in setting the app. Thanks to the guys at the Django Channel that helped me out.

So I hope I can help by writing a tutorial for those who needs it. Stone Mind, once wrote a tutorial on django-registration, but it's out-dated now.

Here it goes:

Prerequisites:
django version 1.0
django-registration version 0.6 (if possible, use the trunk copy)

Step 1, unpack django-registration:
Put the app folder, registration into the project folder. (make sure that your PYTHONPATH is pointing to the project folder). registration folder is the folder that contains __init__.py.

Step 2, setup the application:
Add 'registration' into the list of INSTALLED_APPS. For example,

INSTALLED_APPS = (
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.sites',
    'django.contrib.admin',
    'registration',
)

Step 3, setup the database:
Run python manage.py syncdb to populate the tables from the list of applications. Ensure you have filled in the relevant database settings before you run it. Example for sqlite3 database settings,

DATABASE_ENGINE = 'sqlite3'
DATABASE_NAME = 'reg.db'
DATABASE_USER = ''
DATABASE_PASSWORD = ''
DATABASE_HOST = ''
DATABASE_PORT = ''

Step 4, setup the url pointer:
Add (r'accounts/', include('registration.urls')) into the list of URLpatterns. For example,

urlpatterns = patterns('',
    (r'^admin/(.*)', admin.site.root),
    (r'^accounts/', include('registration.urls')),
)

Step 5, setup the templates:
Setup the template path by adding /path/to/project/templates/ in TEMPLATE_DIRS. Example,

TEMPLATE_DIRS = (
   '/Users/mangoorange/Projects/Django/reg/templates/'
)

Step 6, inserting the templates:
This part is actually fairly simple. I have provided a copy of a working project, [download#74#nohits], that you can use. Just add in the django-registration app into the project folder. If you want to learn more about template form, you can check it out here.

Step 7, done:
Sorry to disappoint you. It's done. :)

Feel free to share any feedback and comments on the tutorial. Hope it helps.

written by mangoorange \\ tags: , ,

Sep 15

DjangoWhile I was learning how to use django-registration app, I discover in the tutorial that I need to know how to send an email for the user to activate the registration.

Thanks to folk at the Django chatroom, they advice me to google 'django gmail' and I discover a post at nathanostgard.com that show roughly how to do it. Here I'm going to extend a little on how to test it using shell.

  1. Create a project, django-admin.py startproject gmail
  2. Edit settings.py with code below:
    EMAIL_USE_TLS = True
    EMAIL_HOST = 'smtp.gmail.com'
    EMAIL_HOST_USER = 'youremail@gmail.com'
    EMAIL_HOST_PASSWORD = 'yourpassword'
    EMAIL_PORT = 587
  3. Run interactive mode, python manage.py shell
  4. Import the EmailMessage module,
    from django.core.mail import EmailMessage
  5. Send the email,
    email = EmailMessage('Subject', 'Body', t=['mickeyckm@mangoorange.com'])
    email.save()

Hope it help someone :) Reference here.

written by mangoorange \\ tags: , , ,

Sep 15

DjangoCon 2008It's a week since the first Django conference ended. Sigh, I didn't manage to get the ticket. Anyway, for those who missed it, like me, the videos are out. I can't wait to go through all of it.

The link below:
http://www.youtube.com/view_play_list?p=D415FAF806EC47A1

Share with me your favorites. :)

written by mangoorange \\ tags: , , ,