http://www.zubrag.com/scripts/website-thumbnail-generator.php http://forums.digitalpoint.com/showthread.php?t=101760
i have this youtube thumb script but i cant get the thunbs to show up. i need....... http://img.youtube.com/vi/ySk1UCUV4bo/default.jpg but im getting............. http://img.youtube.com/vi/ySk1UCUV4bo&feature=youtube_gdata/default.jpg How do i correct the take out the &feature=youtube_gdata line? the code for php is. <?php function yt($ytsearch) { global $ytcurrenttag; global $ytvids; global $ytid; $ytvids = array(); $ytid=0; function ytinsidethetag($ytparser, $ytdata){ global $ytcurrenttag; global $ytvids; global $ytid; if(!strcmp(strtolower($ytcurrenttag)… { $ytvids[$ytid]['type'] = "yt"; $ytvids[$ytid]['title']=$ytdata; $ytvids[$ytid]['title'][0] = ucwords($ytvids[$ytid]['title'][0]); } } function ytopentag($ytparser, $ytdata, $ytattr=''){ global $ytcurrenttag; $ytcurrenttag = $ytdata; global $ytvids; global $ytid; if(!strcmp(strtolower($ytcurrenttag)… { $ytvids[$ytid]['link']=str_replace(… $ytvids[$ytid]['thumb']=str_replace… $ytvids[$ytid]['thumb'].="/default.… } } function ytclosetag($ytparser, $ytdata){ global $ytid; if(!strcmp(strtolower($ytdata),"entr… $ytid++; } $ytxml_parser = xml_parser_create(); xml_set_element_handler($ytxml_parser… "ytopentag", "ytclosetag"); xml_set_character_data_handler($ytxml… "ytinsidethetag"); include("fetch.php"); $ytdata = fetchrssyt("http://gdata.youtube.com/fee… if(!(xml_parse($ytxml_parser, $ytdata))) die("Error on line " . xml_get_current_line_number($ytxml_parse… xml_parser_free($ytxml_parser); return $ytvids; } ?> thanks
thumbnails will obviously be faster if there are more than a few pages... but I played with just shrinking a page inside an iframe and it worked for a bit and then I broke it somehow. heres what I had by that point... <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <style type="text/css"> body {width:100%;} .frameclass { zoom:.3!important; /* the zoom worked earlier but not anymore ??? */ } .frameclass2 {width:90%; height:90%; zoom:2!important;} </style> <title></title> </head> <body> <div> <div style="float:left;"> <button style="vertical-align:top;" onclick="return changeFrameClass('frameid')">click</button> </div> <div style="float:left;clear:left;"> <button style="vertical-align:top;" onclick="return changeFrameClass('frameid2')">click</button> </div> </div> <div> <iframe src="http://news.bbc.co.uk/2/hi/5098706.stm" name="framename" class="frameclass" id="frameid2" scrolling="no" frameborder="yes"> </iframe> <iframe src="http://news.bbc.co.uk/2/hi/5098706.stm" name="framename" class="frameclass" id="frameid" scrolling="no" frameborder="yes"> </iframe> </div> <script type="text/javascript"> function changeFrameClass(id){ var t = document.getElementById(id); t.className = t.className=='frameclass2' ? 'frameclass' : 'frameclass2'; } </script> </body> </html>