News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

[Deprecated, use Aeva] YouTube BBCode v2.6

Started by Nao 尚, September 27, 2007, 05:51:05 PM

Previous topic - Next topic

tsmalmbe

Yes, I know that the DIV is from the template. The problem isn't the DIV per se, but rather the stylesheet. If I remove

overflow: auto;

from the .post-style in the stylesheet, your mod starts to work.

One of the most confusing debugging sessions ever. Now I have to find out what really changes if I remove that line from the stylesheet.
..:: http://www.kontrollrummet.com - Studio och musik ::.. RSS?

karlbenson

I've now uploaded v1.2 which has some minor improvements.

- Tweaked the object html code
- Fixed size protection adjustments bug (so if a user selected [youtube=1100000,800] it would resize both to default rather than just one)

tsmalmbe

How did you tweak it?  Here's my suggestion.

I could actually not find a difference between Musiconica and the default style.css, so although removing stuff from the style.css solved the problem, that was not a proper fix. So how did I resolve it? I close the div, an reopen it after the video. Also, everything related to the object has to be on one line in Subs.php to render properly.

'content' => '</div><object type="application/x-shockwave-flash" width="450" height="350" data="http://www.youtube.com/v/$1" id="ltVideoYouTube"><param name="movie" value="http://www.youtube.com/v/$1" /><param name="wmode" value="transparent" /><param name="allowScriptAcess" value="sameDomain" /><param name="quality" value="best" /><param name="bgcolor" value="#FFFFFF" /><param name="FlashVars" value="playerMode=embedded" /></object><div class=post">',

AND

'content' => '</div><object type="application/x-shockwave-flash" width="$2" height="$3" data="http://www.youtube.com/v/$1" id="ltVideoYouTube"><param name="movie" value="http://www.youtube.com/v/$1" /><param name="wmode" value="transparent" /><param name="allowScriptAcess" value="sameDomain" /><param name="quality" value="best" /><param name="bgcolor" value="#FFFFFF" /><param name="FlashVars" value="playerMode=embedded" /></object><div class="post">',
..:: http://www.kontrollrummet.com - Studio och musik ::.. RSS?

karlbenson

Being on more than one line shouldn't affect it. (in fact nice html should be tabbed out)
However that said, the tweak which I copied from my other bbcode make makes it to appear on one line. (even though its shown on multiple lines in the subs.php)

I thought of doing a <close></open> hack myself, however it would affect ajax editing.
The div is there for a reason (and that css line).

