fritzmg/contao-sharebuttons

[Contao 4.3] _contao/share instdead of share/index.php

Closed this issue · 2 comments

sharebuttons_default.html5 and sharebuttons_fontawesome.html5

<a href="share/index.php?p=facebook&amp;u=<?php echo $this->url; ?>&amp;t=<?php echo $this->title; ?>" rel="nofollow" title="<?php echo $this->lang['share_on_facebook']; ?>" onclick="return shd.open(this.href,600,300);">Facebook</a>
<a href="share/index.php?p=twitter&amp;u=<?php echo $this->url; ?>&amp;t=<?php echo $this->title; ?>" rel="nofollow" title="<?php echo $this->lang['share_on_twitter']; ?>" onclick="return shd.open(this.href,500,260);">Twitter</a>

should be:

<a href="_contao/share?p=facebook&amp;u=<?php echo $this->url; ?>&amp;t=<?php echo $this->title; ?>" rel="nofollow" title="<?php echo $this->lang['share_on_facebook']; ?>" onclick="return shd.open(this.href,600,300);"></a>
<a href="_contao/share?p=twitter&amp;u=<?php echo $this->url; ?>&amp;t=<?php echo $this->title; ?>" rel="nofollow" title="<?php echo $this->lang['share_on_twitter']; ?>" onclick="return shd.open(this.href,500,260);"></a>

Right, I forgot that it is a route in Contao 4 now.

However, this would break compatibility with Contao 3. I'll just directly link to the respective share scripts instead.

Fixed in 828f94a