Hi I have a txt file and 15 000 youtube codes per line like HqiHRC4Q_Ac in it.I want to add "http://www.youtube.com/watch?v=" and create full youtube urls from this codes. How can I do it ? I have : video codes ekJbxA6JOAU AJWjZ-dOKgI I want to create full urls like http://www.youtube.com/watch?v=ekJbxA6JOAU Thanks
Dump your youtube codes text file into a database with a FIELD NAME of "dummy" where the size of the FIELD NAME is long enough for your longest URL then do this: REPLACE dummy WITH "http://www.youtube.com/watch?v=" + dummy ALL Then dump your database back to a text file.
$url = "http://www.youtube.com/watch?v="; $file = "youtube.txt"; $f = fopen($file, "r"); while($line = fgets($f, 1000)){ $full_path = $url.$line; echo $full_path."<br/>"; }