File tree Expand file tree Collapse file tree 2 files changed +34
-1
lines changed Expand file tree Collapse file tree 2 files changed +34
-1
lines changed Original file line number Diff line number Diff line change 56
56
color : # 999 ;
57
57
}
58
58
59
+ ul .dropdown-menu > li > form {
60
+ display : block;
61
+ width : 100% ;
62
+ }
63
+
64
+ ul .dropdown-menu > li > form > button {
65
+ /* taken from bootstrap's styling for '.dropdown-menu > li > a' */
66
+ background : none;
67
+ border : none;
68
+ cursor : pointer;
69
+ display : block;
70
+ padding : 3px 20px ;
71
+ clear : both;
72
+ font-weight : 400 ;
73
+ line-height : 1.42857143 ;
74
+ color : # 333 ;
75
+ white-space : nowrap;
76
+ width : 100% ;
77
+ text-align : left;
78
+ }
79
+
80
+ ul .dropdown-menu > li > form > button : hover {
81
+ /* taken from bootstrap's styling for '.dropdown-menu > li > a:hover' */
82
+ color : # 262626 ;
83
+ text-decoration : none;
84
+ background-color : # f5f5f5 ;
85
+ }
86
+
59
87
form {
60
88
padding : 0em ;
61
89
margin : 0em ;
Original file line number Diff line number Diff line change 93
93
< li > < a href ="{% url 'admin:index' %} "> Administration</ a > </ li >
94
94
{% endif %}
95
95
< li > < a href ="{% url 'user-profile' %} "> View profile</ a > </ li >
96
- < li > < a href ="{% url 'auth_logout' %} "> Logout</ a > </ li >
96
+ < li >
97
+ < form id ="logout-form " method ="post " action ="{% url 'auth_logout' %} ">
98
+ {% csrf_token %}
99
+ < button type ="submit "> Logout</ button >
100
+ </ form >
101
+ </ li >
97
102
</ ul >
98
103
</ li >
99
104
{% else %}
You can’t perform that action at this time.
0 commit comments