-1
我正在嘗試爲我的網站創建自定義社交分享按鈕,但我遇到了當前頁面標題和網址未被正確拉伸以與社交網絡共享的問題。我的代碼抓取頁面標題和當前網址的代碼
例子是這樣的:
<a class="share-btn twitter-btn twitter-sharer-button" id="ref_tw" href="https://twitter.com/intent/tweet?title=<?php echo $title; ?>&url=<?php echo urlencode($share_url);?>&via=Udamonia" onclick="javascript:window.open(this.href, '', 'menubar=no,toolbar=no,resizable=no,scrollbars=no,height=400,width=600');return false;"></a>
任何幫助或在正確的方向點是極大的讚賞。
謝謝!