Igor Gariev (gariev) wrote in changelog,
Igor Gariev
gariev
changelog

[livejournal] r17933: LJSUP-7606: Sharing from YouTube to LJ -...

Committer: gariev
LJSUP-7606: Sharing from YouTube to LJ - URL modification

U   trunk/htdocs/update.bml
Modified: trunk/htdocs/update.bml
===================================================================
--- trunk/htdocs/update.bml	2010-12-15 04:40:41 UTC (rev 17932)
+++ trunk/htdocs/update.bml	2010-12-15 04:59:06 UTC (rev 17933)
@@ -140,7 +140,7 @@
     if ($url) {
         ## currently, the URL is for YouTube only.
         ## in future support for other quick embeds will be added.
-        if ($url =~ m!http://www.youtube.com/watch\?v=(\w+)!) {
+        if ($url =~ m!http://www.youtube.com/watch\?v=(\w+)! || $url =~ m!http://www.youtube.com/v/(\w+)!) {
             $event .= <<"EMBED";
 <object width="640" height="385"><param name="movie" value="http://www.youtube.com/v/$1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/$1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="640" height="385"></embed></object>
 EMBED

Tags: bml, gariev, livejournal
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments