|
Compartir este tema:
|
El 24 marzo, 2011 · 0 Comentarios
Nombre del Programa: WS Downloader
Versión del Programa: 0.1 (Beta)
Autor(es): Sebastián Castaño (.:WindHack:.) y Carlos Sánchez (swik)
Sistema Operativos: Multiplataforma.
- Lenguaje en que fue programado: Python 2.6.x
Licencia bajo la que fue liberado: Creative Commons Reconocimiento-NoComercial-CompartirIgual 3.0 , Ver Registro en SafeCreative.org
Fecha de lanzamiento: 17 de noviembre de 2010
Idioma(s): Español
Funcionalidad/Tópico del Programa: Script para descargar directamente vídeos de YouTube.
Captura de pantalla del programa ejecutándose: NA
Código:
#!/usr/bin/env python # -*- coding: utf-8 -*- # WS Downloader.py - v0.1 (Beta) # Autor(es): .:WindHack:. & swik # :www.daw-labs.com | :www.cibernodo.net # Registrado en SafeCreative # Licencia: Creative Commons Reconocimiento-NoComercial-CompartirIgual 3.0 # 17/11/2010 import sys, urllib, os # # @Charset # Char = ['%3A','%2F','%26','%2C','%3D','%252C','%253A','%7C','%3F'] By = [':','/','&',',','=',',',':','','?'] # # URLDecode(sURL) # Descifra la URL teniendo en cuenta el Charset. # def URLDecode(sURL): for i in range(len(Char)): sURL = sURL.replace(Char[i],By[i]) return sURL # # GetSourceCode(sURL) # Obtiene el código de fuente del vídeo (sitio). # def GetSourceCode(sURL): try: URL = urllib.urlopen(sURL) sSource = URL.read() URL.close() return sSource except: print 'Error de conexión.' exit() # # GetIndexVideo(sSource,Tags) # Obtiene la posición de un "Tag" o etiqueta. # def GetIndexVideo(sSource,Tags): return sSource.find(Tags) # # GetVideoTitle(sSource) # Obtiene el título del vídeo. # def GetVideoTitle(sSource): sSource = sSource[2000:5500] Begin = GetIndexVideo(sSource,'
Categoria Código Abierto, General
