Can someone help how to solve this issue?
I have following html code:
Can some tell How can I fix this table in a proper way so that all headers should align with table data
<div class="article-list container">
<table cellpadding="5px" cellspacing="5px" border="1" bgcolor="lightgreen">
<tbody>
<tr>
<th>User Id</th>
<th>Title</th>
<th>Body</th>
<th>Author</th>
<th>Editor</th>
<th>Created Date</th>
<th>Actions</th>
</tr>
<tr *ngFor="let items of article_array_keys" class="structure">
<p *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</p>
</tr>
</tbody>
and this is the api data from backend:
["id":8,"title":"Hello data updated even now","body":"Ducimus et repellendus eveniet ab nihil labore. Autem in nulla vel rerum sit ut omnis. Nulla est sunt minus. Dolores sapiente totam consequuntur omnis officiis voluptas ut.","author":"Velda Lemke","editor":"Sadie Schmidt IV","active":1,"created_at":"2018-09-04 11:27:22","updated_at":"2018-11-06 10:31:11"]
I am using this code in subscribing service in the component:
this.serv_article_list.getFullArticleList(this.article_resource['request_type'], this.article_resource)
.subscribe(
(article_list_data: any) =>
console.log(article_list_data);
this.article_array_keys = Array.of(article_list_data);//Object.keys(article_list_data)
// this.article_array_values = Object.values(article_list_data)
);
Can some tell How can I fix this table in a proper way so that all headers should align with table data
note: Whenever I use an extra tag such as div
or ```span`` inside/outside a tag it is disturbing the table.
may I be not sure how really a table works with other tags embedded? but they work fine with static HTML code.
SS is attached showing improper formatted table
I want to achive in this way:
this is the code access github link:
https://github.com/ROHAN-TANDEL/ng7
angular html5
add a comment |
I have following html code:
Can some tell How can I fix this table in a proper way so that all headers should align with table data
<div class="article-list container">
<table cellpadding="5px" cellspacing="5px" border="1" bgcolor="lightgreen">
<tbody>
<tr>
<th>User Id</th>
<th>Title</th>
<th>Body</th>
<th>Author</th>
<th>Editor</th>
<th>Created Date</th>
<th>Actions</th>
</tr>
<tr *ngFor="let items of article_array_keys" class="structure">
<p *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</p>
</tr>
</tbody>
and this is the api data from backend:
["id":8,"title":"Hello data updated even now","body":"Ducimus et repellendus eveniet ab nihil labore. Autem in nulla vel rerum sit ut omnis. Nulla est sunt minus. Dolores sapiente totam consequuntur omnis officiis voluptas ut.","author":"Velda Lemke","editor":"Sadie Schmidt IV","active":1,"created_at":"2018-09-04 11:27:22","updated_at":"2018-11-06 10:31:11"]
I am using this code in subscribing service in the component:
this.serv_article_list.getFullArticleList(this.article_resource['request_type'], this.article_resource)
.subscribe(
(article_list_data: any) =>
console.log(article_list_data);
this.article_array_keys = Array.of(article_list_data);//Object.keys(article_list_data)
// this.article_array_values = Object.values(article_list_data)
);
Can some tell How can I fix this table in a proper way so that all headers should align with table data
note: Whenever I use an extra tag such as div
or ```span`` inside/outside a tag it is disturbing the table.
may I be not sure how really a table works with other tags embedded? but they work fine with static HTML code.
SS is attached showing improper formatted table
I want to achive in this way:
this is the code access github link:
https://github.com/ROHAN-TANDEL/ng7
angular html5
anyone looking for a quick look refer @Rahul Swamynathan 's answer
– Krishnan Rohan
Nov 14 at 5:29
add a comment |
I have following html code:
Can some tell How can I fix this table in a proper way so that all headers should align with table data
<div class="article-list container">
<table cellpadding="5px" cellspacing="5px" border="1" bgcolor="lightgreen">
<tbody>
<tr>
<th>User Id</th>
<th>Title</th>
<th>Body</th>
<th>Author</th>
<th>Editor</th>
<th>Created Date</th>
<th>Actions</th>
</tr>
<tr *ngFor="let items of article_array_keys" class="structure">
<p *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</p>
</tr>
</tbody>
and this is the api data from backend:
["id":8,"title":"Hello data updated even now","body":"Ducimus et repellendus eveniet ab nihil labore. Autem in nulla vel rerum sit ut omnis. Nulla est sunt minus. Dolores sapiente totam consequuntur omnis officiis voluptas ut.","author":"Velda Lemke","editor":"Sadie Schmidt IV","active":1,"created_at":"2018-09-04 11:27:22","updated_at":"2018-11-06 10:31:11"]
I am using this code in subscribing service in the component:
this.serv_article_list.getFullArticleList(this.article_resource['request_type'], this.article_resource)
.subscribe(
(article_list_data: any) =>
console.log(article_list_data);
this.article_array_keys = Array.of(article_list_data);//Object.keys(article_list_data)
// this.article_array_values = Object.values(article_list_data)
);
Can some tell How can I fix this table in a proper way so that all headers should align with table data
note: Whenever I use an extra tag such as div
or ```span`` inside/outside a tag it is disturbing the table.
may I be not sure how really a table works with other tags embedded? but they work fine with static HTML code.
SS is attached showing improper formatted table
I want to achive in this way:
this is the code access github link:
https://github.com/ROHAN-TANDEL/ng7
angular html5
I have following html code:
Can some tell How can I fix this table in a proper way so that all headers should align with table data
<div class="article-list container">
<table cellpadding="5px" cellspacing="5px" border="1" bgcolor="lightgreen">
<tbody>
<tr>
<th>User Id</th>
<th>Title</th>
<th>Body</th>
<th>Author</th>
<th>Editor</th>
<th>Created Date</th>
<th>Actions</th>
</tr>
<tr *ngFor="let items of article_array_keys" class="structure">
<p *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</p>
</tr>
</tbody>
and this is the api data from backend:
["id":8,"title":"Hello data updated even now","body":"Ducimus et repellendus eveniet ab nihil labore. Autem in nulla vel rerum sit ut omnis. Nulla est sunt minus. Dolores sapiente totam consequuntur omnis officiis voluptas ut.","author":"Velda Lemke","editor":"Sadie Schmidt IV","active":1,"created_at":"2018-09-04 11:27:22","updated_at":"2018-11-06 10:31:11"]
I am using this code in subscribing service in the component:
this.serv_article_list.getFullArticleList(this.article_resource['request_type'], this.article_resource)
.subscribe(
(article_list_data: any) =>
console.log(article_list_data);
this.article_array_keys = Array.of(article_list_data);//Object.keys(article_list_data)
// this.article_array_values = Object.values(article_list_data)
);
Can some tell How can I fix this table in a proper way so that all headers should align with table data
note: Whenever I use an extra tag such as div
or ```span`` inside/outside a tag it is disturbing the table.
may I be not sure how really a table works with other tags embedded? but they work fine with static HTML code.
SS is attached showing improper formatted table
I want to achive in this way:
this is the code access github link:
https://github.com/ROHAN-TANDEL/ng7
angular html5
angular html5
edited Nov 12 at 14:31
asked Nov 12 at 14:11
Krishnan Rohan
85
85
anyone looking for a quick look refer @Rahul Swamynathan 's answer
– Krishnan Rohan
Nov 14 at 5:29
add a comment |
anyone looking for a quick look refer @Rahul Swamynathan 's answer
– Krishnan Rohan
Nov 14 at 5:29
anyone looking for a quick look refer @Rahul Swamynathan 's answer
– Krishnan Rohan
Nov 14 at 5:29
anyone looking for a quick look refer @Rahul Swamynathan 's answer
– Krishnan Rohan
Nov 14 at 5:29
add a comment |
3 Answers
3
active
oldest
votes
It would appear as though your table is being malformed because each table row is only being given one child element
Change your HTML to
<tr *ngFor="let items of article_array_keys" class="structure">
<ng-container *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</ng-container>
</tr>
Thanks, that worked out butng-container
has to beoutside
andtr
should be itschild
.
– Krishnan Rohan
Nov 12 at 14:26
add a comment |
There are gaps in the code you provided but judging from the json you pasted, the data is an array while in your template, you are making two ngFor
as if you had an array of arrays.
Just set the article_list_data
to a property on your component and iterate over it:
<tr *ngFor="let item of article_list_data" class="structure">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
Edit: To display the content of article_list_data
as available inside the HTML template, use <pre> article_list_data </pre>
.
Judging from your code, Array.Of(x)
creates an array with a first value x
. So you end up with an [[...]]
which is the reason why you need a nested ngFor
.
Remove the Array.of
:
this.serv...getFullArticleList(...)
.subscribe((article_list_data: any) =>
this.article_list_data = article_list_data;
);
Then directly use it.
I tried that way but does not work outthere is no output at all. BTW I printed just after subscribing the
article_list_data``` for typeof it's showing me as an Object in the console.
– Krishnan Rohan
Nov 12 at 14:20
@KrishnanRohan To see the record in your template, use<pre> article_array_keys </pre>
. That will show you the content of your variable then you will be able to judge on what to do with it from thehtml
template.
– Kimserey Lam
Nov 12 at 14:25
it seems helpful I will try with these technique
– Krishnan Rohan
Nov 14 at 5:26
add a comment |
Try like this
<ng-container *ngFor="let items of article_array_keys" class="structure">
<tr *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
</ng-container>
Hope this works - happy coding!!
@peinearydevelopment has given me the hint, and I got my desired result. BTW your answer reflects exactly what I have done with my code.
– Krishnan Rohan
Nov 14 at 5:28
Okay no issues - i didn't see your comments on his answer - if you got the answer then its fine - just proposed the way to achieve the scenario :) Happy coding
– Rahul
Nov 14 at 5:42
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53263941%2fcan-someone-help-how-to-solve-this-issue%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
It would appear as though your table is being malformed because each table row is only being given one child element
Change your HTML to
<tr *ngFor="let items of article_array_keys" class="structure">
<ng-container *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</ng-container>
</tr>
Thanks, that worked out butng-container
has to beoutside
andtr
should be itschild
.
– Krishnan Rohan
Nov 12 at 14:26
add a comment |
It would appear as though your table is being malformed because each table row is only being given one child element
Change your HTML to
<tr *ngFor="let items of article_array_keys" class="structure">
<ng-container *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</ng-container>
</tr>
Thanks, that worked out butng-container
has to beoutside
andtr
should be itschild
.
– Krishnan Rohan
Nov 12 at 14:26
add a comment |
It would appear as though your table is being malformed because each table row is only being given one child element
Change your HTML to
<tr *ngFor="let items of article_array_keys" class="structure">
<ng-container *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</ng-container>
</tr>
It would appear as though your table is being malformed because each table row is only being given one child element
Change your HTML to
<tr *ngFor="let items of article_array_keys" class="structure">
<ng-container *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</ng-container>
</tr>
answered Nov 12 at 14:17
peinearydevelopment
4,10742246
4,10742246
Thanks, that worked out butng-container
has to beoutside
andtr
should be itschild
.
– Krishnan Rohan
Nov 12 at 14:26
add a comment |
Thanks, that worked out butng-container
has to beoutside
andtr
should be itschild
.
– Krishnan Rohan
Nov 12 at 14:26
Thanks, that worked out but
ng-container
has to be outside
and tr
should be its child
.– Krishnan Rohan
Nov 12 at 14:26
Thanks, that worked out but
ng-container
has to be outside
and tr
should be its child
.– Krishnan Rohan
Nov 12 at 14:26
add a comment |
There are gaps in the code you provided but judging from the json you pasted, the data is an array while in your template, you are making two ngFor
as if you had an array of arrays.
Just set the article_list_data
to a property on your component and iterate over it:
<tr *ngFor="let item of article_list_data" class="structure">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
Edit: To display the content of article_list_data
as available inside the HTML template, use <pre> article_list_data </pre>
.
Judging from your code, Array.Of(x)
creates an array with a first value x
. So you end up with an [[...]]
which is the reason why you need a nested ngFor
.
Remove the Array.of
:
this.serv...getFullArticleList(...)
.subscribe((article_list_data: any) =>
this.article_list_data = article_list_data;
);
Then directly use it.
I tried that way but does not work outthere is no output at all. BTW I printed just after subscribing the
article_list_data``` for typeof it's showing me as an Object in the console.
– Krishnan Rohan
Nov 12 at 14:20
@KrishnanRohan To see the record in your template, use<pre> article_array_keys </pre>
. That will show you the content of your variable then you will be able to judge on what to do with it from thehtml
template.
– Kimserey Lam
Nov 12 at 14:25
it seems helpful I will try with these technique
– Krishnan Rohan
Nov 14 at 5:26
add a comment |
There are gaps in the code you provided but judging from the json you pasted, the data is an array while in your template, you are making two ngFor
as if you had an array of arrays.
Just set the article_list_data
to a property on your component and iterate over it:
<tr *ngFor="let item of article_list_data" class="structure">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
Edit: To display the content of article_list_data
as available inside the HTML template, use <pre> article_list_data </pre>
.
Judging from your code, Array.Of(x)
creates an array with a first value x
. So you end up with an [[...]]
which is the reason why you need a nested ngFor
.
Remove the Array.of
:
this.serv...getFullArticleList(...)
.subscribe((article_list_data: any) =>
this.article_list_data = article_list_data;
);
Then directly use it.
I tried that way but does not work outthere is no output at all. BTW I printed just after subscribing the
article_list_data``` for typeof it's showing me as an Object in the console.
– Krishnan Rohan
Nov 12 at 14:20
@KrishnanRohan To see the record in your template, use<pre> article_array_keys </pre>
. That will show you the content of your variable then you will be able to judge on what to do with it from thehtml
template.
– Kimserey Lam
Nov 12 at 14:25
it seems helpful I will try with these technique
– Krishnan Rohan
Nov 14 at 5:26
add a comment |
There are gaps in the code you provided but judging from the json you pasted, the data is an array while in your template, you are making two ngFor
as if you had an array of arrays.
Just set the article_list_data
to a property on your component and iterate over it:
<tr *ngFor="let item of article_list_data" class="structure">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
Edit: To display the content of article_list_data
as available inside the HTML template, use <pre> article_list_data </pre>
.
Judging from your code, Array.Of(x)
creates an array with a first value x
. So you end up with an [[...]]
which is the reason why you need a nested ngFor
.
Remove the Array.of
:
this.serv...getFullArticleList(...)
.subscribe((article_list_data: any) =>
this.article_list_data = article_list_data;
);
Then directly use it.
There are gaps in the code you provided but judging from the json you pasted, the data is an array while in your template, you are making two ngFor
as if you had an array of arrays.
Just set the article_list_data
to a property on your component and iterate over it:
<tr *ngFor="let item of article_list_data" class="structure">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
Edit: To display the content of article_list_data
as available inside the HTML template, use <pre> article_list_data </pre>
.
Judging from your code, Array.Of(x)
creates an array with a first value x
. So you end up with an [[...]]
which is the reason why you need a nested ngFor
.
Remove the Array.of
:
this.serv...getFullArticleList(...)
.subscribe((article_list_data: any) =>
this.article_list_data = article_list_data;
);
Then directly use it.
edited Nov 12 at 14:33
answered Nov 12 at 14:15
Kimserey Lam
9314
9314
I tried that way but does not work outthere is no output at all. BTW I printed just after subscribing the
article_list_data``` for typeof it's showing me as an Object in the console.
– Krishnan Rohan
Nov 12 at 14:20
@KrishnanRohan To see the record in your template, use<pre> article_array_keys </pre>
. That will show you the content of your variable then you will be able to judge on what to do with it from thehtml
template.
– Kimserey Lam
Nov 12 at 14:25
it seems helpful I will try with these technique
– Krishnan Rohan
Nov 14 at 5:26
add a comment |
I tried that way but does not work outthere is no output at all. BTW I printed just after subscribing the
article_list_data``` for typeof it's showing me as an Object in the console.
– Krishnan Rohan
Nov 12 at 14:20
@KrishnanRohan To see the record in your template, use<pre> article_array_keys </pre>
. That will show you the content of your variable then you will be able to judge on what to do with it from thehtml
template.
– Kimserey Lam
Nov 12 at 14:25
it seems helpful I will try with these technique
– Krishnan Rohan
Nov 14 at 5:26
I tried that way but does not work out
there is no output at all. BTW I printed just after subscribing the
article_list_data``` for typeof it's showing me as an Object in the console.– Krishnan Rohan
Nov 12 at 14:20
I tried that way but does not work out
there is no output at all. BTW I printed just after subscribing the
article_list_data``` for typeof it's showing me as an Object in the console.– Krishnan Rohan
Nov 12 at 14:20
@KrishnanRohan To see the record in your template, use
<pre> article_array_keys </pre>
. That will show you the content of your variable then you will be able to judge on what to do with it from the html
template.– Kimserey Lam
Nov 12 at 14:25
@KrishnanRohan To see the record in your template, use
<pre> article_array_keys </pre>
. That will show you the content of your variable then you will be able to judge on what to do with it from the html
template.– Kimserey Lam
Nov 12 at 14:25
it seems helpful I will try with these technique
– Krishnan Rohan
Nov 14 at 5:26
it seems helpful I will try with these technique
– Krishnan Rohan
Nov 14 at 5:26
add a comment |
Try like this
<ng-container *ngFor="let items of article_array_keys" class="structure">
<tr *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
</ng-container>
Hope this works - happy coding!!
@peinearydevelopment has given me the hint, and I got my desired result. BTW your answer reflects exactly what I have done with my code.
– Krishnan Rohan
Nov 14 at 5:28
Okay no issues - i didn't see your comments on his answer - if you got the answer then its fine - just proposed the way to achieve the scenario :) Happy coding
– Rahul
Nov 14 at 5:42
add a comment |
Try like this
<ng-container *ngFor="let items of article_array_keys" class="structure">
<tr *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
</ng-container>
Hope this works - happy coding!!
@peinearydevelopment has given me the hint, and I got my desired result. BTW your answer reflects exactly what I have done with my code.
– Krishnan Rohan
Nov 14 at 5:28
Okay no issues - i didn't see your comments on his answer - if you got the answer then its fine - just proposed the way to achieve the scenario :) Happy coding
– Rahul
Nov 14 at 5:42
add a comment |
Try like this
<ng-container *ngFor="let items of article_array_keys" class="structure">
<tr *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
</ng-container>
Hope this works - happy coding!!
Try like this
<ng-container *ngFor="let items of article_array_keys" class="structure">
<tr *ngFor="let item of items">
<td><h5> item.id </h5></td>
<td><h5> item.title </h5></td>
<td><h5> item.body </h5></td>
<td><h5> item.author </h5></td>
<td><h5> item.editor </h5></td>
<td><h5> item.created_at </h5></td>
</tr>
</ng-container>
Hope this works - happy coding!!
answered Nov 12 at 15:11
Rahul
9631315
9631315
@peinearydevelopment has given me the hint, and I got my desired result. BTW your answer reflects exactly what I have done with my code.
– Krishnan Rohan
Nov 14 at 5:28
Okay no issues - i didn't see your comments on his answer - if you got the answer then its fine - just proposed the way to achieve the scenario :) Happy coding
– Rahul
Nov 14 at 5:42
add a comment |
@peinearydevelopment has given me the hint, and I got my desired result. BTW your answer reflects exactly what I have done with my code.
– Krishnan Rohan
Nov 14 at 5:28
Okay no issues - i didn't see your comments on his answer - if you got the answer then its fine - just proposed the way to achieve the scenario :) Happy coding
– Rahul
Nov 14 at 5:42
@peinearydevelopment has given me the hint, and I got my desired result. BTW your answer reflects exactly what I have done with my code.
– Krishnan Rohan
Nov 14 at 5:28
@peinearydevelopment has given me the hint, and I got my desired result. BTW your answer reflects exactly what I have done with my code.
– Krishnan Rohan
Nov 14 at 5:28
Okay no issues - i didn't see your comments on his answer - if you got the answer then its fine - just proposed the way to achieve the scenario :) Happy coding
– Rahul
Nov 14 at 5:42
Okay no issues - i didn't see your comments on his answer - if you got the answer then its fine - just proposed the way to achieve the scenario :) Happy coding
– Rahul
Nov 14 at 5:42
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53263941%2fcan-someone-help-how-to-solve-this-issue%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
anyone looking for a quick look refer @Rahul Swamynathan 's answer
– Krishnan Rohan
Nov 14 at 5:29