Version 3.2.3

This commit is contained in:
Neo committed 2025-12-19 00:34:03 -08:00
1 parent ae5c01cc78
commit 78706903a2
2641 files changed
+228363 -201264

No files matched your search

+29 -13
View File
@@ -45,6 +45,7 @@ _sharelinks.prototype.sharelinks = {
var shareKey = elem.id.replace( /slink_/, '' );
var ok = false;
var callback = null;
var h = '190';
if ( shareKey == 'twitter' )
{
@@ -52,15 +53,16 @@ _sharelinks.prototype.sharelinks = {
{
callback = ipb.sharelinks.twitterPostPop;
ok = true;
h = '110';
}
}
else if ( shareKey == 'facebook' )
{
if ( ipb.vars['member_id'] && ipb.vars['fb_uid'] )
{
//if ( ipb.vars['member_id'] && ipb.vars['fb_uid'] )
//{
callback = ipb.sharelinks.facebookPostPop;
ok = true;
}
//}
}
if ( ok === false || DISABLE_AJAX )
@@ -73,19 +75,26 @@ _sharelinks.prototype.sharelinks = {
var _url = ipb.vars['base_url'] + '&app=core&module=ajax&secure_key=' + ipb.vars['secure_hash'] + '&section=sharelinks&do=' + shareKey + 'Form';
var x = new ipb.Popup( 'shareKeyPop_' + Math.random(), { type: 'balloon',
ajaxURL: _url,
stem: true,
hideAtStart: false,
attach: { target: $('slink_' + shareKey), position: 'auto' },
w: '400px' }, { 'afterAjax': callback, 'beforeAjax': ipb.sharelinks.resetPop } );
var x = new ipb.Popup( 'shareKeyPop_' + Math.random(), { type: 'modal',
ajaxURL: _url,
modal: true,
stem: false,
hideAtStart: false,
w: '550px', h: h }, { 'afterAjax': callback, 'beforeAjax': ipb.sharelinks.resetPop } );
},
/**
* Post process twitter pop-up
*/
facebookPostPop: function( e )
facebookPostPop: function( e, responseText )
{
/* Issue with FB API? */
if( responseText == 'x' )
{
window.location = "http://www.facebook.com/sharer.php?u=" + ipb.sharelinks.url.encodeParam();
return false;
}
$('fContent').update('');
$('fSubmit').observe('click', ipb.sharelinks.goFacebook);
},
@@ -93,12 +102,19 @@ _sharelinks.prototype.sharelinks = {
/**
* Post process twitter pop-up
*/
twitterPostPop: function( e )
twitterPostPop: function( e, responseText )
{
/* Issue with Twitter API? */
if( responseText == 'x' )
{
window.location = "http://twitter.com/intent/tweet?status=" + ipb.sharelinks.title.encodeParam() + '%20-%20' + ipb.sharelinks.url.encodeParam();
return false;
}
/* clean up title */
ipb.sharelinks.title = ipb.sharelinks.title.replace(/"/g , '"');
ipb.sharelinks.title = ipb.sharelinks.title.replace(/!/g , "!");
ipb.sharelinks.title = ipb.sharelinks.title.replace(/"/g, '"');
ipb.sharelinks.title = ipb.sharelinks.title.replace(/'/g, "'");
ipb.sharelinks.title = ipb.sharelinks.title.replace(/"/g, '"');
/* Clean up board name */
@@ -106,7 +122,7 @@ _sharelinks.prototype.sharelinks = {
ipb.sharelinks.bname = ipb.sharelinks.bname.replace(/!/g , "!");
ipb.sharelinks.bname = ipb.sharelinks.bname.replace(/'/g , "'");
ipb.sharelinks.bname = ipb.sharelinks.bname.replace(/"/g, '"');
Debug.write( ipb.sharelinks.title );
$('tContent').value = ipb.sharelinks.bname + ': ' + ipb.sharelinks.title;
$('tContent').observe('keyup', ipb.sharelinks.checkTwitterLength);
$('tSubmit').observe('click', ipb.sharelinks.goTwitter);