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.

Comments

jhodgdon’s picture

Actually, 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.

avpaderno’s picture

Assigned: Unassigned » avpaderno

I will work on this March 19.

jhodgdon’s picture

Assigned: avpaderno » Unassigned
Issue tags: +Novice, +Needs backport to D7

I'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.

mjonesdinero’s picture

StatusFileSize
new1.41 KB

what 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.

mjonesdinero’s picture

Status: Active » Needs review
jhodgdon’s picture

Status: Needs review » Needs work

Thanks! 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.

asrob’s picture

Status: Needs work » Needs review
StatusFileSize
new1.08 KB

It'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.

avpaderno’s picture

Status: Needs review » Needs work

As 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:

node: The current template type (for example, "theming hook").

avpaderno’s picture

Thinking better of this, I would rather propose the following plan:

  • Replace i.e. with e.g. as per this issue report.
  • Open a new issue report for replacing e.g. with for example between parentheses.

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.

avpaderno’s picture

Status: Needs work » Needs review
StatusFileSize
new37.79 KB

This 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.

avpaderno’s picture

This 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.

jhodgdon’s picture

Title: Incorrect use of "i.e." » Don't use i.e. or e.g. -- too much misuse potential
Status: Needs review » Needs work

Actually, 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:

- *   The type of the item (i.e. theme, theme_engine, module, profile).

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.

-  // installed yet (i.e., if no $databases array has been defined in the
+  // installed yet (i.e. if no $databases array has been defined in the

This change in puncutation is incorrect, IMO, and I think we can just leave out i.e. here entirely.

- * If a destination was specified in the current request's URI (i.e.,
+ * If a destination was specified in the current request's URI (e.g.,
  * $_GET['destination']) then it will override the $path and $options values

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.).

balsama’s picture

Status: Needs work » Needs review
StatusFileSize
new2.53 KB

Looks 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.

jhodgdon’s picture

Title: Don't use i.e. or e.g. -- too much misuse potential » Remove i.e. and e.g. from node.tpl.php
Status: Needs review » Needs work

Looks pretty good! One mistake:

- *   - view-mode-[view_mode]: The View Mode of the node e.g. teaser or full.
+ *   - view-mode-[view_mode]: The View Mode of the node; that is, teaser or full.

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!

balsama’s picture

StatusFileSize
new2.54 KB

I don't think I realized that D7/8 had the ability to add additional view modes! Good to know.

balsama’s picture

Status: Needs work » Needs review
StatusFileSize
new5.11 KB

And for Bartik.

jhodgdon’s picture

Status: Needs review » Needs work

The 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.

balsama’s picture

Status: Needs work » Needs review
StatusFileSize
new6.11 KB
new6.11 KB

Rerolled attached.

I also wrapped some lines that were over 80 characters.

jhodgdon’s picture

Why two patches on one issue? Normally we just do one... I'll have to review these later, sorry, can't do it right now...

balsama’s picture

StatusFileSize
new6.11 KB

My mistake. The patches are identical and both include changes for both files. To keep it simple, please review the patch attached to this message.

jhodgdon’s picture

Status: Needs review » Needs work

Looks pretty good! I did notice this:

+ *   - view-mode-[view_mode]: The View Mode of the node; for example, "teaser"
+       or "full".

That second line is missing a * at the beginning.

Other than that, I think it looks fine. Thanks!

jibran’s picture

Status: Needs work » Needs review
StatusFileSize
new6.11 KB

added the *

jhodgdon’s picture

Version: 8.x-dev » 7.x-dev
Status: Needs review » Patch (to be ported)

Thanks! Committed to 8.x. Needs reroll/port for 7.x

jibran’s picture

StatusFileSize
new4.9 KB

d7 patch

jibran’s picture

Status: Patch (to be ported) » Needs review

updated status

jhodgdon’s picture

Status: Needs review » Reviewed & tested by the community

Thanks! I'll get this committed shortly.

jhodgdon’s picture

Status: Reviewed & tested by the community » Fixed

Committed to 7.x. Thanks!

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

Improved formatting.