For assistance with theme development.

I want to migrate my WordPress to Drupal

Hi,

I'm the owner of https://www.appsmedian.com and I want to migrate my site to Drupal. I'm interested in create a template that it is very similar to the current template. Somebody know if there is easy way to convert a WordPress template to Drupal template?

Thanks in advance

Printing views field raw value from twig template

I have a view that pulls in fields from a content type. I am trying to print only the raw value of one of the fields. Since there doesn't appear to be any clear documentation on how to do this anywhere, I am forced to ask here. 

I have a views-view-field--field-name.html.twig template file. I have tried multiple things to get the field to render, and aside from using {{ output -}} nothing works. 

Things I have tried. 

{{ field.field_name.value }}

{{ field.field_name.value|raw }}

{{ field.field_name.content }}

{{ field.field_name.content|raw }}

How to display field_tags of a node in html.html.twig?

I want to display Field "field_summary" and "field_tags" of a node in html.html.twig (without using a module for that) as metatags. I was already able to get "field_summary" value in html.html.twig with this code:

Site-wide background image and header image for MAYO for 8.x

Hello,

I have the MAYO theme installed am using a subMayo creation. According to the MAYO Theme write-up, it does everything that I want it to do. The problem I have is HOW? Is there an interface that I'm missing somewhere? Do I need to make all of my changes in the .css files? Is there a documentation file somewhere that actually has some information?

At this point, I just want to change the header image (keeping the logo.png image intact) and create a site-wide background image.

Any assistance would be greatly appreciated,

Error after adding .theme file

After creating .theme file in my template folder (whether empty or not), I get the following error message:

Checking the field for completeness

I am trying to check the field for completeness and if there is a loaded video in the field, display a small icon on the preview layer. doing so:

<?php if(!empty($fields['field_video'])) echo '<div class="ribbon-wrapper-gold"><div class="ribbon-gold">with video</div></div>'; ?> 

But with video always appears regardless of whether the field_video field is filled or not. What am I doing wrong?

Pages

Subscribe with RSS Subscribe to RSS - Theme development