Support non-html URIs and ensure saving/loading works well (fix #28)