Skip to content

Instantly share code, notes, and snippets.

@nicmare
Created October 1, 2025 11:58
Show Gist options
  • Select an option

  • Save nicmare/9af6377b3f995904f81c5981dccc8d91 to your computer and use it in GitHub Desktop.

Select an option

Save nicmare/9af6377b3f995904f81c5981dccc8d91 to your computer and use it in GitHub Desktop.

Revisions

  1. nicmare created this gist Oct 1, 2025.
    8 changes: 8 additions & 0 deletions functions.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,8 @@
    <?php
    function change_layer_from_card($layer,$prefix,$image_args){
    if($prefix != "unterstuetzer_archive") return $layer;
    $layer["featured_image"] = sprintf('<div class="ct-media-container">%s</div>',strip_tags($layer["featured_image"],"<img>"));
    $layer["title"] = strip_tags($layer["title"],"<h2>");
    return $layer;
    }
    add_filter('blocksy:archive:render-card-layers',"change_layer_from_card",10,3);