Código
<div id="FM-featured" ></div>
<script type="text/javascript">
//#################### Defaults
var ListBlogLink = window.location.hostname;
var ListCount = 4;
var ChrCount = 97;
var TitleCount = 97;
var ImageSize = 360;
//################ Function Start
function mbtlist(json) {
document.write('<ul class="mbtlist">');
for (var i = 0; i < ListCount; i++)
{
//################### Variables Declared
var listing= ListImage = ListUrl = ListTitle = ListImage = ListContent = ListConten = ListAuthor = ListTag = ListDate = ListUpdate = ListComments = thumbUrl = TotalPosts = sk = ListMonth = Y = D = M = m = YY = DD = MM = mm = TT = "";
//################### Category
if (json.feed.entry[i].category != null)
{
for (var k = 0; k < json.feed.entry[i].category.length; k++) {
ListTag += json.feed.entry[i].category[k].term;
if(k < json.feed.entry[i].category.length-1)
{ ListTag += " / ";}
}
}
//################### URL
for (var j = 0; j < json.feed.entry[i].link.length; j++) {
if (json.feed.entry[i].link[j].rel == 'alternate') {
break;
}
}
ListUrl= "'" + json.feed.entry[i].link[j].href + "'";
//################### Info
TotalPosts = json.feed.openSearch$totalResults.$t;
if (json.feed.entry[i].title!= null)
{
ListTitle= json.feed.entry[i].title.$t.substr(0, TitleCount);
}
if (json.feed.entry[i].thr$total)
{
ListComments= json.feed.entry[i].thr$total.$t;
}
ListAuthor= json.feed.entry[i].author[0].name.$t.split(" ");
ListAuthor=ListAuthor.slice(0, 3).join(" ");
//################### Content Check
ListConten = json.feed.entry[i].content.$t;
ListContent= ListConten.replace(/(<([^>]+)>)/ig,"").substring(0, ChrCount);
//################### Date Format
ListMonth= ["January","February","March","April","May","June","July","August","September","October","November","December"];
ListDate= json.feed.entry[i].published.$t.substring(0,10);
Y = ListDate.substring(0, 4);
m = ListDate.substring(5, 7);
D = ListDate.substring(8, 10);
M = ListMonth[parseInt(m - 1)];
ListUpdate= json.feed.entry[i].updated.$t.substring(0, 16);
YY = ListUpdate.substring(0, 4);
mm = ListUpdate.substring(5, 7);
DD = ListUpdate.substring(8, 10);
TT = ListUpdate.substring(11, 16);
MM = ListMonth[parseInt(mm - 1)];
//################### Thumbnail Check
// YouTube scan
if (json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/) != null)
{
var youtube_id = json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/).pop();
if (youtube_id.length == 11) {
var ListImage = "'//img.youtube.com/vi/"+youtube_id+"/0.jpg'";
}
}
else if (json.feed.entry[i].media$thumbnail)
{
thumbUrl = json.feed.entry[i].media$thumbnail.url;
sk= thumbUrl.replace("/s72-c/","/s"+ImageSize+"/");
ListImage= "'" + sk.replace("?imgmax=800","") + "'";
}
else if (json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/) != null)
{
// Support For 3rd Party Images
ListImage = json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/)[1];
}
else
{
ListImage= "'https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_AODL7PfHgStp-5MxJjr95IsrmrokL8q6LDpdQbvTMGL_hCDqBGl1wXcXAzIkOT1pLi82BofU5rNBRFQlMX1SH8Sul8QSzEM6I8vE2I6qdg3OsOVj_d69_XMwJfrcC9X7GGcVM2CV-kYf/s1600/no-image.png'";
}
//################### Printing List
var listing = "<li class='node"+[i]+"' ><a href="
+ ListUrl+
"><div class='overlay'><img src="
+ListImage+
"/></div></a><span class='itag'>"
+ListTag+
"</span><a class='mbttitle' href="
+ ListUrl+
">"
+ ListTitle+
"</a> <div class='iline'>By <span class='iauthor'>"
+ListAuthor+
"</span><span class='icomments'>"
+ ListComments+
"</span><span class='idate'> "
+ M +
" "
+ D +
", "
+ Y +
"</span><span class='iedit'> <a class='tooltip1'>Edited<span><b></b>On ? "
+ MM +
" "
+ DD +
", "
+ YY +
" at ? "
+TT+
" </span></a> </span></div> <span class='icon'>"
+ListContent+
" ... <a href="
+ListUrl+
" class='imore'></a></span></li>";
document.write(listing);
}
document.write("<div class='itotal'><span> <a href='"+ListBlogLink+"/search'>View all <font>"+TotalPosts+"</font> posts</a></span></div></ul>");
}
</script>
<script>
var ListBlogLink = "you-home_url";
var ListCount = 4;
var LableName = "you-tag_label" // recommended is Featured //
</script>
<script>
document.write("<script src='"+ListBlogLink+"/feeds/posts/default/-/"+LableName+"?alt=json-in-script&callback=mbtlist'></"+"script>");
</script>
<div id="FM-featured" ></div>
<script type="text/javascript">
//#################### Defaults
var ListBlogLink = window.location.hostname;
var ListCount = 4;
var ChrCount = 97;
var TitleCount = 97;
var ImageSize = 360;
//################ Function Start
function mbtlist(json) {
document.write('<ul class="mbtlist">');
for (var i = 0; i < ListCount; i++)
{
//################### Variables Declared
var listing= ListImage = ListUrl = ListTitle = ListImage = ListContent = ListConten = ListAuthor = ListTag = ListDate = ListUpdate = ListComments = thumbUrl = TotalPosts = sk = ListMonth = Y = D = M = m = YY = DD = MM = mm = TT = "";
//################### Category
if (json.feed.entry[i].category != null)
{
for (var k = 0; k < json.feed.entry[i].category.length; k++) {
ListTag += json.feed.entry[i].category[k].term;
if(k < json.feed.entry[i].category.length-1)
{ ListTag += " / ";}
}
}
//################### URL
for (var j = 0; j < json.feed.entry[i].link.length; j++) {
if (json.feed.entry[i].link[j].rel == 'alternate') {
break;
}
}
ListUrl= "'" + json.feed.entry[i].link[j].href + "'";
//################### Info
TotalPosts = json.feed.openSearch$totalResults.$t;
if (json.feed.entry[i].title!= null)
{
ListTitle= json.feed.entry[i].title.$t.substr(0, TitleCount);
}
if (json.feed.entry[i].thr$total)
{
ListComments= json.feed.entry[i].thr$total.$t;
}
ListAuthor= json.feed.entry[i].author[0].name.$t.split(" ");
ListAuthor=ListAuthor.slice(0, 3).join(" ");
//################### Content Check
ListConten = json.feed.entry[i].content.$t;
ListContent= ListConten.replace(/(<([^>]+)>)/ig,"").substring(0, ChrCount);
//################### Date Format
ListMonth= ["January","February","March","April","May","June","July","August","September","October","November","December"];
ListDate= json.feed.entry[i].published.$t.substring(0,10);
Y = ListDate.substring(0, 4);
m = ListDate.substring(5, 7);
D = ListDate.substring(8, 10);
M = ListMonth[parseInt(m - 1)];
ListUpdate= json.feed.entry[i].updated.$t.substring(0, 16);
YY = ListUpdate.substring(0, 4);
mm = ListUpdate.substring(5, 7);
DD = ListUpdate.substring(8, 10);
TT = ListUpdate.substring(11, 16);
MM = ListMonth[parseInt(mm - 1)];
//################### Thumbnail Check
// YouTube scan
if (json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/) != null)
{
var youtube_id = json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/).pop();
if (youtube_id.length == 11) {
var ListImage = "'//img.youtube.com/vi/"+youtube_id+"/0.jpg'";
}
}
else if (json.feed.entry[i].media$thumbnail)
{
thumbUrl = json.feed.entry[i].media$thumbnail.url;
sk= thumbUrl.replace("/s72-c/","/s"+ImageSize+"/");
ListImage= "'" + sk.replace("?imgmax=800","") + "'";
}
else if (json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/) != null)
{
// Support For 3rd Party Images
ListImage = json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/)[1];
}
else
{
ListImage= "'https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_AODL7PfHgStp-5MxJjr95IsrmrokL8q6LDpdQbvTMGL_hCDqBGl1wXcXAzIkOT1pLi82BofU5rNBRFQlMX1SH8Sul8QSzEM6I8vE2I6qdg3OsOVj_d69_XMwJfrcC9X7GGcVM2CV-kYf/s1600/no-image.png'";
}
//################### Printing List
var listing = "<li class='node"+[i]+"' ><a href="
+ ListUrl+
"><div class='overlay'><img src="
+ListImage+
"/></div></a><span class='itag'>"
+ListTag+
"</span><a class='mbttitle' href="
+ ListUrl+
">"
+ ListTitle+
"</a> <div class='iline'>By <span class='iauthor'>"
+ListAuthor+
"</span><span class='icomments'>"
+ ListComments+
"</span><span class='idate'> "
+ M +
" "
+ D +
", "
+ Y +
"</span><span class='iedit'> <a class='tooltip1'>Edited<span><b></b>On ? "
+ MM +
" "
+ DD +
", "
+ YY +
" at ? "
+TT+
" </span></a> </span></div> <span class='icon'>"
+ListContent+
" ... <a href="
+ListUrl+
" class='imore'></a></span></li>";
document.write(listing);
}
document.write("<div class='itotal'><span> <a href='"+ListBlogLink+"/search'>View all <font>"+TotalPosts+"</font> posts</a></span></div></ul>");
}
</script>
<script>
var ListBlogLink = "you-home_url";
var ListCount = 4;
var LableName = "you-tag_label" // recommended is Featured //
</script>
<script>
document.write("<script src='"+ListBlogLink+"/feeds/posts/default/-/"+LableName+"?alt=json-in-script&callback=mbtlist'></"+"script>");
</script>
- Reemplace
Red text
con el enlace de su sitio: como http://www.templatezy.com - Reemplace
blue text
con su sitio cualquier etiqueta: Me gusta asignar la etiqueta de función a la publicación de funciones - Nota: debe asignar una etiqueta a las publicaciones antes de agregar esa etiqueta en el script.
- Finalmente haga clic enGuardar widget.
- Para mostrar las publicaciones de la galería, siga estos pasos
- En Blogger Dashbord, haga clic en Diseño .
- Copie el código a continuación y Pasteen la Gallery Widgetcaptura de pantalla como en la anterior
Códigos
<div id="FM-gallery" ></div> <script type="text/javascript">
//#################### Defaults var ListBlogLink = window.location.hostname; var ListCount = 3; var ChrCount = 97; var TitleCount = 97; var ImageSize = 670; //################ Function Start function mbtlist(json) { document.write('<ul class="mbtlist">'); for (var i = 0; i < ListCount; i++) { //################### Variables Declared var listing= ListImage = ListUrl = ListTitle = ListImage = ListContent = ListConten = ListAuthor = ListTag = ListDate = ListUpdate = ListComments = thumbUrl = TotalPosts = sk = ListMonth = Y = D = M = m = YY = DD = MM = mm = TT = "";
//################### Category if (json.feed.entry[i].category != null) { for (var k = 0; k < json.feed.entry[i].category.length; k++) { ListTag += json.feed.entry[i].category[k].term; if(k < json.feed.entry[i].category.length-1) { ListTag += " / ";} } }
//################### URL for (var j = 0; j < json.feed.entry[i].link.length; j++) { if (json.feed.entry[i].link[j].rel == 'alternate') { break; } } ListUrl= "'" + json.feed.entry[i].link[j].href + "'";
//################### Info TotalPosts = json.feed.openSearch$totalResults.$t; if (json.feed.entry[i].title!= null) { ListTitle= json.feed.entry[i].title.$t.substr(0, TitleCount); } if (json.feed.entry[i].thr$total) { ListComments= json.feed.entry[i].thr$total.$t; } ListAuthor= json.feed.entry[i].author[0].name.$t.split(" "); ListAuthor=ListAuthor.slice(0, 3).join(" ");
//################### Content Check
ListConten = json.feed.entry[i].content.$t; ListContent= ListConten.replace(/(<([^>]+)>)/ig,"").substring(0, ChrCount);
//################### Date Format
ListMonth= ["January","February","March","April","May","June","July","August","September","October","November","December"];
ListDate= json.feed.entry[i].published.$t.substring(0,10);
Y = ListDate.substring(0, 4); m = ListDate.substring(5, 7); D = ListDate.substring(8, 10); M = ListMonth[parseInt(m - 1)];
ListUpdate= json.feed.entry[i].updated.$t.substring(0, 16);
YY = ListUpdate.substring(0, 4); mm = ListUpdate.substring(5, 7); DD = ListUpdate.substring(8, 10); TT = ListUpdate.substring(11, 16); MM = ListMonth[parseInt(mm - 1)];
//################### Thumbnail Check // YouTube scan
if (json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/) != null) {
var youtube_id = json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/).pop(); if (youtube_id.length == 11) { var ListImage = "'//img.youtube.com/vi/"+youtube_id+"/0.jpg'"; } }
else if (json.feed.entry[i].media$thumbnail) { thumbUrl = json.feed.entry[i].media$thumbnail.url; sk= thumbUrl.replace("/s72-c/","/s"+ImageSize+"/"); ListImage= "'" + sk.replace("?imgmax=800","") + "'"; }
else if (json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/) != null) { // Support For 3rd Party Images ListImage = json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/)[1]; } else { ListImage= "'https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_AODL7PfHgStp-5MxJjr95IsrmrokL8q6LDpdQbvTMGL_hCDqBGl1wXcXAzIkOT1pLi82BofU5rNBRFQlMX1SH8Sul8QSzEM6I8vE2I6qdg3OsOVj_d69_XMwJfrcC9X7GGcVM2CV-kYf/s1600/no-image.png'"; } //################### Printing List
var listing = "<li class='node"+[i]+"' ><a href=" + ListUrl+ "><div class='overlay'><img src=" +ListImage+ "/></div></a><span class='itag'>" +ListTag+ "</span><a class='mbttitle' href=" + ListUrl+ ">" + ListTitle+ "</a> <div class='iline'>By <span class='iauthor'>" +ListAuthor+ "</span><span class='icomments'>" + ListComments+ "</span><span class='idate'> " + M + " " + D + ", " + Y +
"</span><span class='iedit'> <a class='tooltip1'>Edited<span><b></b>On ? " + MM + " " + DD + ", " + YY + " at ? " +TT+ " </span></a> </span></div> <span class='icon'>" +ListContent+ " ... <a href=" +ListUrl+ " class='imore'></a></span></li>"; document.write(listing); } document.write("<div class='itotal'><span> <a href='"+ListBlogLink+"/search'>View all <font>"+TotalPosts+"</font> posts</a></span></div></ul>"); } </script>
<script> var ListBlogLink = "add-your-site-url";var ListCount = 3;var LableName = "Gallery" </script>
<div id="FM-gallery" ></div>
<script type="text/javascript">
//#################### Defaults
var ListBlogLink = window.location.hostname;
var ListCount = 3;
var ChrCount = 97;
var TitleCount = 97;
var ImageSize = 670;
//################ Function Start
function mbtlist(json) {
document.write('<ul class="mbtlist">');
for (var i = 0; i < ListCount; i++)
{
//################### Variables Declared
var listing= ListImage = ListUrl = ListTitle = ListImage = ListContent = ListConten = ListAuthor = ListTag = ListDate = ListUpdate = ListComments = thumbUrl = TotalPosts = sk = ListMonth = Y = D = M = m = YY = DD = MM = mm = TT = "";
//################### Category
if (json.feed.entry[i].category != null)
{
for (var k = 0; k < json.feed.entry[i].category.length; k++) {
ListTag += json.feed.entry[i].category[k].term;
if(k < json.feed.entry[i].category.length-1)
{ ListTag += " / ";}
}
}
//################### URL
for (var j = 0; j < json.feed.entry[i].link.length; j++) {
if (json.feed.entry[i].link[j].rel == 'alternate') {
break;
}
}
ListUrl= "'" + json.feed.entry[i].link[j].href + "'";
//################### Info
TotalPosts = json.feed.openSearch$totalResults.$t;
if (json.feed.entry[i].title!= null)
{
ListTitle= json.feed.entry[i].title.$t.substr(0, TitleCount);
}
if (json.feed.entry[i].thr$total)
{
ListComments= json.feed.entry[i].thr$total.$t;
}
ListAuthor= json.feed.entry[i].author[0].name.$t.split(" ");
ListAuthor=ListAuthor.slice(0, 3).join(" ");
//################### Content Check
ListConten = json.feed.entry[i].content.$t;
ListContent= ListConten.replace(/(<([^>]+)>)/ig,"").substring(0, ChrCount);
//################### Date Format
ListMonth= ["January","February","March","April","May","June","July","August","September","October","November","December"];
ListDate= json.feed.entry[i].published.$t.substring(0,10);
Y = ListDate.substring(0, 4);
m = ListDate.substring(5, 7);
D = ListDate.substring(8, 10);
M = ListMonth[parseInt(m - 1)];
ListUpdate= json.feed.entry[i].updated.$t.substring(0, 16);
YY = ListUpdate.substring(0, 4);
mm = ListUpdate.substring(5, 7);
DD = ListUpdate.substring(8, 10);
TT = ListUpdate.substring(11, 16);
MM = ListMonth[parseInt(mm - 1)];
//################### Thumbnail Check
// YouTube scan
if (json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/) != null)
{
var youtube_id = json.feed.entry[i].content.$t.match(/youtube\.com.*(\?v=|\/embed\/)(.{11})/).pop();
if (youtube_id.length == 11) {
var ListImage = "'//img.youtube.com/vi/"+youtube_id+"/0.jpg'";
}
}
else if (json.feed.entry[i].media$thumbnail)
{
thumbUrl = json.feed.entry[i].media$thumbnail.url;
sk= thumbUrl.replace("/s72-c/","/s"+ImageSize+"/");
ListImage= "'" + sk.replace("?imgmax=800","") + "'";
}
else if (json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/) != null)
{
// Support For 3rd Party Images
ListImage = json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/)[1];
}
else
{
ListImage= "'https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_AODL7PfHgStp-5MxJjr95IsrmrokL8q6LDpdQbvTMGL_hCDqBGl1wXcXAzIkOT1pLi82BofU5rNBRFQlMX1SH8Sul8QSzEM6I8vE2I6qdg3OsOVj_d69_XMwJfrcC9X7GGcVM2CV-kYf/s1600/no-image.png'";
}
//################### Printing List
var listing = "<li class='node"+[i]+"' ><a href="
+ ListUrl+
"><div class='overlay'><img src="
+ListImage+
"/></div></a><span class='itag'>"
+ListTag+
"</span><a class='mbttitle' href="
+ ListUrl+
">"
+ ListTitle+
"</a> <div class='iline'>By <span class='iauthor'>"
+ListAuthor+
"</span><span class='icomments'>"
+ ListComments+
"</span><span class='idate'> "
+ M +
" "
+ D +
", "
+ Y +
"</span><span class='iedit'> <a class='tooltip1'>Edited<span><b></b>On ? "
+ MM +
" "
+ DD +
", "
+ YY +
" at ? "
+TT+
" </span></a> </span></div> <span class='icon'>"
+ListContent+
" ... <a href="
+ListUrl+
" class='imore'></a></span></li>";
document.write(listing);
}
document.write("<div class='itotal'><span> <a href='"+ListBlogLink+"/search'>View all <font>"+TotalPosts+"</font> posts</a></span></div></ul>");
}
</script>
<script>
var ListBlogLink = "add-your-site-url";
var ListCount = 3;
var LableName = "Gallery"
</script>
- Reemplace
Red text
con el enlace de su sitio: como http://www.templatezy.com - Reemplace
blue text
con su sitio cualquier etiqueta: Me gusta asignar la etiqueta de la Galería a la publicación de la galería - Nota: debe asignar una etiqueta a las publicaciones antes de agregar esa etiqueta en el script.
- Finalmente haga clic enGuardar widget.
- Para mostrar publicaciones de noticias, siga estos pasos
- En Blogger Dashbord, haga clic en Diseño .
- Copie el código a continuación y Pasteen el menú News WidgetComo en la captura de pantalla anterior
- Reemplace
Red text
con el enlace de su sitio: como http://www.templatezy.com - Reemplace
Blue text
con su sitio cualquier enlace de etiqueta: como si asigne una etiqueta multimedia a la publicación de noticias - Finalmente haga clic enGuardar widget.
<div id="FM-video" ></div> <script type="text/javascript"> //################### Valores predeterminados var ListBlogLink = ventana.ubicación.nombre de host; var CuentaLista = 5; var CuentaCuenta = 97; var TítuloCuenta = 97; var tamaño de imagen = 420; //################ Función Función de inicio mbtlist(json) { document.write('<ul class="mbtlist">'); for (var i = 0; i < ListCount; i++) { //################### Variables declaradas var listing= ListImage = ListUrl = ListTitle = ListImage = ListContent = ListConten = ListAuthor = ListTag = ListDate = ListUpdate = ListComments = thumbUrl = TotalPosts = sk = ListMonth = Y = D = M = m = YY = DD = MM = mm = TT = ""; //################### Categoría if (json.feed.entry[i].category ! = nulo) { for (var k = 0; k < json.feed.entry[i].category.length; k++) { ListTag += json.feed.entry[i].category[k].term; if(k < json.feed.entry[i].category.length-1) { ListTag += " / ";} } } //################## # URL para (var j = 0; j < json.feed.entry[i].link.length; j++) { if (json.feed.entry[i].link[j].rel == 'alternate') { descanso; } } ListUrl= "'" + json.feed.entry[i].link[j].href + "'"; //################### Info TotalPosts = json.feed.openSearch$totalResults.$t; if (json.feed.entry[i].title!= null) { ListTitle= json.feed.entry[i].title.$t.substr(0, TitleCount); } if (json.feed.entry[i].thr$total) { ListComments= json.feed.entry[i].thr$total.$t; } ListAuthor= json.feed.entry[i].autor[0].name.$t.split(" "); ListAuthor=ListAuthor.slice(0, 3).join(" "); //################### Lista de comprobación de contenidoConten = json.feed.entry[i].content.$t; ListContent= ListConten.replace(/(<([^>]+)>)/ig,"").substring(0, ChrCount); //################## Formato de fecha ListMonth= ["Enero","Febrero","Marzo","Abril","Mayo","Junio", "Julio Agosto Septiembre Octubre Noviembre Diciembre"]; ListDate= json.feed.entry[i].published.$t.substring(0,10); Y = FechaLista.subcadena(0, 4); m = FechaLista.subcadena(5, 7); D = ListDate.substring(8, 10); M = ListMonth[parseInt(m - 1)]; ListUpdate= json.feed.entry[i].updated.$t.substring(0, 16); YY = ListUpdate.substring(0, 4); mm = ListaActualizar.subcadena(5, 7); DD = ListUpdate.substring(8, 10); TT = ListaActualizar.subcadena(11, 16); MM = ListMonth[parseInt(mm - 1)]; //################### Verificación de miniaturas // Análisis de YouTube si (json.feed.entry[i].content.$t.match(/youtube\.com .*(\?v=|\/embed\/)(.{11})/) != null) { var youtube_id = json.feed.entry[i].content.$t.match(/youtube\. com.*(\?v=|\/incrustar\/)(.{11})/).pop(); si (youtube_id.longitud == 11) { var ListImage = "'//img.youtube.com/vi/" +youtube_id+"/0.jpg'"; } } else if (json.feed.entry[i].media$thumbnail) { thumbUrl = json.feed.entry[i].media$thumbnail.url; sk= thumbUrl.replace("/s72-c/","/s"+ImageSize+"/"); ListImage= "'" + sk.replace("?imgmax=800","") + "'"; } else if (json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/) != null) { / / Compatibilidad con imágenes de terceros ListImage = json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/)[1 ]; } else { ListImage= "'https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_AODL7PfHgStp-5MxJjr95IsrmrokL8q6LDpdQbvTMGL_hCDqBGl1wXcXAzIkOT1pLi82BofU5rNBRFQlMX1SH8Sul8QSzEM6I8vE2I6qdg3OsOVj_d69_XMwJfrcC9X7GGcVM2CV-kYf/s1600/no-image.png'"; } //################### Lista de impresión var listado = "< li class='node"+[i]+"' ><a href=" + ListUrl+ "><div class='overlay'><img src=" +ListImage+ "/></div></a>< span class='itag'>" +ListTag+ "</span><a class='mbttitle' href=" + ListUrl+ ">" + ListTitle+ "</a> <div class='iline'>Por <span class= 'iautor'>" +ListAuthor+ "</span><span class='icomments'>" + ListComments+ "</span><span class='idate'> " + M + " " + D + ", " + Y + "</span><span class='iedit'> <a class='tooltip1'>Editado<span><b></b>¿Activado? " + MM + " " + DD + ", " + YY + " en ? " +TT+ " </span></a> </span></div> <span class='icon'>" +ListContent+ " . .. <a href=" +ListUrl+ " class='imore'></a></span></li>"; documento.escribir(listado); } document.write("<div class='itotal'><span> <a href='"+ListBlogLink+"/search'>Ver todas las <font>"+TotalPosts+"</font> publicaciones</a></ intervalo></div></ul>"); } </script> <script>
var ListBlogLink = " agregar-el-enlace-de-su-sitio ";
var CuentaLista = 5;
var LableName = " agregar-cualquier-etiqueta-aquí "
</script>- Para mostrar publicaciones recientes, siga estos pasos
- En Blogger Dashbord, haga clic en Diseño .
- Copie el código a continuación y Pasteen la Recent Post Widgetcaptura de pantalla como en la anterior
- Reemplace
Red text
con el enlace de su sitio: como http://www.templatezy.com - Finalmente haga clic enGuardar widget.
<script type="text/javascript"> //################### Valores predeterminados var ListBlogLink = window.location.hostname; var CuentaLista = 4; var CuentaCuenta = 97; var TítuloCuenta = 97; var tamaño de imagen = 250; //################ Función Función de inicio mbtlist(json) { document.write('<ul class="mbtlist">'); for (var i = 0; i < ListCount; i++) { //################### Variables declaradas var listing= ListImage = ListUrl = ListTitle = ListImage = ListContent = ListConten = ListAuthor = ListTag = ListDate = ListUpdate = ListComments = thumbUrl = TotalPosts = sk = ListMonth = Y = D = M = m = YY = DD = MM = mm = TT = ""; //################### Categoría if (json.feed.entry[i].category != null) { for (var k = 0; k < json. feed.entry[i].category.length; k++) { ListTag += json.feed.entry[i].category[k].term; if(k < json.feed.entry[i].category.length-1) { ListTag += " / ";} } } //################## # URL para (var j = 0; j < json.feed.entry[i].link.length; j++) { if (json.feed.entry[i].link[j].rel == 'alternate') { descanso; } } ListUrl= "'" + json.feed.entry[i].link[j].href + "'"; //################### Info TotalPosts = json.feed.openSearch$totalResults.$t; if (json.feed.entry[i].title!= null) { ListTitle= json.feed.entry[i].title.$t.substr(0, TitleCount); } if (json.feed.entry[i].thr$total) { ListComments= json.feed.entry[i].thr$total.$t; } ListAuthor= json.feed.entry[i].autor[0].name.$t.split(" "); ListAuthor=ListAuthor.slice(0, 3).join(" "); //################### Lista de comprobación de contenidoConten = json.feed.entry[i].content.$t; ListContent= ListConten.replace(/(<([^>]+)>)/ig,"").substring(0, ChrCount); //################## Formato de fecha ListMonth= ["Enero","Febrero","Marzo","Abril","Mayo","Junio", "Julio Agosto Septiembre Octubre Noviembre Diciembre"]; ListDate= json.feed.entry[i].published.$t.substring(0,10); Y = FechaLista.subcadena(0, 4); m = FechaLista.subcadena(5, 7); D = ListDate.substring(8, 10); M = ListMonth[parseInt(m - 1)]; ListUpdate= json.feed.entry[i].updated.$t.substring(0, 16); YY = ListUpdate.substring(0, 4); mm = ListaActualizar.subcadena(5, 7); DD = ListUpdate.substring(8, 10); TT = ListaActualizar.subcadena(11, 16); MM = ListMonth[parseInt(mm - 1)]; //################### Verificación de miniaturas // Análisis de YouTube si (json.feed.entry[i].content.$t.match(/youtube\.com .*(\?v=|\/embed\/)(.{11})/) != null) { var youtube_id = json.feed.entry[i].content.$t.match(/youtube\. com.*(\?v=|\/incrustar\/)(.{11})/).pop(); if (youtube_id.length == 11) { var ListImage = "'//img.youtube.com/vi/"+youtube_id+"/0.jpg'"; } } else if (json.feed.entry[i].media$thumbnail) { thumbUrl = json.feed.entry[i].media$thumbnail.url; sk= thumbUrl.replace("/s72-c/","/s"+ImageSize+"/"); ListImage= "'" + sk.replace("?imgmax=800","") + "'"; } else if (json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/) != null) { / / Compatibilidad con imágenes de terceros ListImage = json.feed.entry[i].content.$t.match(/src=(.+?[\.jpg|\.gif|\.png]")/)[1 ]; } else { ListImage= "'https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_AODL7PfHgStp-5MxJjr95IsrmrokL8q6LDpdQbvTMGL_hCDqBGl1wXcXAzIkOT1pLi82BofU5rNBRFQlMX1SH8Sul8QSzEM6I8vE2I6qdg3OsOVj_d69_XMwJfrcC9X7GGcVM2CV-kYf/s1600/no-image.png'"; } //################### Lista de impresión var list = "<li class='node"+[i]+"' ><a href=" + ListUrl+ "><div class='overlay'><img src=" +ListImage+ "/></div></a><span class='itag'>" +ListTag+ "</ span><a class='mbttitle' href=" + ListUrl+ "target='_blank'>" + ListTitle+ "</a> <div class='iline'>Por <span class='iauthor'>" +ListAuthor+ " </span><span class='icomments'>" + ListComments+ "</span><span class='idate'> " + M + " " + D + ", " + Y + "</span><span class='iedit'> <a class='tooltip1'>Editado<span><b></b>¿Activado? "+MM+" " + DD + ", " + YY + " en ? " +TT+ " </span></a> </span></div> <span class='icon'>" +ListContent+ " ... <a href=" +ListUrl+ " class='imore'>< /a></span></li>"; document.write(listing); } document.write("<div class='itotal'><span> <a href='"+ListBlogLink+"/search'> Ver todas las <font>"+TotalPosts+"</font> publicaciones</a></span></div></ul>"); } </script> <script>
var ListBlogLink = " agregar-el-enlace-de-su-sitio ";
var CuentaLista = 4;
</script>
Nota:
Antes de realizar cualquier cambio en nuestro blog, tendremos que realizar una copia de seguridad del mismo por si algo no sale bien.
Puedes ver en este post como lo hacemos paso a paso
Antes de realizar cualquier cambio en nuestro blog, tendremos que realizar una copia de seguridad del mismo por si algo no sale bien.
Puedes ver en este post como lo hacemos paso a paso
No hay comentarios:
Publicar un comentario
Deja tu comentario y en breve te contestaremos