{"action":"opened","issue":{"url":"https://api.github.com/repos/symfony/symfony/issues/13368","labels_url":"https://api.github.com/repos/symfony/symfony/issues/13368/labels{/name}","comments_url":"https://api.github.com/repos/symfony/symfony/issues/13368/comments","events_url":"https://api.github.com/repos/symfony/symfony/issues/13368/events","html_url":"https://github.com/symfony/symfony/issues/13368","id":53996439,"number":13368,"title":"[Console][Table] Add support for colspan/rowspan","user":{"login":"tomzx","id":188960,"avatar_url":"https://avatars.githubusercontent.com/u/188960?v=3","gravatar_id":"","url":"https://api.github.com/users/tomzx","html_url":"https://github.com/tomzx","followers_url":"https://api.github.com/users/tomzx/followers","following_url":"https://api.github.com/users/tomzx/following{/other_user}","gists_url":"https://api.github.com/users/tomzx/gists{/gist_id}","starred_url":"https://api.github.com/users/tomzx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tomzx/subscriptions","organizations_url":"https://api.github.com/users/tomzx/orgs","repos_url":"https://api.github.com/users/tomzx/repos","events_url":"https://api.github.com/users/tomzx/events{/privacy}","received_events_url":"https://api.github.com/users/tomzx/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-01-11T16:33:38Z","updated_at":"2015-01-11T16:33:38Z","closed_at":null,"body":"Much like an HTML table, it would be nice to be able to specify colspan/rowspan on the data of the table.\r\n\r\nMy suggestion on how the users would use it is as follow:\r\n\r\nTo specify a `colspan`/`rowspan`other than 1 (default), the user calls `addRow`/`addRows`/`setRow`/`setRows` with a new parameter `$options`. The `$options` parameter is an array where the key is the row cell number and the value is an array of properties that apply to that cell. In this case, `colspan` and `rowspan`.\r\n\r\n```php\r\n$table->addRow(['data', 'data', 'data']);\r\n$table->addRow(['data', 'data'], [\r\n\t0 => [\r\n\t\t'colspan' => 2,\r\n\t],\r\n\t2 => [\r\n\t\t'rowspan' => 3,\r\n\t],\r\n]);\r\n$table->addRow(['', '']);\r\n$table->addRow(['', '']);\r\n```\r\n\r\n```\r\n+------+------+------+\r\n| data | data | data |\r\n+------+------+------+\r\n| data        |      |\r\n+-------------+      +\r\n|             | data |\r\n+-------------+      +\r\n|             |      |\r\n+-------------+------+\r\n```"}}