JS sharing qq Space, Sina Weibo, Baidu, Google, Renren, happy NET code

Source: Internet
Author: User
Tags php tutorial

JS sharing qq Space, Sina Weibo, Baidu, Google, Renren, happy NET code

/*
* Do not download this JS file to your host, because the wind will not regularly update the Yin.
* Stored in Google code hosting is very stable, do not worry about which day will be harmonious.
* We should all trust Google.
*/

/*
* Share.js
* Copyright (c) 2009 Fengyin
* date:2010 Year January 7 13:16:17
* Blog:http://fengyin.name/http://www.111cn.net
* update:http://code.google.com/p/share-js/
*/
(function () {var a=

{version: ' 1.0 ', Build: ' 1ce010bc1f412fd202df4c0b28b9f380 ', url:function () {return

encodeURIComponent (window.location.href)},title:function () {return

encodeURIComponent (Window.document.title)},content:function (b) {if (b) {return

encodeURIComponent (document.getElementById (b). innertext)}else

{return "" "}},setid:function () {if (typeof (Shareid) = =" undefined ") {return null}else

{return shareid}},kaixin:function () {window.open

("http://www.kaixin001.com/repaste/share.php tutorial? rtitle=" +this.title ()

+ "&rurl=" +this.url () + "&rcontent=" +this.content (This.setid ())},renren:function ()

{window.open ("http://share.renren.com/share/buttonshare.do?link=" +this.url ()

+ "&title=" +this.title ())},sinaminiblog:function () {window.open

("Http://v.t.sina.com.cn/share/share.php?url=" +this.url () + "&title=" +this.title ()

+ "&content=utf-8&source=&sourceurl=&pic=")},baidusoucang:function () {window.open

("http://cang.baidu.com/do/add?it=" +this.title () + "&iu=" +this.url ()

+ "&dc=" +this.content (This.setid ()) + "&fr=ien#nw=1")},qqshuqian:function ()

{window.open ("http://shuqian.qq.com/post?from=3&title=" +this.title ()

+ "&uri=" +this.url () + "&jumpback=2&noui=1")},gugesghuqian:function () {window.open

("http://www.google.com/bookmarks/mark?op=edit&output=popup&bkmk=" +this.url ()

+ "&title=" +this.title ())},douban:function () {window.open

("Http://www.douban.com/recommend/?url=" +this.url () + "&title=" +this.title ()

+ "&v=1")},baishehui:function () {window.open

("http://bai.sohu.com/share/blank/addbutton.do?from=fengyin&link=" +this.url ()

+ "&title=" +this.title ())}};window.share=a}) ();d ocument.write ("Share this page to: <a

href= "Web effects: Share.kaixin ();" > kaixin </a> <a href= "Javascript:share.renren

();" > Renren </a> <a href= "Javascript:share.baishehui ();" > White Society </a> <a

Href= "Javascript:share.sinaminiblog ();" > Sina Micro-blog </a> <a

Href= "Javascript:share.baidusoucang ();" > Baidu Search </a> <a

Href= "Javascript:share.qqshuqian ();" >QQ Bookmarks </a> <a

Href= "Javascript:share.gugesghuqian ();" > Google </a> <a

Href= "Javascript:share.douban ();" > Watercress </a> ");

The call method is very simple, directly save the following content into JS and then to the page to be called plus this JS became.
Such as
Above JS I save as 111cn.net.js file

Called in b.htm
<script type= "Text/javascript" src= "Http://www.111cn.net/111cn.net.js" ></script>

This is the KO.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.