-
AuthorPosts
-
December 18th, 2015 at 05:34 #34867Ippolit
Hi,
First off, great theme!
I am in a small dilemma here though, regarding the linking of the social pages. For a different site, I have used the following links in order to get the URL and Title of the page when sharing:
Some text
(I naturally tried using simply this bit: https://www.facebook.com/sharer/sharer.php?u=’+encodeURIComponent(document.URL)+’&t=’+encodeURIComponent(document.URL));return false – but to no avail.)The problem is that I for some reason cannot do this when pasting the links into the Social Media Settings. I have no clue why, but I suspect it’s because no js is supported? and the links are redone so that space is translated into %20, etc.?
If so, how would I be able to change that (or perhaps use other parameters)?
Thank you,
Ippolit.December 18th, 2015 at 05:37 #34868IppolitOk, sorry for a double post, but I didn’t realise that links would be automatically changed, so to be sure, this is the code:
<a href="https://www.facebook.com/sharer/sharer.php?u=http%3A%2F%2Fexample.com&t=" onclick="window.open('https://www.facebook.com/sharer/sharer.php?u='+encodeURIComponent(document.URL)+'&t='+encodeURIComponent(document.URL));return false">some text</a>
December 21st, 2015 at 12:48 #34907ZedCryout Creations mastermindSocial links are filtered using WordPress’ wp_kses filter, so links using JS would get filtered out.
The Social links are not designed to be used in that way. You can add sharing buttons for sharing your content.
If you like our creations, help us share by rating them on WordPress.org.
Please check the available documentation and search the forums before starting a topic.December 23rd, 2015 at 02:04 #34924IppolitThanks,
I like to keep it clean, and sharing plugins are everything but clean (and they clog on the resources).
I’ll have to think of a different solution 🙂Thanks again, great theme!
-
AuthorPosts
The topic ‘Social buttons link’ is closed to new replies.