You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: en/css/README.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -85,7 +85,7 @@ h1 a, h2 a {
85
85
`h1 a` is a CSS Selector. This means we're applying our styles to any `a` element inside of an `h1` element; the `h2 a` selector does the same thing for `h2` elements. So when we have something like `<h1><a href="">link</a></h1>`, the `h1 a` style will apply. In this case, we're telling it to change its color to `#C25100`, which is a dark orange. Or you can put your own color here, but make sure it has good contrast against a white background!
86
86
87
87
In a CSS file we determine styles for elements in the HTML file. The first way we identify elements is with the element name. You might remember these as tags from the HTML section. Things like `a`, `h1`, and `body` are all examples of element names.
88
-
We also identify elements by the attribute `class` or the attribute `id`. Class and id are names you give the element by yourself. Classes define groups of elements, and ids point to specific elements. For example, you could identify the following tag by using the tag name `a`, the class `external_link`, or the id `link_to_wiki_page`:
88
+
We also identify elements by the attribute `class` or the attribute `id`. Class and id are names you give the element by yourself. Classes define groups of elements, and ids point to specific elements. For example, you could identify the following element by using the element name `a`, the class `external_link`, or the id `link_to_wiki_page`:
Copy file name to clipboardExpand all lines: en/django_forms/README.md
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,7 @@ Before we add the link, we need some icons to use as buttons for the link. For t
48
48
49
49
> Note: To download the SVG image, open the context menu on the link (usually by right-clicking on it) and select "Save link as". In the dialog asking you where to save the file, navigate to the `djangogirls` directory of your Django project, and within that to subdirectory `blog/templates/blog/icons/`, and save the file there.
50
50
51
-
It's time to open `blog/templates/blog/base.html` in the code editor. Now we can use this icon file inside the base template as follow. In the `div`tag inside `header` section, we will add a link before `h1`tag:
51
+
It's time to open `blog/templates/blog/base.html` in the code editor. Now we can use this icon file inside the base template as follow. In the `div`element inside `header` section, we will add a link before the `h1`element:
@@ -147,7 +147,7 @@ To create a new `Post` form, we need to call `PostForm()` and pass it to the tem
147
147
We need to create a file `post_edit.html` in the `blog/templates/blog` directory, and open it in the code editor. To make a form work we need several things:
148
148
149
149
- We have to display the form. We can do that with (for example) {% raw %}`{{ form.as_p }}`{% endraw %}.
150
-
- The line above needs to be wrapped with an HTML form tag: `<form method="POST">...</form>`.
150
+
- The line above needs to be wrapped with an HTML form element: `<form method="POST">...</form>`.
151
151
- We need a `Save` button. We do that with an HTML button: `<button type="submit">Save</button>`.
152
152
- And finally, just after the opening `<form ...>` tag we need to add {% raw %}`{% csrf_token %}`{% endraw %}. This is very important, since it makes your forms secure! If you forget about this bit, Django will complain when you try to save the form:
153
153
@@ -285,7 +285,7 @@ Now we know how to add a new post. But what if we want to edit an existing one?
285
285
286
286
First, let's save the icon which represents the edit button. Download [pencil-fill.svg](https://raw.githubusercontent.com/twbs/icons/main/icons/pencil-fill.svg) and save it to the location `blog/templates/blog/icons/`.
287
287
288
-
Open `blog/templates/blog/post_detail.html` in the code editor and add the following code inside `article`tag:
288
+
Open `blog/templates/blog/post_detail.html` in the code editor and add the following code inside `article`element:
@@ -380,7 +380,7 @@ If you need more information about Django forms, you should read the documentati
380
380
381
381
Being able to create new posts by clicking a link is awesome! But right now, anyone who visits your site will be able to make a new blog post, and that's probably not something you want. Let's make it so the button shows up for you but not for anyone else.
382
382
383
-
Open `blog/templates/blog/base.html` in the code editor, find our `div` inside `header` and the anchor tag you put in there earlier. It should look like this:
383
+
Open `blog/templates/blog/base.html` in the code editor, find our `div` inside `header` and the anchor element you put in there earlier. It should look like this:
@@ -389,7 +389,7 @@ Open `blog/templates/blog/base.html` in the code editor, find our `div` inside `
389
389
</a>
390
390
```
391
391
392
-
We're going to add another `{% if %}` tag to this, which will make the link show up only for users who are logged into the admin. Right now, that's just you! Change the `<a>`tag to look like this:
392
+
We're going to add another `{% if %}` tag to this, which will make the link show up only for users who are logged into the admin. Right now, that's just you! Change the `<a>`element to look like this:
0 commit comments