I get array like:
Array ( [0] => url=website1.com/etcetcetc&itag=43&quality=medium&something=nill
[1] => url=website2.com/etcetcetc&itag=18&quality=medium&something=nill
[2] => url=website3.com/etcetcetc&itag=5&quality=small&something=nill
[3] => url=website4.com/etcetcetc&itag=36&quality=small&something=nill
[4] => url=website5.com/etcetcetc&itag=17&quality=small&something=nill )
and after using foreach($links as $link)
, I get these arrays like:
Array ( [url] => website.com1/etcetcetc [itag] => 43 [quality] => medium [something] => nill )
Array ( [url] => website.com2/etcetcetc [itag] => 18 [quality] => medium [something] => nill )
Array ( [url] => website.com3/etcetcetc [itag] => 5 [quality] => small [something] => nill )
Array ( [url] => website.com4/etcetcetc [itag] => 36 [quality] => small [something] => nill )
Array ( [url] => website.com5/etcetcetc [itag] => 17 [quality] => small [something] => nill )
How can I show selected links from it?
I want to show links with itag
: 43 , 18 , 36. It checks if URL with one of those is available . If available, then show it's URL. It can be 1, 2 or 3 links, meaning if the link with itag
43 and 18 is available, then it shows the 2 URLs and if all 3 itag
links are available then it shows those 3 links.
The url is different every time, so I can't save url in php, meaning it always has to take URL/link from array.
Currently I am showing it like:
echo '<a href="'.$r['url'].'">quality: '.$r['itag'].'</a>';
------- edit ------
here is the script/code in which i want to do that (it was made by one of my friend but he is not there now a days )
foreach($links as $link) {
echo '<a href="'.$r['url'].'">quality: '.$r['itag'].'</a><br />';
}