API page: http://api.drupal.org/api/drupal/core%21modules%21node%21node.tpl.php/8
The documentation page contains the following text:
node: The current template type, i.e., "theming hook".
The text should be the following one:
node: The current template type, e.g., "theming hook".
The correct use of i.e. is as in the following sentence:
A walking boot that is synthetic, i.e., not leather or suede.
What follows i.e. is an exhaustive list; if the list I am going to list is not exhaustive, then I should use e.g., as in the following sentence.
I like only few vegetables, e.g. carrots, tomatoes, and peppers.
When I use i.e. or e.g. there should not be any etc in the list, as in the first case the list is supposed to be exhaustive, while in the second case the list is not exhaustive by definition.
I spotted at least two places where i.e. is not correctly used. I am not sure how to proceed with creating a patch, as a too generic patch would not apply anymore as soon as one of the other pending patches is applied; doing a single patch for each function doesn't see the correct way to proceed too.
| Comment | File | Size | Author |
|---|---|---|---|
| #25 | 1472724-25.patch | 4.9 KB | jibran |
| #23 | 1472724-23.patch | 6.11 KB | jibran |
| #16 | incorrect-use-of-i-1472724-16.patch | 2.54 KB | balsama |
| #21 | incorrect-use-of-ie-1472724-21.diff | 6.11 KB | balsama |
| #19 | incorrect-use-of-ie-1472724-19.diff | 6.11 KB | balsama |
Comments
Comment #1
jhodgdonActually, the correct text should be [note punctuation!]:
node: The current template type; e.g., "theming hook".
The reason is that "e.g." means "for example". "i.e." means "that is", and you are perfectly right, it is misused in the node: text.
Actually, I'd prefer not to use either of them. How about:
node: The current template type; for example, 'theming hook'.
Anyway, just go ahead and make one patch with all the places you've spotted. We can deal with rerolling it. If it is only a few places, there's a good chance it can just get committed.
Comment #2
avpadernoI will work on this March 19.
Comment #3
jhodgdonI'm assuming this should be unassigned so someone else can pick it up? Feel free to assign it back if you still want to work on it.
Comment #4
mjonesdinero commentedwhat i have done in this patch is to change the eg, to for example as what on comment #1 have said
you can also add other possible changes on the documentation so that i can re-roll and make a new patch again
Thanks.
Comment #5
mjonesdinero commentedComment #6
jhodgdonThanks! But the patch you uploaded contains the fix for another issue along with the fix for this issue.
Also, the original report mentioned finding this problem elsewhere in the documentation. So if you wanted to do even more, you could use "grep" to find other places with "i.e." in the documentation, see if they are also wrong, and fix them in a similar way.
Comment #7
asrobIt's good novice issue for me so as to I start to know the drupal core development deeply that's why I worked on this and attached a patch.
Comment #8
avpadernoAs said in a previous comment, the patch should replace all the instances of i.e. with e.g., where necessary.
As per punctuation, before e.g. is used a comma. The examples I shown in the issue summary have been taken from the New Oxford American English dictionary, which never uses a semicolon before e.g. The comma after e.g. is not strictly necessary, but it is normally used.
I propose to use the following style:
Comment #9
avpadernoThinking better of this, I would rather propose the following plan:
In this issue we are aiming just a part of the instances of e.g.: the ones for which i.e. has been wrongly used. If we are going to replace e.g., it makes more sense in an issue report that involves every instance of e.g.; if then we decide that is not worth replacing e.g., this patch would still be correct, as it replaces i.e. with e.g. where i.e. should not be used.
Comment #10
avpadernoThis is my first tentative of providing a patch, basing on my previous comments.
If the patch is being provided for any file, novice users should know there are files that should not be patched, i.e. the ones provided from third-parties.
Comment #12
avpadernoThis is a slightly better patch. The documentation for a function was referring to the /modules directory, which is /core/modules in Drupal 8.
I didn't ask the patch to be tested because the previous one was working.
Comment #13
jhodgdonActually, let's get rid of all i.e. and e.g. in the documentation, in this patch. They're more often misused than used correctly, and so many people are confused about what they are... i.e. we shouldn't probably even need at all, and we can replace e.g. with "for example" where it is actually necessary. In the rare case that i.e. is actually needed, use the English "that is".
Regarding "do not test" -- all new patches that are supposed to be committed must be tested. Period. As a committer, that makes me more confident that there wasn't a small syntax error in the patch that completely breaks core. Thanks!
So, my suggestion would be for a few of the changes in this patch:
Take out the "i.e.", and say "(theme, theme_engine, module, etc.)" instead. This actually *could* be "that is", but anyway the punctuation was wrong.
This change in puncutation is incorrect, IMO, and I think we can just leave out i.e. here entirely.
This really was "that is" not "for example" I think. I think it should be reworded to say:
If $_GET['destination'] was specified in the current request, then it will override the $path...
So, all of these changes will need a bit of thought... but I think we'd be better off without using either e.g. (which is almost always mis-punctuated) or i.e. (which is often used to mean e.g. by mistake, and in the rare case when it's used correctly, is misunderstood by the majority of people who think it means e.g.).
Comment #14
balsamaLooks like this file has changed since the last patch, but here's my attempt at getting rid of all the e.g. i.e.s.
Comment #15
jhodgdonLooks pretty good! One mistake:
This one should be "for example", and the examples should be in '' quotes.
Otherwise, looks fine. The other thing we should do is make the same changes in bartik's node.tpl.php and any other node.tpl.php files in core. Thanks!
Comment #16
balsamaI don't think I realized that D7/8 had the ability to add additional view modes! Good to know.
Comment #17
balsamaAnd for Bartik.
Comment #18
jhodgdonThe patch in #17 looks good to me and to the test bot, but I cannot get it to apply to the latest 8.x. I think it just needs a reroll-- looks like some templates got updated recently.
Comment #19
balsamaRerolled attached.
I also wrapped some lines that were over 80 characters.
Comment #20
jhodgdonWhy two patches on one issue? Normally we just do one... I'll have to review these later, sorry, can't do it right now...
Comment #21
balsamaMy mistake. The patches are identical and both include changes for both files. To keep it simple, please review the patch attached to this message.
Comment #22
jhodgdonLooks pretty good! I did notice this:
That second line is missing a * at the beginning.
Other than that, I think it looks fine. Thanks!
Comment #23
jibranadded the *
Comment #24
jhodgdonThanks! Committed to 8.x. Needs reroll/port for 7.x
Comment #25
jibrand7 patch
Comment #26
jibranupdated status
Comment #28
jhodgdonThanks! I'll get this committed shortly.
Comment #29
jhodgdonCommitted to 7.x. Thanks!
Comment #30.0
(not verified) commentedImproved formatting.