]> git.openstreetmap.org Git - osqa.git/blob - forum/skins/default/templates/users/edit.html
making the user edit url contain the user slug
[osqa.git] / forum / skins / default / templates / users / edit.html
1 {% extends "base_content.html" %}\r
2 <!-- user_edit.html -->\r
3 {% load extra_tags %}\r
4 {% load humanize %}\r
5 {% load i18n %}\r
6 {% block title %}{% spaceless %}{% trans "Edit user profile" %}{% endspaceless %}{% endblock %}\r
7 {% block forejs %}\r
8         <script type="text/javascript">google.load("jquery", "1.4.2");google.load("jqueryui", "1.8.1");</script>\r
9 \r
10         <link rel="stylesheet" href="http://jquery-ui.googlecode.com/svn/tags/latest/themes/base/jquery-ui.css" type="text/css" media="all" />\r
11         <link rel="stylesheet" href="http://static.jquery.com/ui/css/demo-docs-theme/ui.theme.css" type="text/css" media="all" />\r
12 \r
13         <script type="text/javascript">\r
14             $().ready(function(){\r
15                 $("#id_birthday").datepicker({\r
16                     changeMonth: true,\r
17                     changeYear: true,\r
18                     dateFormat: 'yy-mm-dd',\r
19                     minDate: null,\r
20                     maxDate: '0M 0D',\r
21                     yearRange: '1920:2010'\r
22                 });\r
23 \r
24                 $("#nav_profile").attr('className',"on");\r
25                 $("#cancel").bind('click', function(){history.go(-1);})\r
26             });     \r
27         </script>\r
28         {% block userjs %}\r
29         {% endblock %}\r
30 {% endblock %}\r
31 {% block content %}\r
32 <div id="main-bar" class="headNormal">\r
33     {{ user.username }} - {% trans "edit profile" %}\r
34 </div>\r
35 <div id="main-body" style="width:100%;padding-top:10px">\r
36     <form name="" action="{% url edit_user user.id user.username|slugify %}" method="post">\r
37         {% csrf_token %}\r
38         <div id="left" style="float:left;width:180px">\r
39             {% if user.email %}\r
40             {% gravatar user 128 %}\r
41             {% else %}\r
42             <img src="{% media  "/media/images/nophoto.png" %}">\r
43             {% endif %}\r
44             <div style="padding:20px 0 0 20px;font-weight:bold;font-size:150%">\r
45                 <a href="http://www.gravatar.com/" target="_blank" \r
46                                         title="gravatar {% trans "image associated with your email address" %}">{% trans "gravatar" %}</a>\r
47             </div>\r
48         </div>\r
49         \r
50         <div id="askform" style="float:right;width:750px;text-align:left;">\r
51             <h2>{% trans "Registered user" %}</h2>\r
52             <table class="user-details">\r
53                 <tr>\r
54                     <th width="100px"></th>\r
55                     <th></th>\r
56                 </tr>\r
57                 <tr style="height:35px">\r
58                         <td>{% trans "Screen Name" %}:</td>\r
59                         <td>\r
60                         {% if form.username %}\r
61                             {{ form.username }} <span class="form-error"></span> {{ form.username.errors }}\r
62                         {% else %}\r
63                             {{ user.username }}\r
64                         {% endif %}\r
65                         </td>\r
66                     </tr>\r
67                 \r
68                     <tr style="height:35px">\r
69                         <td>{{ form.email.label_tag }}:</td>\r
70                         <td>{{ form.email }} <span class="form-error"></span> {{ form.email.errors }} </td>\r
71                     </tr>\r
72                 <tr style="height:35px">\r
73                         <td></td>\r
74                         <td class="title-desc">{{ form.email.help_text }}</td>\r
75                     </tr>\r
76                 <tr style="height:35px">\r
77                         <td>{{ form.realname.label_tag }}:</td>\r
78                         <td>{{ form.realname }} <span class="form-error"></span> {{ form.realname.errors }} </td>\r
79                     </tr>\r
80                 <tr style="height:35px">\r
81                         <td>{{ form.website.label_tag }}:</td>\r
82                         <td>{{ form.website }} <span class="form-error"></span> {{ form.website.errors }} </td>\r
83                     </tr>\r
84                 <tr style="height:35px">\r
85                         <td>{{ form.city.label_tag }}:</td>\r
86                         <td>{{ form.city }} <span class="form-error"></span> {{ form.city.errors }} </td>\r
87                     </tr>\r
88                 <tr style="height:35px">\r
89                         <td>{{ form.birthday.label_tag }}:</td>\r
90                         <td>{{ form.birthday }} <span class="form-error"></span> {{ form.birthday.errors }} </td>\r
91                     </tr>\r
92                 <tr>\r
93                         <td style="vertical-align:top">{{ form.about.label_tag }}:</td>\r
94                         <td>{{ form.about }} <span class="form-error"></span> {{ form.about.errors }} </td>\r
95                     </tr>\r
96                     \r
97             </table>\r
98             <div style="margin:30px 0 60px 0">\r
99                 <input type="submit" value="{% trans "Update" %}" class="submit" >\r
100                 <input id="cancel" type="button" value="{% trans "Cancel" %}" class="submit" >\r
101           \r
102             </div>\r
103         </div>\r
104     </form>\r
105     \r
106 </div>\r
107 {% endblock %}\r
108 <!-- end user_edit.html -->\r