Recordad que para pedir soporte alguno, debéis facilitar los datos de soporte oportunos por favor, mirad aquí y leer las Normas generales del foro, esto nos servirá de ayuda para dar el mejor soporte..

Gracias.

La Administración de phpBB España.

consulta sobre [BETA] YouTube Videos Mod

Soporte de MODs para phpBB 3.0.x
Dudas sobre AutoMOD aquí por favor.
Cerrado

0
No hay votos
 
Votos totales: 0

Avatar de Usuario
Megabyte
Elite
Mensajes: 1037
Registrado: 25 Dic 2010, 02:39
Edad: 45

consulta sobre [BETA] YouTube Videos Mod

#1

Mensaje por Megabyte »

Buen día amigos...

He instalado éste mod: http://www.phpbb.com/community/viewtopi ... &t=2131476

y pues todo muy bien, me gusta, de hecho le agregue a la opción donde buscar videos, el nombre de mi canal de youtube y los "jala" al darle "ver videos".

El mod funcionando aqui:
aqui

Ahora bien, me he estado leyendo ésto para encontrar la solucion a lo que busco:
esto

que quiero?
Cuando ingreso a la pagina del mod, me muestra los videos mas recientes subidos a youtube, y me gustaría poner los videos mas recientes pero subidos a mi canal o a mi playlist.

Les dejo el mod x si acaso:
youtube_videos_mod_011.zip
(85.87 KiB) Descargado 35 veces


he revisado y creo saber que todo está en un archivo js: ../youtube/quvic.js
lo posteo acá:
SPOILER_SHOW

Código: Seleccionar todo

/*!
 * QUVIC YouTube Video Browser JavaScript Library v1.0
 * http://quvic.com/
 *
 * Copyright 2010, TYZEN
 * Dual licensed under the MIT or GPL Version 2 licenses.
 * http://tyzen.net
 *
 * Includes TEXTTUBE
 * http://texttube.org
 * Copyright 2010, TEXTTUBE
 * Released under the MIT, BSD, and GPL Licenses.
 *
 * Date: Sun Jul 11 2010
 */

function onPlayerError(errorCode) {
        alert("An error occured of type:" + errorCode);
      }
 
function onYouTubePlayerReady(playerId) {
        ytplayer = document.getElementById("player");
        ytplayer.addEventListener("onError", "onPlayerError");
      }

function playVideo(videoID,title){
     if(document.title)
		document.title = title;
    
	ytplayer.loadVideoById(videoID);
}
function HDPlayer() {
        resizePlayer(720, 436);
      }
function HQPlayer() {
        resizePlayer(540, 436);
      }
function resizePlayer(width, height) {
        var playerObj = document.getElementById("player");
        playerObj.height = height;
        playerObj.width = width;
      }
