this BBcode help everyone can view topic easier via markPoint if the post is too long to scroll exactly.
BBCode:
1. Create mark point
BBCode: [markP=<number>] anchor [/markP]
actionscript: ACP>Modules>HTML&JavaScript> JavaScript codes Management
1. Go to mark point
BBCode: [GoTo=<number>] anchor [/GoTo]
javascript: ACP>Modules>HTML&JavaScript> JavaScript codes Management
BBCode:
1. Create mark point
BBCode: [markP=<number>] anchor [/markP]
actionscript: ACP>Modules>HTML&JavaScript> JavaScript codes Management
- Code:
/***
* Date: 26/06/2016
* Author: jackauk
***/
jQuery(document).ready(function($) {
var jContent = $('.postbody, .blog_message');
jContent.html(function() {
return $(this)
.html()
.replace(/\[markP=(.*?)\](.*?)\[\/markP\]/g,'<p id="$1">$2</p>');
});
});
1. Go to mark point
BBCode: [GoTo=<number>] anchor [/GoTo]
javascript: ACP>Modules>HTML&JavaScript> JavaScript codes Management
- Code:
/***
* Date: 26/06/2016
* Author: jackauk
***/
jQuery(document).ready(function($) {
var jContent = $('.postbody, .blog_message');
jContent.html(function() {
return $(this)
.html()
.replace(/\[GoTo=(.*?)\](.*?)\[\/GoTo\]/g,'<p id="g$1">$2</p>');
});
$('p').click(function() {
var address_origin = $(this).attr("id");
if (address_origin.indexOf("g")==0)
{
var address = '#'+ $(this).attr("id").replace('g','');
$(document.body).animate({ 'scrollTop': $(address).offset().top}, 1000);
}
});
});
function gotoMark(GAL) {
var address_origin = $(this).attr("id");
if (address_origin.indexOf("g")==0)
{
var address = '#'+ $(this).attr("id").replace('g','');
$(document.body).animate({ 'scrollTop': $(address).offset().top}, 1000);
}
}