Skip to main content
added 6 characters in body
Source Link
No Sssweat
  • 31.6k
  • 14
  • 55
  • 91

I have a view called customfeedview showing contents of a content type viz. customfeeds. View Setting are given in the picture below: View Settings I created views-view--customfeedview.html.twig to customize the view. Code of the file is given here under.

        <div class="box prog">
            <div class="col-md-3"><img src="{{directory}}/images/2000px-Lotus_position.svg.png" ></div>
            <div class="col-md-9">
                    <h3><b>{{ fields.title.content }} </b></h3>
                        <p>{{ fields.body.content }} </p>
            </div>
      </div>

But {{ fields.body.content }}{{ fields.body.content }} & {{ fields.title.content }}{{ fields.title.content }} does not render title and body of the contents of type customfeed.

Please help me in this issue as I am totally a beginner in drupal 8. Thank you...

N.B.: Here I am using show-type content instead of fields as only show-type content only give read-more option in the view page. Using show-type fields {{ fields.body.content }}{{ fields.body.content }} is working fine but whenever I changed it to content {{ fields.body.content }}{{ fields.body.content }} is not rendering the values.

I have a view called customfeedview showing contents of a content type viz. customfeeds. View Setting are given in the picture below: View Settings I created views-view--customfeedview.html.twig to customize the view. Code of the file is given here under.

        <div class="box prog">
            <div class="col-md-3"><img src="{{directory}}/images/2000px-Lotus_position.svg.png" ></div>
            <div class="col-md-9">
                    <h3><b>{{ fields.title.content }} </b></h3>
                        <p>{{ fields.body.content }} </p>
            </div>
      </div>

But {{ fields.body.content }} & {{ fields.title.content }} does not render title and body of the contents of type customfeed.

Please help me in this issue as I am totally a beginner in drupal 8. Thank you...

N.B.: Here I am using show-type content instead of fields as only show-type content only give read-more option in the view page. Using show-type fields {{ fields.body.content }} is working fine but whenever I changed it to content {{ fields.body.content }} is not rendering the values.

I have a view called customfeedview showing contents of a content type viz. customfeeds. View Setting are given in the picture below: View Settings I created views-view--customfeedview.html.twig to customize the view. Code of the file is given here under.

        <div class="box prog">
            <div class="col-md-3"><img src="{{directory}}/images/2000px-Lotus_position.svg.png" ></div>
            <div class="col-md-9">
                    <h3><b>{{ fields.title.content }} </b></h3>
                        <p>{{ fields.body.content }} </p>
            </div>
      </div>

But {{ fields.body.content }} & {{ fields.title.content }} does not render title and body of the contents of type customfeed.

Please help me in this issue as I am totally a beginner in drupal 8. Thank you...

N.B.: Here I am using show-type content instead of fields as only show-type content only give read-more option in the view page. Using show-type fields {{ fields.body.content }} is working fine but whenever I changed it to content {{ fields.body.content }} is not rendering the values.

N.B. is added
Source Link

I have a view called customfeedview showing contents of a content type viz. customfeeds. View Setting are given in the picture below: View Settings I created views-view--customfeedview.html.twig to customize the view. Code of the file is given here under.

        <div class="box prog">
            <div class="col-md-3"><img src="{{directory}}/images/2000px-Lotus_position.svg.png" ></div>
            <div class="col-md-9">
                    <h3><b>{{ fields.title.content }} </b></h3>
                        <p>{{ fields.body.content }} </p>
            </div>
      </div>

But {{ fields.body.content }} & {{ fields.title.content }} does not render title and body of the contents of type customfeed.

Please help me in this issue as I am totally a beginner in drupal 8. Thank you...

N.B.: Here I am using show-type content instead of fields as only show-type content only give read-more option in the view page. Using show-type fields {{ fields.body.content }} is working fine but whenever I changed it to content {{ fields.body.content }} is not rendering the values.

I have a view called customfeedview showing contents of a content type viz. customfeeds. View Setting are given in the picture below: View Settings I created views-view--customfeedview.html.twig to customize the view. Code of the file is given here under.

        <div class="box prog">
            <div class="col-md-3"><img src="{{directory}}/images/2000px-Lotus_position.svg.png" ></div>
            <div class="col-md-9">
                    <h3><b>{{ fields.title.content }} </b></h3>
                        <p>{{ fields.body.content }} </p>
            </div>
      </div>

But {{ fields.body.content }} & {{ fields.title.content }} does not render title and body of the contents of type customfeed.

Please help me in this issue as I am totally a beginner in drupal 8. Thank you...

I have a view called customfeedview showing contents of a content type viz. customfeeds. View Setting are given in the picture below: View Settings I created views-view--customfeedview.html.twig to customize the view. Code of the file is given here under.

        <div class="box prog">
            <div class="col-md-3"><img src="{{directory}}/images/2000px-Lotus_position.svg.png" ></div>
            <div class="col-md-9">
                    <h3><b>{{ fields.title.content }} </b></h3>
                        <p>{{ fields.body.content }} </p>
            </div>
      </div>

But {{ fields.body.content }} & {{ fields.title.content }} does not render title and body of the contents of type customfeed.

Please help me in this issue as I am totally a beginner in drupal 8. Thank you...

N.B.: Here I am using show-type content instead of fields as only show-type content only give read-more option in the view page. Using show-type fields {{ fields.body.content }} is working fine but whenever I changed it to content {{ fields.body.content }} is not rendering the values.

Source Link

Render node fields in the views-view--[view_machine_name].html.twig

I have a view called customfeedview showing contents of a content type viz. customfeeds. View Setting are given in the picture below: View Settings I created views-view--customfeedview.html.twig to customize the view. Code of the file is given here under.

        <div class="box prog">
            <div class="col-md-3"><img src="{{directory}}/images/2000px-Lotus_position.svg.png" ></div>
            <div class="col-md-9">
                    <h3><b>{{ fields.title.content }} </b></h3>
                        <p>{{ fields.body.content }} </p>
            </div>
      </div>

But {{ fields.body.content }} & {{ fields.title.content }} does not render title and body of the contents of type customfeed.

Please help me in this issue as I am totally a beginner in drupal 8. Thank you...