|
|
@ -102,12 +102,12 @@ Within that template the following structure is needed: |
|
|
|
{{ $dataJ := getJSON $location }} |
|
|
|
{{ $dataJ := getJSON $location }} |
|
|
|
{{ range $dataJ.comments }} |
|
|
|
{{ range $dataJ.comments }} |
|
|
|
{# HTML and template codes here #} |
|
|
|
{# HTML and template codes here #} |
|
|
|
{{ end }} |
|
|
|
|
|
|
|
{# This is to display replies to this comment, you can use them same variables #} |
|
|
|
{# This is to display replies to this comment, you can use them same variables #} |
|
|
|
{{ range where $dataJ.replies "replied_to" .comment_id }} |
|
|
|
{{ range where $dataJ.replies "replied_to" .comment_id }} |
|
|
|
{# HTML and template codes here for replies #} |
|
|
|
{# HTML and template codes here for replies #} |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
{{ end }} |
|
|
|
{{ end }} |
|
|
|
|
|
|
|
{{ end }} |
|
|
|
``` |
|
|
|
``` |
|
|
|
|
|
|
|
|
|
|
|
This loads the json depending on the rel url and walks the list of comments. You can then use the following variables to |
|
|
|
This loads the json depending on the rel url and walks the list of comments. You can then use the following variables to |
|
|
|