Pārlūkot izejas kodu

Added sticky footer

Denis Merigoux 10 gadi atpakaļ
vecāks
revīzija
76dc85220a
2 mainītis faili ar 37 papildinājumiem un 0 dzēšanām
  1. 5 0
      LAPI/settings.py
  2. 32 0
      static/sticky-footer.css

+ 5 - 0
LAPI/settings.py

@@ -83,3 +83,8 @@ USE_TZ = True
83 83
 # https://docs.djangoproject.com/en/1.7/howto/static-files/
84 84
 
85 85
 STATIC_URL = '/static/'
86
+
87
+STATICFILES_DIRS = (
88
+    os.path.join(BASE_DIR, "static"),
89
+)
90
+

+ 32 - 0
static/sticky-footer.css

@@ -0,0 +1,32 @@
1
+/* Sticky footer styles
2
+-------------------------------------------------- */
3
+html {
4
+  position: relative;
5
+  min-height: 100%;
6
+}
7
+body {
8
+  /* Margin bottom by footer height */
9
+  margin-bottom: 60px;
10
+}
11
+.footer {
12
+  position: absolute;
13
+  bottom: 0;
14
+  width: 100%;
15
+  /* Set the fixed height of the footer here */
16
+  height: 60px;
17
+  background-color: #f5f5f5;
18
+}
19
+
20
+
21
+/* Custom page CSS
22
+-------------------------------------------------- */
23
+/* Not required for template or sticky footer method. */
24
+
25
+.container {
26
+  width: auto;
27
+  max-width: 680px;
28
+  padding: 0 15px;
29
+}
30
+.container .text-muted {
31
+  margin: 20px 0;
32
+}