What I would do is I from the source code of the page (although I'm not sure that the links either directly marked in the source code on all sites. So I create a variable string containing the source code for the page (it must surely be way to do this automatically, but I do not know that action).
However, imagine that we get and we put this string in the variable:
Code:
code_source = "source code";
then it should know how many characters contains the source code to know when to stop searching:
Code:
nb_characters_code_source = code_source.length;
and once you done all it creates a table to save the search results.
Code:
resultat_mp3 = new Array;
Then, since it seeks the string. "mp3" which is 4 characters, we're gonna do a search on 4 characters in both advancing each time of 1 character ... you follow me?
Code:
for (cpt = 0; cpt <= nb_caracteres_code_source; cpt + +) (
code_source.substring search = (cpt, cpt +4);
if (search ==. "mp3") (
resultat_mp3 [cpt] = ". mp3";
)
)
but now you only know where the strings. "mp3". we must still seek the full url ... however, they are probably stuck between two quotes. We must therefore seek what is between "and. ... mp3
Code:
nb_cellules_resultat_mp3 = resultat_mp3.length;
for (cpt = 0; cpt <= nb_cellules_resultat_mp3; cpt + +) (
if (resultat_mp3 [cpt]! = "") (
i = 1;
while (code_source.substring (cpt)! ='"'){
resultat_mp3 [cpt] = code_source.substring (cpt-i-1, CPT-i) + resultat_mp3 [cpt];
i = i + 1;
)
)
)
and then, normally, you should have a table with all your url.
That's all I can do. I hope this is not what you already knew.
Bookmarks