I believe it just means that sometimes you have to click to focus on the clip and then again to make it play. (as far as I'm aware all the other embed mods will also have the same issue)

tsmalmbe

Quote from: karlbenson on October 07, 2007, 03:57:32 PM
Being on more than one line shouldn't affect it. (in fact nice html should be tabbed out)
However that said, the tweak which I copied from my other bbcode make makes it to appear on one line. (even though its shown on multiple lines in the subs.php)

Well, the version I installed a couple of days ago had the html split on several lines in subs.php, but only the first line was rendered. I agree that html per se should be nice, not on one line.

Quote from: karlbenson on October 07, 2007, 03:57:32 PM
I thought of doing a <close></open> hack myself, however it would affect ajax editing.
The div is there for a reason (and that css line).

I believe it just means that sometimes you have to click to focus on the clip and then again to make it play. (as far as I'm aware all the other embed mods will also have the same issue)

Care to elaborate on the ajax-issue? Did I unknowingly break something, when I added the close/open -tags? I could not get the vids to play, no matter how much I focused. Tested with Moz/IE/FF.
..:: http://www.kontrollrummet.com - Studio och musik ::.. RSS?

karlbenson

I believe that the id tag on the <div> is used for the ajax modify(quick edit) and your hack is likely to break it.
In otherwords the <div> is there for a reason.

In IE7, Firefox 2.0.07/ Opera the youtube videos all play for me (with both the earlier versions of this mod and also the  new one)

tsmalmbe

Well, it has to be the Musiconica-template itself that is screwing this up for me somehow. That is the only differing factor as far as I can see.
..:: http://www.kontrollrummet.com - Studio och musik ::.. RSS?

Krysia

Quote@ Krysia ~ Sorry for not posting before now, I've tested and tested and still am not able to reproduce the bug you report.  However I have tweaked the flash code and fixed a minor issue with sizes and hope to upload version 1.2 later tonight.
I reported a bug?



asdas2

Quote from: karlbenson on October 07, 2007, 01:07:55 PM
@asdas2 ~ I have started/nearly finished a metacafe one, however it will be a while before its approved (maybe weeks)

@ tsmalmbe ~ Does the play button appear.  The youtube flash player button is sometimes a bit dodgy and you have to click it more than once to get it to play.

@ Krysia ~ Sorry for not posting before now, I've tested and tested and still am not able to reproduce the bug you report.  However I have tweaked the flash code and fixed a minor issue with sizes and hope to upload version 1.2 later tonight.



Thankz karlbenson i m waitng for it
www.chillparadise.com

for all desi people .... get everything u ever wanted.... log in to view hidden stuff.

karlbenson

Krysia  lol maybe not :)

I probably meant tsmalmbe.  Its just I was in a rush to fix the bug as I had something else to do.  Must have c+p'd the wrong name ;)

Asda2.  ~ Metacafe one will be submitted to SMF Customize area in an hour or so (once I've done some testing).  Although it will not be available for download until smf approves it.

Kays

Hi, nice mod. It even works if "search=" is left in the url.

I have run across a bit of a funky problem though (SMF 1.1.4).  If a post or edit is submited when there are only the youtube tags and no other text I'll get a "The message body was left empty." error. Add a smilie to the message and it's happy.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

karlbenson

yeah you must have some other content in the post besides the youtube tag.  Thats required by smf not by this mod.

Kays

Thanks. :)

You know, that after using the boards for over two years now, I've never noticed that. I'm assuming the same applies to all BBC tags then.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

karlbenson

I'm unsure whether it applies to most bbc tags

Off hand I'm unsure whether its all of them.

Kays

Well not all, color= is regularly used for a whole post. I would of thought that it would apply the the img, code and quote tags. But it doesn't. I just checked.

If at first you don't succeed, use a bigger hammer. If that fails, read the manual.
My Mods

falguni1

I am using this mod and it works smoothly

The Kruzzen Guy

I installed the mod and I don't have post.template.php in my other themes, i dont use the original theme that comes with SMF, I use 1.1.4 version and have installed latest version of your mod. When I test mod out in forum...i get nothing but "click to activate control" and then after click, nothing is there.

See it at:
http://forum.kruzzen.com/index.php?topic=867.0 [nofollow]

If its on my end, the issue, I apologise. Thanks.
Thanks,
~Shawn

My SMF Forums:
All-Topics [nofollow] | Freemasonry & Co-Masonry [nofollow] | Weather & Climate Change [nofollow]

karlbenson

@ The Kruzzen Guy
You don't appear to be using my YouTube Mod
but either
http://custom.simplemachines.org/mods/index.php?mod=390
or the other one which was recently removed from SMF site for security reasons.

I can tell this because the html embed code doesnt match that used by my mod.

The reason why its not working at the moment is because the one you are using ONLY works with the id of the video whereas a complete youtube url has been entered.

I would recommend uninstalling the one you have installed and grab a latest copy of mine from
http://custom.simplemachines.org/mods/index.php?mod=936

EgAr

Hi
for spanish  and  spanish_es

$txt['youtube'] = 'YouTube';
$txt['youtube_invalid'] = '#Link de YouTube Inválido#';




for spanish-utf8 and spanish_es-utf8

$txt['youtube'] = 'YouTube';
$txt['youtube_invalid'] = '#Link de YouTube Inv&aacute;lido#';



Saludos   :D

karlbenson


Advertisement: