Amazon S3 Website CNAME

While trying to create an S3-hosted static website I was trying to configure my domain to point to the S3 with a CNAME record on my DNS records for the domain.

The Amazon documentation mistakenly tells you to setup your CNAME to point to something like this:

#this is wrong! CNAME # will work # will not work

This configuration will not work if you want directories to serve index.html by default. You may notice that if you type the complete URL you will get an S3 “Access Denied” message.

For your bucket, go to: Properties->Website
You need:

Now you can configure your DNS settings.

# the proper configuration CNAME # will work # will work

Button labels for checkout

Taking an inventory of submit button labels during the purchase process.

* Add to cart
* Proceed to checkout
* Continue (3x)
* Place your order
* Buy
* Proceed to Checkout
* Use this Address
* Use this Card
* Place my order!
* Add to Cart
* View Cart and Checkout / Continue Shopping
* Proceed to Checkout (or PayPal button)
* UPGRADE NOW $5/month - $49/year
* Buy Supporter Account
* upgrade plan
* change plan
* confirm

Insert html django contrib messages

I wanted to use raw HTML in certain invocations of Django’s Messages architecture such as in messages.success.

When sending your message:

messages.success(request, mark_safe("""Thanks for your purchase. 
     Your <a href="%s">Account &gt; Payment</a>""" 
     % urlresolvers.reverse(‘account_payment_detail’, kwargs = {‘id’})
       ), extra_tags=‘html’)

Modify your Django snippet to skip the web-safe encoding:

{% if ‘html’ in message.tags %}
  {{ message|safe }}
{% else %}
  {{ message }}
{% endif %}
Syndicate content