news_latest.html5 anpassen $this->linkHeadline
Hallo,
ich brauche gerade den Stupser in die richtige Richtung.
ich passe das template news_latest.html5 an und möchte darin auch das Bild mit dem <a> tag abgreifen. Ich kann aber nicht herausfinden, wie und wo die url dafür "erzeugt" wird.
Im Grunde ist es ja die gleiche url die aus $this->linkHeadline und $this->more erzeugt wird.
Aber für beide finde ich nicht heraus, wie ich den <a>-tag nun "ausschreiben" kann.
$this->url oder $this->href ist's nicht ...
HTML-Code:
div class="layout_latest row arc_<?= $this->archive->id ?> block<?= $this->class ?>" itemscope itemtype="http://schema.org/Article">
<div class="image-block col-3">
<figure class="image_container "<?php if ($this->margin): ?> style="<?=$this->margin ?>""<?php endif; ?>>
<?php if ($this->href): ?>
<a href="<?= $this->href ?>"<?= $this->attributes ?> title="<?= $this->alt ?>">
<?php endif; ?>
<?php $this->insert('picture_default', $this->picture); ?>
<?php if ($this->href): ?>
</a>
<?php endif; ?>
<?php if ($this->caption): ?>
<figcaption class="caption"><?= $this->caption ?></figcaption>
<?php endif; ?>
</figure>
</div>
<div class="info-block-wrapper col-9">
<div class="info-block">
<?php if ($this->hasMetaFields): ?>
<p class="info">
<span>erstellt am </span>
<span><?php echo $this->parseDate("d.m.Y", $this->timestamp); ?></span>
<span><?= $this->author ?></span>
</p>
<?php endif; ?>
</div>
<h2 itemprop="name"><?= $this->linkHeadline ?></h2>
<div class="ce_text block" itemprop="description">
<?= $this->teaser ?>
</div>
<?php if ($this->hasText || $this->hasTeaser): ?>
<p class="more"><?= $this->more ?></p>
<?php endif; ?>
<?php $this->showTemplateVars(); ?>
</div>
</div>
Zitat:
<?php $this->insert('picture_default', $this->picture); ?>
hier rum sollte der <a>-tag erzeugt werden:
Code:
<a href="..."><?php $this->insert('picture_default', $this->picture); ?></a>
vielen Dank für die Hilfestellung
news_latest.html5 anpassen $this->linkHeadline
Zitat:
Zitat von
rusty
Hallo planepix,
2 Ideen:
1. Per CSS die Caption so einstellen, dass sie für Mausereignisse quasi durchsichtig wird:
Code:
.caption { pointer-events: none; }
2. Den Link um die figure entfernen, um ihn anschließend einmal um das image und einmal um die caption zu legen.
Zum Entfernen des Links ersetze ich meistens das durch
Danke für die erste Variante.
Da caption komplett eine Farbe erhält, geht es nicht.
Zweite Variante habe ich versucht; egal wie ich es drehe, gelingt es mir nicht.
Ich hab jetzt ja ein Ansatz.