{"action":"created","comment":{"url":"https://api.github.com/repos/cakephp/docs/pulls/comments/82489322","pull_request_review_id":3396632,"id":82489322,"diff_hunk":"@@ -0,0 +1,179 @@\n+Breadcrumbs\n+###########\n+\n+.. php:namespace:: Cake\\View\\Helper\n+\n+.. php:class:: BreadcrumbsHelper(View $view, array $config = [])\n+\n+.. versionadded:: 3.3.6\n+\n+BreadcrumbsHelper provides a way to easily deal with the creation and rendering\n+of a breadcrumbs trail for your app.\n+\n+Creating a breadcrumbs trail\n+============================\n+\n+You can add a crumb to the list using the ``add()`` method. It takes three\n+arguments:\n+\n+- **title** The string to be displayed as a the title of the crumb\n+- **url** A string or an array of parameters that will be given to the :doc:`/views/helpers/url`\n+- **options** An array of attributes for the ``item`` and\n+  ``itemWithoutLink`` templates. See the section about :ref:`defining attributes for the item <defining_attributes_item>`\n+  for more informations.\n+\n+In addition to adding to the end of the trail, you can do a variety of operations::\n+\n+    // Add at the end of the trail\n+    $this->Breadcrumbs->add(\n+        'Products',\n+        ['controller' => 'products', 'action' => 'index']\n+    );\n+\n+    // Prepended middleware will be put at the top of the list\n+    $this->Breadcrumbs->prepend(\n+        'Products',\n+        ['controller' => 'products', 'action' => 'index']\n+    );\n+\n+    // Insert in a specific slot. If the slot is out of\n+    // bounds, it will be added to the end.\n+    $this->Breadcrumbs->insertAt(\n+        2,\n+        'Products',\n+        ['controller' => 'products', 'action' => 'index']\n+    );\n+\n+    // Insert before another crumb, based on the title.\n+    // If the named crumb title cannot be found,\n+    // an exception will be raised.\n+    $this->Breadcrumbs->insertBefore(\n+        'A product name', // the title of the crumb to insert before\n+        'Products',\n+        ['controller' => 'products', 'action' => 'index']\n+    );\n+\n+    // Insert after another crumb, based on the title.\n+    // If the named crumb title cannot be found,\n+    // an exception will be raised.\n+    $this->Breadcrumbs->insertAfter(\n+        'A product name', // the title of the crumb to insert after\n+        'Products',\n+        ['controller' => 'products', 'action' => 'index']\n+    );\n+\n+Using these methods give you the ability to go around CakePHP's way of\n+rendering the view. Since templates and layouts are rendered from the inside\n+out (meaning, included elements are rendered first), this allows you to define\n+precisely where you want to add a crumb.\n+\n+Rendering the breadcrumbs trail\n+===============================\n+\n+Basic rendering\n+---------------\n+\n+After adding crumbs to the trail, you can easily render it using the\n+``render()`` methods.\n+This method accepts two arguments, both of them arrays:\n+\n+- ``$attributes`` : An array of attributes that will applied to the ``wrapper``\n+  template. This gives you the ability to add attributes to the HTML tag. It\n+  accepts the special ``templateVars`` key to allow the insertion of custom\n+  template variables in the template.\n+- ``$separator`` : An array of attributes for the ``separator`` template.\n+  Possible properties are:\n+\n+    - **separator** The string to be displayed as a separator\n+    - **innerAttrs** To provide attributes in case your separator is divided\n+      in two elements\n+    - **templateVars** Allows the insertion of custom template variable in the\n+      template\n+\n+  All other properties will be converted as HTML attributes and will replace\n+  the **attrs** key in the template. If you use the default for this option\n+  (empty), it will not render a separator.\n+\n+Here is an example of how to render a trail::\n+\n+    echo $this->BreadcrumbsHelper->render(\n+        ['class' => 'breadcrumbs-trail'],\n+        ['separator' => '<i class=\"fa fa-angle-right\"></i>']\n+    );\n+\n+Customizing the output\n+----------------------\n+\n+Customizing the templates\n+~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+The BreadcrumbsHelper internally uses the ``StringTemplateTrait`` which gives\n+the ability to easily customize output of various HTML strings.\n+It includes four templates, with the following default declaration::\n+\n+    [\n+        'wrapper' => '<ul{{attrs}}>{{content}}</ul>',\n+        'item' => '<li{{attrs}}><a href=\"{{url}}\"{{innerAttrs}}>{{title}}</a></li>{{separator}}',\n+        'itemWithoutLink' => '<li{{attrs}}><span{{innerAttrs}}>{{title}}</span></li>{{separator}}',\n+        'separator' => '<li{{attrs}}><span{{innerAttrs}}>{{custom}}{{separator}}</span></li>'\n+    ]\n+\n+You can easily customize them using the ``templates()`` method from the\n+``StringTemplateTrait``::\n+\n+    $this->Breadcrumbs->templates([\n+        'wrapper' => '<nav class=\"breadcrumbs\"><ul{{attrs}}>{{content}}</ul></nav>',\n+    ]);\n+\n+Since your templates will be rendered supporting the ``templateVars``, you can\n+add your own templates var in the various templates::","path":"en/views/helpers/breadcrumbs.rst","position":129,"original_position":129,"commit_id":"0592d5a3fd30e0be7da7fff2dcacd50ba630ace3","original_commit_id":"0592d5a3fd30e0be7da7fff2dcacd50ba630ace3","user":{"login":"ravage84","id":625761,"avatar_url":"https://avatars.githubusercontent.com/u/625761?v=3","gravatar_id":"","url":"https://api.github.com/users/ravage84","html_url":"https://github.com/ravage84","followers_url":"https://api.github.com/users/ravage84/followers","following_url":"https://api.github.com/users/ravage84/following{/other_user}","gists_url":"https://api.github.com/users/ravage84/gists{/gist_id}","starred_url":"https://api.github.com/users/ravage84/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ravage84/subscriptions","organizations_url":"https://api.github.com/users/ravage84/orgs","repos_url":"https://api.github.com/users/ravage84/repos","events_url":"https://api.github.com/users/ravage84/events{/privacy}","received_events_url":"https://api.github.com/users/ravage84/received_events","type":"User","site_admin":false},"body":"\"templates var\" -> \"template variables\"?","created_at":"2016-10-08T00:16:26Z","updated_at":"2016-10-08T00:16:26Z","html_url":"https://github.com/cakephp/docs/pull/4376#discussion_r82489322","pull_request_url":"https://api.github.com/repos/cakephp/docs/pulls/4376","_links":{"self":{"href":"https://api.github.com/repos/cakephp/docs/pulls/comments/82489322"},"html":{"href":"https://github.com/cakephp/docs/pull/4376#discussion_r82489322"},"pull_request":{"href":"https://api.github.com/repos/cakephp/docs/pulls/4376"}}},"pull_request":{"url":"https://api.github.com/repos/cakephp/docs/pulls/4376","id":88522811,"html_url":"https://github.com/cakephp/docs/pull/4376","diff_url":"https://github.com/cakephp/docs/pull/4376.diff","patch_url":"https://github.com/cakephp/docs/pull/4376.patch","issue_url":"https://api.github.com/repos/cakephp/docs/issues/4376","number":4376,"state":"open","locked":false,"title":"BreadcrumbsHelper documentation","user":{"login":"HavokInspiration","id":5243386,"avatar_url":"https://avatars.githubusercontent.com/u/5243386?v=3","gravatar_id":"","url":"https://api.github.com/users/HavokInspiration","html_url":"https://github.com/HavokInspiration","followers_url":"https://api.github.com/users/HavokInspiration/followers","following_url":"https://api.github.com/users/HavokInspiration/following{/other_user}","gists_url":"https://api.github.com/users/HavokInspiration/gists{/gist_id}","starred_url":"https://api.github.com/users/HavokInspiration/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HavokInspiration/subscriptions","organizations_url":"https://api.github.com/users/HavokInspiration/orgs","repos_url":"https://api.github.com/users/HavokInspiration/repos","events_url":"https://api.github.com/users/HavokInspiration/events{/privacy}","received_events_url":"https://api.github.com/users/HavokInspiration/received_events","type":"User","site_admin":false},"body":"This is a first draft for the BreadcrumbsHelper documentation.\r\nThere is most certainly room for improvements (and probably build fixes :smile:)\r\nOnce we have something approved in English, I'll take care of the French translation.\r\n\r\nRefs https://github.com/cakephp/cakephp/pull/9562","created_at":"2016-10-07T23:29:12Z","updated_at":"2016-10-08T00:20:57Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1cd44b8da59f92ab799b5768d98f00f89c9ab63d","assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/cakephp/docs/milestones/1","html_url":"https://github.com/cakephp/docs/milestones/3.x","labels_url":"https://api.github.com/repos/cakephp/docs/milestones/1/labels","id":629438,"number":1,"title":"3.x","description":"","creator":{"login":"markstory","id":24086,"avatar_url":"https://avatars.githubusercontent.com/u/24086?v=3","gravatar_id":"","url":"https://api.github.com/users/markstory","html_url":"https://github.com/markstory","followers_url":"https://api.github.com/users/markstory/followers","following_url":"https://api.github.com/users/markstory/following{/other_user}","gists_url":"https://api.github.com/users/markstory/gists{/gist_id}","starred_url":"https://api.github.com/users/markstory/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/markstory/subscriptions","organizations_url":"https://api.github.com/users/markstory/orgs","repos_url":"https://api.github.com/users/markstory/repos","events_url":"https://api.github.com/users/markstory/events{/privacy}","received_events_url":"https://api.github.com/users/markstory/received_events","type":"User","site_admin":false},"open_issues":31,"closed_issues":1935,"state":"open","created_at":"2014-04-14T15:44:13Z","updated_at":"2016-10-07T23:29:12Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/cakephp/docs/pulls/4376/commits","review_comments_url":"https://api.github.com/repos/cakephp/docs/pulls/4376/comments","review_comment_url":"https://api.github.com/repos/cakephp/docs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cakephp/docs/issues/4376/comments","statuses_url":"https://api.github.com/repos/cakephp/docs/statuses/0592d5a3fd30e0be7da7fff2dcacd50ba630ace3","head":{"label":"cakephp:3.0-breadcrumbs-helper","ref":"3.0-breadcrumbs-helper","sha":"0592d5a3fd30e0be7da7fff2dcacd50ba630ace3","user":{"login":"cakephp","id":23666,"avatar_url":"https://avatars.githubusercontent.com/u/23666?v=3","gravatar_id":"","url":"https://api.github.com/users/cakephp","html_url":"https://github.com/cakephp","followers_url":"https://api.github.com/users/cakephp/followers","following_url":"https://api.github.com/users/cakephp/following{/other_user}","gists_url":"https://api.github.com/users/cakephp/gists{/gist_id}","starred_url":"https://api.github.com/users/cakephp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cakephp/subscriptions","organizations_url":"https://api.github.com/users/cakephp/orgs","repos_url":"https://api.github.com/users/cakephp/repos","events_url":"https://api.github.com/users/cakephp/events{/privacy}","received_events_url":"https://api.github.com/users/cakephp/received_events","type":"Organization","site_admin":false},"repo":{"id":1514950,"name":"docs","full_name":"cakephp/docs","owner":{"login":"cakephp","id":23666,"avatar_url":"https://avatars.githubusercontent.com/u/23666?v=3","gravatar_id":"","url":"https://api.github.com/users/cakephp","html_url":"https://github.com/cakephp","followers_url":"https://api.github.com/users/cakephp/followers","following_url":"https://api.github.com/users/cakephp/following{/other_user}","gists_url":"https://api.github.com/users/cakephp/gists{/gist_id}","starred_url":"https://api.github.com/users/cakephp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cakephp/subscriptions","organizations_url":"https://api.github.com/users/cakephp/orgs","repos_url":"https://api.github.com/users/cakephp/repos","events_url":"https://api.github.com/users/cakephp/events{/privacy}","received_events_url":"https://api.github.com/users/cakephp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cakephp/docs","description":"CakePHP CookBook","fork":false,"url":"https://api.github.com/repos/cakephp/docs","forks_url":"https://api.github.com/repos/cakephp/docs/forks","keys_url":"https://api.github.com/repos/cakephp/docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cakephp/docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cakephp/docs/teams","hooks_url":"https://api.github.com/repos/cakephp/docs/hooks","issue_events_url":"https://api.github.com/repos/cakephp/docs/issues/events{/number}","events_url":"https://api.github.com/repos/cakephp/docs/events","assignees_url":"https://api.github.com/repos/cakephp/docs/assignees{/user}","branches_url":"https://api.github.com/repos/cakephp/docs/branches{/branch}","tags_url":"https://api.github.com/repos/cakephp/docs/tags","blobs_url":"https://api.github.com/repos/cakephp/docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cakephp/docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cakephp/docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/cakephp/docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cakephp/docs/statuses/{sha}","languages_url":"https://api.github.com/repos/cakephp/docs/languages","stargazers_url":"https://api.github.com/repos/cakephp/docs/stargazers","contributors_url":"https://api.github.com/repos/cakephp/docs/contributors","subscribers_url":"https://api.github.com/repos/cakephp/docs/subscribers","subscription_url":"https://api.github.com/repos/cakephp/docs/subscription","commits_url":"https://api.github.com/repos/cakephp/docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/cakephp/docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/cakephp/docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/cakephp/docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/cakephp/docs/contents/{+path}","compare_url":"https://api.github.com/repos/cakephp/docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cakephp/docs/merges","archive_url":"https://api.github.com/repos/cakephp/docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cakephp/docs/downloads","issues_url":"https://api.github.com/repos/cakephp/docs/issues{/number}","pulls_url":"https://api.github.com/repos/cakephp/docs/pulls{/number}","milestones_url":"https://api.github.com/repos/cakephp/docs/milestones{/number}","notifications_url":"https://api.github.com/repos/cakephp/docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cakephp/docs/labels{/name}","releases_url":"https://api.github.com/repos/cakephp/docs/releases{/id}","deployments_url":"https://api.github.com/repos/cakephp/docs/deployments","created_at":"2011-03-23T04:54:13Z","updated_at":"2016-09-28T18:41:20Z","pushed_at":"2016-10-07T23:29:13Z","git_url":"git://github.com/cakephp/docs.git","ssh_url":"git@github.com:cakephp/docs.git","clone_url":"https://github.com/cakephp/docs.git","svn_url":"https://github.com/cakephp/docs","homepage":"http://book.cakephp.org","size":52392,"stargazers_count":540,"watchers_count":540,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2172,"mirror_url":null,"open_issues_count":44,"forks":2172,"open_issues":44,"watchers":540,"default_branch":"3.0"}},"base":{"label":"cakephp:3.0","ref":"3.0","sha":"3f3a80ec4d1a1d500f6169475f86fadddf72a08e","user":{"login":"cakephp","id":23666,"avatar_url":"https://avatars.githubusercontent.com/u/23666?v=3","gravatar_id":"","url":"https://api.github.com/users/cakephp","html_url":"https://github.com/cakephp","followers_url":"https://api.github.com/users/cakephp/followers","following_url":"https://api.github.com/users/cakephp/following{/other_user}","gists_url":"https://api.github.com/users/cakephp/gists{/gist_id}","starred_url":"https://api.github.com/users/cakephp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cakephp/subscriptions","organizations_url":"https://api.github.com/users/cakephp/orgs","repos_url":"https://api.github.com/users/cakephp/repos","events_url":"https://api.github.com/users/cakephp/events{/privacy}","received_events_url":"https://api.github.com/users/cakephp/received_events","type":"Organization","site_admin":false},"repo":{"id":1514950,"name":"docs","full_name":"cakephp/docs","owner":{"login":"cakephp","id":23666,"avatar_url":"https://avatars.githubusercontent.com/u/23666?v=3","gravatar_id":"","url":"https://api.github.com/users/cakephp","html_url":"https://github.com/cakephp","followers_url":"https://api.github.com/users/cakephp/followers","following_url":"https://api.github.com/users/cakephp/following{/other_user}","gists_url":"https://api.github.com/users/cakephp/gists{/gist_id}","starred_url":"https://api.github.com/users/cakephp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cakephp/subscriptions","organizations_url":"https://api.github.com/users/cakephp/orgs","repos_url":"https://api.github.com/users/cakephp/repos","events_url":"https://api.github.com/users/cakephp/events{/privacy}","received_events_url":"https://api.github.com/users/cakephp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cakephp/docs","description":"CakePHP CookBook","fork":false,"url":"https://api.github.com/repos/cakephp/docs","forks_url":"https://api.github.com/repos/cakephp/docs/forks","keys_url":"https://api.github.com/repos/cakephp/docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cakephp/docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cakephp/docs/teams","hooks_url":"https://api.github.com/repos/cakephp/docs/hooks","issue_events_url":"https://api.github.com/repos/cakephp/docs/issues/events{/number}","events_url":"https://api.github.com/repos/cakephp/docs/events","assignees_url":"https://api.github.com/repos/cakephp/docs/assignees{/user}","branches_url":"https://api.github.com/repos/cakephp/docs/branches{/branch}","tags_url":"https://api.github.com/repos/cakephp/docs/tags","blobs_url":"https://api.github.com/repos/cakephp/docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cakephp/docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cakephp/docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/cakephp/docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cakephp/docs/statuses/{sha}","languages_url":"https://api.github.com/repos/cakephp/docs/languages","stargazers_url":"https://api.github.com/repos/cakephp/docs/stargazers","contributors_url":"https://api.github.com/repos/cakephp/docs/contributors","subscribers_url":"https://api.github.com/repos/cakephp/docs/subscribers","subscription_url":"https://api.github.com/repos/cakephp/docs/subscription","commits_url":"https://api.github.com/repos/cakephp/docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/cakephp/docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/cakephp/docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/cakephp/docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/cakephp/docs/contents/{+path}","compare_url":"https://api.github.com/repos/cakephp/docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cakephp/docs/merges","archive_url":"https://api.github.com/repos/cakephp/docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cakephp/docs/downloads","issues_url":"https://api.github.com/repos/cakephp/docs/issues{/number}","pulls_url":"https://api.github.com/repos/cakephp/docs/pulls{/number}","milestones_url":"https://api.github.com/repos/cakephp/docs/milestones{/number}","notifications_url":"https://api.github.com/repos/cakephp/docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cakephp/docs/labels{/name}","releases_url":"https://api.github.com/repos/cakephp/docs/releases{/id}","deployments_url":"https://api.github.com/repos/cakephp/docs/deployments","created_at":"2011-03-23T04:54:13Z","updated_at":"2016-09-28T18:41:20Z","pushed_at":"2016-10-07T23:29:13Z","git_url":"git://github.com/cakephp/docs.git","ssh_url":"git@github.com:cakephp/docs.git","clone_url":"https://github.com/cakephp/docs.git","svn_url":"https://github.com/cakephp/docs","homepage":"http://book.cakephp.org","size":52392,"stargazers_count":540,"watchers_count":540,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":2172,"mirror_url":null,"open_issues_count":44,"forks":2172,"open_issues":44,"watchers":540,"default_branch":"3.0"}},"_links":{"self":{"href":"https://api.github.com/repos/cakephp/docs/pulls/4376"},"html":{"href":"https://github.com/cakephp/docs/pull/4376"},"issue":{"href":"https://api.github.com/repos/cakephp/docs/issues/4376"},"comments":{"href":"https://api.github.com/repos/cakephp/docs/issues/4376/comments"},"review_comments":{"href":"https://api.github.com/repos/cakephp/docs/pulls/4376/comments"},"review_comment":{"href":"https://api.github.com/repos/cakephp/docs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cakephp/docs/pulls/4376/commits"},"statuses":{"href":"https://api.github.com/repos/cakephp/docs/statuses/0592d5a3fd30e0be7da7fff2dcacd50ba630ace3"}}}}
{"actor":{"display_login":"ravage84"}}