fnds Posted September 16, 2008 at 04:33 PM Report #210970 Posted September 16, 2008 at 04:33 PM import urllib import re interprete, titulo = re.search(re.compile('<div id="pub_marquee"><MARQUEE WIDTH\ ="100%" scrolldelay="150" BEHAVIOR="SCROLL" ><span class="txtmarquee">A TOCAR A\ GORA : (.+) - (.+)</span></MARQUEE></div>'),\ urllib.urlopen("http://www.rfm.pt/p_quemusicaera.aspx").read().replace("\r\n",\ "")).groups() print "%s - %s" % (interprete, titulo) 😛
softklin Posted September 16, 2008 at 05:05 PM Report #210982 Posted September 16, 2008 at 05:05 PM fnds, se calhar em vez de ires buscar a essa tabela, seria mais fácil ires buscar à marquee que está a rolar do lado direito, onde diz "Oiça aqui" "a tocar agora:" Nick antigo: softclean | Tens um projeto? | Wiki P@P Ajuda a comunidade! Se encontrares algo de errado, usa a opção "Denunciar" por baixo de cada post.
fnds Posted September 16, 2008 at 05:12 PM Author Report #210984 Posted September 16, 2008 at 05:12 PM Já funciona bem. softclean, era isso que estava a fazer.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now