function addslashes(str) {
	str=str.replace(/\'/g,'\\\'');
	str=str.replace(/\"/g,'');
	return str;
}
function stripslashes(str) {
	str=str.replace(/\\'/g,'\'');
	return str;
}
var imname;
var timer;
function mousOverImage(name,id,nr){
	if(name)
		imname = name;
	imname.src = "http://img.youtube.com/vi/"+id+"/"+nr+".jpg";
	imname.style.border = 	'3px solid silver';
	nr++;
	if(nr > 3)
		nr = 1;
	timer =  setTimeout("mousOverImage(false,'"+id+"',"+nr+");",1000);
}
function mouseOutImage(name){
	if(name)
		imname = name;
	imname.style.border = 	'3px solid #fff';
	if(timer)
		clearTimeout(timer);
}

var quvic = {};

quvic.MAX_RESULTS_LIST = 15;

quvic.VIDEO_LIST_CSS_CLASS = 'videolist';

quvic.PREVIOUS_PAGE_BUTTON = 'previousPageButton';

quvic.NEXT_PAGE_BUTTON = 'nextPageButton';

quvic.STANDARD_FEED_URL_TOP_RATED = 
    'http://gdata.youtube.com/feeds/api/standardfeeds/top_rated?';

quvic.STANDARD_FEED_URL_MOST_VIEWED = 
    'http://gdata.youtube.com/feeds/api/standardfeeds/most_viewed?';

quvic.STANDARD_FEED_URL_MOST_POPULAR = 
    'http://gdata.youtube.com/feeds/api/standardfeeds/most_popular?';

quvic.STANDARD_FEED_URL_RECENTLY_FEATURED = 
    'http://gdata.youtube.com/feeds/api/standardfeeds/recently_featured?'; 

quvic.VIDEO_FEED_URL = 
    'http://gdata.youtube.com/feeds/api/videos?';

quvic.QUERY_URL_MAP = {
  'top_rated' : quvic.STANDARD_FEED_URL_TOP_RATED,
 
  'most_viewed' : quvic.STANDARD_FEED_URL_MOST_VIEWED,
 
  'most_popular' : quvic.STANDARD_FEED_URL_MOST_POPULAR,
  
  'recently_featured' : quvic.STANDARD_FEED_URL_RECENTLY_FEATURED,  
 
  'search' : quvic.VIDEO_FEED_URL
};

quvic.nextPage = 2;

quvic.previousPage = 0;

quvic.previousSearchTerm = '';

quvic.previousQueryType = 'search';

quvic.jsonFeed_ = null;

quvic.appendScriptTag = function(scriptSrc, scriptId, scriptCallback) {
 
  var oldScriptTag = document.getElementById(scriptId);
  if (oldScriptTag) {
    oldScriptTag.parentNode.removeChild(oldScriptTag);
  }
  var script = document.createElement('script');
  script.setAttribute('src', 
      scriptSrc + '&v=2&alt=jsonc&callback=' + scriptCallback);
  script.setAttribute('id', scriptId);
  script.setAttribute('type', 'text/javascript');
  document.getElementsByTagName('head')[0].appendChild(script);
};

quvic.listVideos = function(queryType, searchTerm, page) {
  quvic.previousSearchTerm = searchTerm; 
  quvic.previousQueryType = queryType; 
  var queryUrl = quvic.QUERY_URL_MAP[queryType];
  if (queryUrl) {
    queryUrl += 'max-results=' + quvic.MAX_RESULTS_LIST +
        '&format=5&start-index=' + (((page - 1) * quvic.MAX_RESULTS_LIST) + 1);
    if (searchTerm != '') {
      queryUrl += '&q=' + encodeURI(searchTerm);
    }
    quvic.appendScriptTag(queryUrl, 
                         'searchResultsVideoListScript', 
                         'quvic.listVideosCallback');
    quvic.updateNavigation(page);
	
  } else {
    alert('Unknown feed type specified');
  }
};

quvic.PresentVideos = function(queryType, searchTerm, page) {
  quvic.previousSearchTerm = searchTerm; 
  quvic.previousQueryType = queryType; 
  var queryUrl = quvic.QUERY_URL_MAP[queryType];
  if (queryUrl) {
    queryUrl += 'max-results=' + quvic.MAX_RESULTS_LIST +
        '&format=5&start-index=' + (((page - 1) * quvic.MAX_RESULTS_LIST) + 1);
    if (searchTerm != '') {
      queryUrl += '&q=' + encodeURI(searchTerm);
    }
    quvic.appendScriptTag(queryUrl, 
                         'searchResultsVideoListScript', 
                         'quvic.listVideosCall');
    quvic.updateNavigation(page);
   }
};

quvic.listVideosCall = function(json) {
  quvic.jsonFeed_ = json.data;
  var div = document.getElementById(quvic.VIDEO_LIST_CSS_CLASS);
  var items = json.data.items || [];
  var html = ['<dl class="videos">'];
  for (var i = 0; i < items.length; i++) {
    var title = json.data.items[i].title;
    var thumbnailUrl = json.data.items[i].thumbnail.sqDefault;
    var videoID = json.data.items[i].id;
    html.push('<dt><a href="javascript:playVideo(\''+videoID+'\',\''+addslashes(title)+'\')">');
	html.push('<img src="',thumbnailUrl,'" width="124" height="93" onmouseout="mouseOutImage(this)" onmouseover="mousOverImage(this,\'',videoID,'\',1)"></a>');
	html.push('<br/>', title.substr(0,37), '</dt>');}
    html.push('</dl><br style="clear: left;"/>');
    jQuery(div).fadeTo(500, 1.0);
    document.getElementById(quvic.VIDEO_LIST_CSS_CLASS).innerHTML = html.join('');
  if (items.length > 0) {
    loadVideo(json.data.items[0].id);
  }
};

function loadVideo(videoID) {
  swfobject.embedSWF("http://www.youtube.com/v/" + videoID + "?version=3&enablejsapi=1&playerapiid=ytplayer&fs=1",
  'player', '720', '436', '9.0.0', false, false, {allowScriptAccess: 'always',allowfullscreen: 'true'});
  }

quvic.listVideosCallback = function(json) {
 quvic.jsonFeed_ = json.data;
  var div = document.getElementById(quvic.VIDEO_LIST_CSS_CLASS);
  while (div.childNodes.length >= 1) {
    div.removeChild(div.firstChild);
    jQuery(div).fadeTo(0, '.01');
    }
  var items = json.data.items || [];
  var html = ['<dl class="videos">'];
  for (var i = 0; i < items.length; i++) {
    var title = json.data.items[i].title;
    var thumbnailUrl = json.data.items[i].thumbnail.sqDefault;
    var videoID = json.data.items[i].id;
    html.push('<dt><a href="javascript:playVideo(\''+videoID+'\',\''+addslashes(title)+'\')">');
	html.push('<img src="',thumbnailUrl,'" width="124" height="93" onmouseout="mouseOutImage(this)" onmouseover="mousOverImage(this,\'',videoID,'\',1)"></a>');
	html.push('<br/>', title.substr(0,37), '</dt>');}
    html.push('</dl><br style="clear: left;"/>');
    jQuery(div).fadeTo(500, 1.0);
    document.getElementById(quvic.VIDEO_LIST_CSS_CLASS).innerHTML = html.join('');
};
 
quvic.updateNavigation = function(page) {
  quvic.nextPage = page + 1;
  quvic.previousPage = page - 1;
  document.getElementById(quvic.NEXT_PAGE_BUTTON).style.display = 'inline';
  document.getElementById(quvic.PREVIOUS_PAGE_BUTTON).style.display = 'inline';
  if (quvic.previousPage < 1) {
    document.getElementById(quvic.PREVIOUS_PAGE_BUTTON).disabled = true;
  } else {
    document.getElementById(quvic.PREVIOUS_PAGE_BUTTON).disabled = false;
  }
  document.getElementById(quvic.NEXT_PAGE_BUTTON).disabled = false;
};
Creería q tendria q modificar ésta linea que he estado modificando:

Código: Seleccionar todo

quvic.STANDARD_FEED_URL_RECENTLY_FEATURED = 
    'http://gdata.youtube.com/feeds/api/standardfeeds/recently_featured?'; 
Bueno espero vuestras respuestas... :lee :lee
Contenido Oculto
Este foro requiere que este registrado e identificado para ver el contenido oculto.

Avatar de Usuario
leviatan21
Ex Staff
Mensajes: 8279
Registrado: 26 Mar 2008, 20:06
Género:
Edad: 55

Re: consulta sobre [BETA] YouTube Videos Mod

#2

Mensaje por leviatan21 »

Megabyte escribió:Creería q tendria q modificar ésta linea que he estado modificando:
Yo también creo que debes modificar esa URL por la del feed de tu canal en youtube
Normas de phpBB España | Normas de Soporte
No doy soporte por privado : tenga en cuenta que su problema, también puede ser el problema de otro usuario.
Cualquier mensaje privado no solicitado será ignorado :twisted:

"Education is what remains after one has forgotten everything he learned in school" - Albert Einstein

Avatar de Usuario
Megabyte
Elite
Mensajes: 1037
Registrado: 25 Dic 2010, 02:39
Edad: 45

Re: consulta sobre [BETA] YouTube Videos Mod

#3

Mensaje por Megabyte »

pero lo he intentado sin resultados...

lo cambio y ya no aparece ni el video principal, ni los de mi canal. :(

bueno, supongamos que mi canal se llama: canalphp
lo he colocado de las siguentes dos formas:

Código: Seleccionar todo

http://gdata.youtube.com/feeds/api/users/canalphp/favorites

Código: Seleccionar todo

http://gdata.youtube.com/feeds/api/users/canalphp/playlists
con y sin el signo de interrogación al final...

pero no me funciona...como iría?

grax Leviatan21...como siempre... :D
Última edición por Megabyte el 18 Jul 2011, 04:45, editado 2 veces en total.
Contenido Oculto
Este foro requiere que este registrado e identificado para ver el contenido oculto.

Avatar de Usuario
leviatan21
Ex Staff
Mensajes: 8279
Registrado: 26 Mar 2008, 20:06
Género:
Edad: 55

Re: consulta sobre [BETA] YouTube Videos Mod

#4

Mensaje por leviatan21 »

esas URL no son validas, entra a tu propio canal y busca los feeds
Normas de phpBB España | Normas de Soporte
No doy soporte por privado : tenga en cuenta que su problema, también puede ser el problema de otro usuario.
Cualquier mensaje privado no solicitado será ignorado :twisted:

"Education is what remains after one has forgotten everything he learned in school" - Albert Einstein

Avatar de Usuario
Megabyte
Elite
Mensajes: 1037
Registrado: 25 Dic 2010, 02:39
Edad: 45

Re: consulta sobre [BETA] YouTube Videos Mod

#5

Mensaje por Megabyte »

claro leviatan21, solo era un ejemplo, una suposicion, como lo indico ahi.

pero mi pregunta era si asi tenia que ir?
xq lo coloco asi, y no sale nada.

Iniciaré a meterme mas a mi canal pues youtube no ha sido mi hobbie, si alguien sabe, les agradeceré... :D
Contenido Oculto
Este foro requiere que este registrado e identificado para ver el contenido oculto.

Avatar de Usuario
leviatan21
Ex Staff
Mensajes: 8279
Registrado: 26 Mar 2008, 20:06
Género:
Edad: 55

Re: consulta sobre [BETA] YouTube Videos Mod

#6

Mensaje por leviatan21 »

indicanos cual es tu canal en YT
Normas de phpBB España | Normas de Soporte
No doy soporte por privado : tenga en cuenta que su problema, también puede ser el problema de otro usuario.
Cualquier mensaje privado no solicitado será ignorado :twisted:

"Education is what remains after one has forgotten everything he learned in school" - Albert Einstein

Avatar de Usuario
Megabyte
Elite
Mensajes: 1037
Registrado: 25 Dic 2010, 02:39
Edad: 45

Re: consulta sobre [BETA] YouTube Videos Mod

#7

Mensaje por Megabyte »

es este: canal

:mrgreen:
Contenido Oculto
Este foro requiere que este registrado e identificado para ver el contenido oculto.

Avatar de Usuario
leviatan21
Ex Staff
Mensajes: 8279
Registrado: 26 Mar 2008, 20:06
Género:
Edad: 55

Re: consulta sobre [BETA] YouTube Videos Mod

#8

Mensaje por leviatan21 »

Prueba asi :

Código: Seleccionar todo

http://gdata.youtube.com/feeds/api/users/ConectateJovenGuate/uploads

Código: Seleccionar todo

http://gdata.youtube.com/feeds/api/users/ConectateJovenGuate/playlists

Código: Seleccionar todo

http://gdata.youtube.com/feeds/api/users/ConectateJovenGuate/favorites
Normas de phpBB España | Normas de Soporte
No doy soporte por privado : tenga en cuenta que su problema, también puede ser el problema de otro usuario.
Cualquier mensaje privado no solicitado será ignorado :twisted:

"Education is what remains after one has forgotten everything he learned in school" - Albert Einstein

Avatar de Usuario
Megabyte
Elite
Mensajes: 1037
Registrado: 25 Dic 2010, 02:39
Edad: 45

Re: consulta sobre [BETA] YouTube Videos Mod

#9

Mensaje por Megabyte »

Gracias Leviatan21, ya he probado asi (segun la guia para desarrolladores ), y nada.

:(
Contenido Oculto
Este foro requiere que este registrado e identificado para ver el contenido oculto.

Avatar de Usuario
leviatan21
Ex Staff
Mensajes: 8279
Registrado: 26 Mar 2008, 20:06
Género:
Edad: 55

Re: consulta sobre [BETA] YouTube Videos Mod

#10

Mensaje por leviatan21 »

cuando vas a la página del MOD si veo que funcione, al pulsar el botón [Ver Videos] te muestra los videos que están en tu canal
Normas de phpBB España | Normas de Soporte
No doy soporte por privado : tenga en cuenta que su problema, también puede ser el problema de otro usuario.
Cualquier mensaje privado no solicitado será ignorado :twisted:

"Education is what remains after one has forgotten everything he learned in school" - Albert Einstein

Avatar de Usuario
Megabyte
Elite
Mensajes: 1037
Registrado: 25 Dic 2010, 02:39
Edad: 45

Re: consulta sobre [BETA] YouTube Videos Mod

#11

Mensaje por Megabyte »

Al entrar a la pagina del mod:

mira el mod sin modificar nada

Imagen

el mod modificando esa linea

Imagen

lo que deseo es que se vea como arriba pero con los de mi canal, sin tener q darle al boton "ver videos"

pero al modificar, desaparece el video principal, y cuando le doy al boton "ver videos" tampoco aparece el video principal, que es donde se visuualiza el video que se elige.

:lee
Contenido Oculto
Este foro requiere que este registrado e identificado para ver el contenido oculto.

Avatar de Usuario
leviatan21
Ex Staff
Mensajes: 8279
Registrado: 26 Mar 2008, 20:06
Género:
Edad: 55

Re: consulta sobre [BETA] YouTube Videos Mod

#12

Mensaje por leviatan21 »

He analizado los diferentes feeds y que algunos son generados con errores, y por eso es el problema, este es el que mejor funciona :

Código: Seleccionar todo

http://gdata.youtube.com/feeds/api/users/ConectateJovenGuate/uploads
Normas de phpBB España | Normas de Soporte
No doy soporte por privado : tenga en cuenta que su problema, también puede ser el problema de otro usuario.
Cualquier mensaje privado no solicitado será ignorado :twisted:

"Education is what remains after one has forgotten everything he learned in school" - Albert Einstein

Avatar de Usuario
Megabyte
Elite
Mensajes: 1037
Registrado: 25 Dic 2010, 02:39
Edad: 45

Re: consulta sobre [BETA] YouTube Videos Mod

#13

Mensaje por Megabyte »

será q no hay q modificar algo más? se queda igual q la segunda captura q t dejé arriba. :(

En serio te agradezco x el tiempo q t tomas para ayudarnos....pero :nolose:
Contenido Oculto
Este foro requiere que este registrado e identificado para ver el contenido oculto.

Avatar de Usuario
leviatan21
Ex Staff
Mensajes: 8279
Registrado: 26 Mar 2008, 20:06
Género:
Edad: 55

Re: consulta sobre [BETA] YouTube Videos Mod

#14

Mensaje por leviatan21 »

Megabyte escribió:será q no hay q modificar algo más? se queda igual q la segunda captura q t dejé arriba. :(

En serio te agradezco x el tiempo q t tomas para ayudarnos....pero :nolose:
Para probarlo he tenido que instalarlo y a mi me ha funcionado con esa URI
Normas de phpBB España | Normas de Soporte
No doy soporte por privado : tenga en cuenta que su problema, también puede ser el problema de otro usuario.
Cualquier mensaje privado no solicitado será ignorado :twisted:

"Education is what remains after one has forgotten everything he learned in school" - Albert Einstein

Cerrado

Volver a “Soporte de MODs”