Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: xPandax on July 12, 2013, 02:36:25 PM

Title: Simple Youtube Video Embedder/BBC
Post by: xPandax on July 12, 2013, 02:36:25 PM


Simple Youtube Video Embedder/BBC
(For SMF 2.0.x)
Mod by xPandax | Other Mods (http://custom.simplemachines.org/mods/index.php?action=profile;u=158159) by xPandax


Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=3751) | Support Thread for this Mod (http://www.simplemachines.org/community/index.php?topic=507505.0)


Features

Who should use this Mod
If you are one of the people who use only youtube videos & playlist in your forum then this is the mod that you're looking for.


How-To
Youtube video links are parsed & displayed automatically. Just post the youtube links as plain text.

Youtube links wrapped within [url] tags won't be parsed as videos. If you wrap a link within [url] tags, then it means you are forcing youtube links to be displayed as url.

Correct: Hi, checkout this youtube video, http://www.youtube.com/watch?v=yVpbFMhOAwE

Incorrect: Hi, checkout this youtube video, [url]http://www.youtube.com/watch?v=yVpbFMhOAwE[/url]

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fcustom.simplemachines.org%2Fmods%2Findex.php%2Faction%2Cdownload%2Fmod%2C3751%2Fid%2C224268%2Fimage&hash=87fda8f290dd3d9d9f7c148967cd3bb4da6662b8)


Supported Themes
Works on all the themes without any custom edits!


Supported SMF Versions
Tested on fresh installation of 2.0.4.


Supported Languages
Translations to other languages are welcome. Please post them in this Support Thread for this Mod (http://www.simplemachines.org/community/index.php?topic=507505.0).


Support
If you need support with this mod, please use the Support Thread for this Mod (http://www.simplemachines.org/community/index.php?topic=507505.0).


Changelog
v2.0 - Mod totally rewritten using hooks (13 March 2014)
v1.1 - Just a maintenance release.
v1.0



License

This is free and unencumbered mod released into the public domain. For more information, see http://unlicense.org/ (http://unlicense.org/) or the accompanying UNLICENSE file.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Dzonny on July 12, 2013, 02:38:24 PM
Nice and clean :)

If i can i would suggest to consider making a bbc button for this :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: 4Kstore on July 12, 2013, 02:47:47 PM
Congratulations, nice mod and it's really very simple and efficient ...
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Shambles on July 12, 2013, 04:44:24 PM
Your links aren't working (as before) ;)


(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi.imgur.com%2FI1iPxpt.jpg&hash=3d78c47a37c75348da04233da4321d448c28dd84)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 13, 2013, 09:10:07 AM
Quote from: Dzonny on July 12, 2013, 02:38:24 PM
Nice and clean :)

If i can i would suggest to consider making a bbc button for this :)
Thank you very much.

I thought of making a bbc button but this mod automatically parses youtube links & displays them as videos which is the core feature. So I dropped the idea of adding a bbc.


Quote from: 4Kstore on July 12, 2013, 02:47:47 PM
Congratulations, nice mod and it's really very simple and efficient ...
Thank you very much.


Quote from: Shambles on July 12, 2013, 04:44:24 PM
Your links aren't working (as before) ;)
Thank you very much and I've fixed the links.  O:)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Dzonny on July 13, 2013, 09:36:39 AM
Quote from: xPandax on July 13, 2013, 09:10:07 AM
Quote from: Dzonny on July 12, 2013, 02:38:24 PM
Nice and clean :)

If i can i would suggest to consider making a bbc button for this :)
Thank you very much.

I thought of making a bbc button but this mod automatically parses youtube links & displays them as videos which is the core feature. So I dropped the idea of adding a bbc.

Yeah, that's right, make sense to me :)

Keep up the good work! :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 13, 2013, 10:10:49 AM
Quote from: Dzonny on July 13, 2013, 09:36:39 AM
Quote from: xPandax on July 13, 2013, 09:10:07 AM
Quote from: Dzonny on July 12, 2013, 02:38:24 PM
Nice and clean :)

If i can i would suggest to consider making a bbc button for this :)
Thank you very much.

I thought of making a bbc button but this mod automatically parses youtube links & displays them as videos which is the core feature. So I dropped the idea of adding a bbc.

Yeah, that's right, make sense to me :)

Keep up the good work! :)
Thank you very much. :D
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Venera on July 15, 2013, 08:24:39 AM
Nice mod. Thank you. (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.venerinsan.com%2FSmileys%2Fdefault%2FLaie_98.gif&hash=f3ea63ecd1477a4e0eb362c9da1c6c83375a01bd)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 15, 2013, 11:45:07 AM
Quote from: Venera on July 15, 2013, 08:24:39 AM
Nice mod. Tahnk you. (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.venerinsan.com%2FSmileys%2Fdefault%2FLaie_98.gif&hash=f3ea63ecd1477a4e0eb362c9da1c6c83375a01bd)
You're welcome, thank you.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Butjam on July 21, 2013, 07:52:19 PM
Hi, I've just tried to install this on a forum and I'm having a bit of an issue. I'm more a day to day 'stop the place from falling apart' admin than the other two, so I'm woefully out of my depth in this. Attempts to contact my colleagues have been unsuccessful.... so I'll try this!

I get this error:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fimg39.imageshack.us%2Fimg39%2F821%2Fihoo.png&hash=d895fe33fc5ac3b9ffe2f99428307932d2e2ca2a)
Followed by:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi.imgur.com%2FoQlsAC3.png&hash=a044d38c66e5d26a968180aced4e441a9b8d66b1)

Like I said, my technical skill is next to nothing, so I can only assume there is a conflict with another package, listed here:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi.imgur.com%2FmfqgDBB.png&hash=e143b981208ea7afcba1df4961e97e8984a6edab)

Any and all help is great, thanks!
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 21, 2013, 10:51:53 PM
Well just now the mod was updated. Improved the edits done by the package to fix/minimise the clash with other mods during install/uninstall operations. I suggest you to try the new version 1.1.

If you face the error even with version 1.1, then upload your Post.php file here and ill do the edit for you. :)

Actually its a simple edit which you can try yourself. Browse to your forum_directory/Sources/Post.php.

You'll find the following tag twice in the Post.php file.
Code (find) Select
<img>


Add the following code before <img> in both the places.
Code (add before) Select
<object><embed><iframe>
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Butjam on July 22, 2013, 02:43:34 PM
Your update worked perfectly, actually, just downloaded and installed with ease, thank you very much
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 23, 2013, 02:55:42 AM
Thanks & you're welcome. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: rajeshvv on July 23, 2013, 03:12:46 AM
Hi.. I installed 1.0 version which is working gr8...now the version updated to 1.1
what is the process for updating the mod ?
just uninstalling the 1.0 and installing the 1.1 ?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 23, 2013, 04:36:24 AM
Quote from: rajeshvv on July 23, 2013, 03:12:46 AM
Hi.. I installed 1.0 version which is working gr8...now the version updated to 1.1
what is the process for updating the mod ?
just uninstalling the 1.0 and installing the 1.1 ?

Yes, that's right. But this is just a maintenance release. :)

Changelog
v1.0 - Initial release.
v1.1 - Just a maintenance release.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Ricky. on July 27, 2013, 01:33:23 AM
Nice work .. simple and effective..
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 27, 2013, 04:33:26 AM
Quote from: Ricky. on July 27, 2013, 01:33:23 AM
Nice work .. simple and effective..

Thank you very much. :D
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Malibuz0r on July 29, 2013, 06:57:13 PM
Hey I have a problem with this mod and Simpleportal's default shoutbox. Whenever I post a youtube link in that shoutbox, it cuts off the link and leaves the id wrapped around the youtube bbc tag. Is there a way to fix this?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 30, 2013, 02:23:37 AM
Quote from: Malibuz0r on July 29, 2013, 06:57:13 PM
Hey I have a problem with this mod and Simpleportal's default shoutbox. Whenever I post a youtube link in that shoutbox, it cuts off the link and leaves the id wrapped around the youtube bbc tag. Is there a way to fix this?

I'm not sure if youtube videos can be embedded in simple portal's shoutbox. You have to ask simple portal devs regarding that issue.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Malibuz0r on July 30, 2013, 05:11:08 AM
No no, that's not what I want. Whenever I post a youtube URL, a complete URL in the shoutbox, it cuts off the link and leaves it like:
. Which makes the URL unclickable.. I want it to show the full url. This only started happening after I installed the mod.

PS: Don't want to embed videos on the shoutbox.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: sadiahassan41 on July 30, 2013, 07:51:13 AM
thanks for this mods its a very simple and useful mod i thanks again the developer of this mod.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: azirion on July 30, 2013, 02:13:00 PM
Hi

I'm having trouble with this wonderful mod. It doesn't seem to work right in my site. When I post a YouTube video, it opens up a black video box on the thread but with an error that says the video is not available. It happens with any youtube video  :( any ideas?

I'm using the core theme and the SPortal mod

Thanks in advance for any help  ;)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on July 31, 2013, 03:26:44 AM
Quote from: Malibuz0r on July 30, 2013, 05:11:08 AM
No no, that's not what I want. Whenever I post a youtube URL, a complete URL in the shoutbox, it cuts off the link and leaves it like:
. Which makes the URL unclickable.. I want it to show the full url. This only started happening after I installed the mod.

PS: Don't want to embed videos on the shoutbox.

Unfortunately, that's how this mod works (i.e. youtube links will be automatically wrapped within [youtube] tags.. So, if you want to post youtube url as clickable links, you should wrap them with [url] tags.



Quote from: sadiahassan41 on July 30, 2013, 07:51:13 AM
thanks for this mods its a very simple and useful mod i thanks again the developer of this mod.
Thanks & you're welcome. :)



Quote from: azirion on July 30, 2013, 02:13:00 PM
Hi

I'm having trouble with this wonderful mod. It doesn't seem to work right in my site. When I post a YouTube video, it opens up a black video box on the thread but with an error that says the video is not available. It happens with any youtube video  :( any ideas?

I'm using the core theme and the SPortal mod

Thanks in advance for any help  ;)
Did the mod install without any error?

Are there any other youtube video related mods installed in your forum? If so then you should remove any one of the mods.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: azirion on July 31, 2013, 10:43:57 PM
Quote from: xPandax on July 31, 2013, 03:26:44 AM
Did the mod install without any error?

Are there any other youtube video related mods installed in your forum? If so then you should remove any one of the mods.
Yep installed with no errors. And no, there is no other video mod. As a matter of fact the only mod installed is the SimplePortal mod.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 01, 2013, 04:25:14 AM
Quote from: azirion on July 31, 2013, 10:43:57 PM
Quote from: xPandax on July 31, 2013, 03:26:44 AM
Did the mod install without any error?

Are there any other youtube video related mods installed in your forum? If so then you should remove any one of the mods.
Yep installed with no errors. And no, there is no other video mod. As a matter of fact the only mod installed is the SimplePortal mod.

This mod does not have any issues with simple portal.

Could you please post a link to a thread in your forum that has a youtube video link in the post. Also could you kindly attach the Subs.php file which you can find in the Sources directory.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: azirion on August 01, 2013, 12:05:34 PM
Ok here's the example:

http://acuarioscr.com/index.php?topic=221.msg1704;topicseen#new

I'm still trying to figure out how to attach the subs.php file with my cellphone  :-\
Title: Re: Simple Youtube Video Embedder/BBC
Post by: azirion on August 01, 2013, 12:34:42 PM
Here's another example from a forum with guest permissions:

Go to the bottom of: http://acuarioscr.com/index.php?topic=22.new#new
Title: Re: Simple Youtube Video Embedder/BBC
Post by: azirion on August 01, 2013, 12:47:13 PM
Ok here's something weird: in this post there are 2 videos. One doesn't show up but the next one looks perfect  ???  http://acuarioscr.com/index.php?topic=202.0

Any ideas here?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: azirion on August 01, 2013, 09:24:15 PM
Hi

Finally I got to my computer, here´s the Subs.php file you asked
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 02, 2013, 03:11:26 AM
Quote from: azirion on August 01, 2013, 09:24:15 PM
Hi

Finally I got to my computer, here´s the Subs.php file you asked

Ok, I figured out the issue. There mod is working fine and there are no compatibility issues with the mods installed in your forum.

I check the source code of the thread in this link, http://acuarioscr.com/index.php?topic=221.0.

The issue is that some random span style tags gets inserted automatically.

<span style="width: 0; margin: 0 -0.6ex 0 -1px;"> </span>

And if you check the above code, there is just a "space" between the span tags. I don't have any idea how that "space" gets into the video links.

This does not happen just with youtube videos, it happens with posts that has only text too. Please check the attached pictures.



I think this has something to do with the language settings used in your forum but I'm not sure. You may try posting this issue (along with the pictures) in the language specific support board. Thanks. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: donut42day on August 07, 2013, 07:53:33 AM
hi xPandax can u kindly help to edit my Post.php? can't locate the <img>
Title: Re: Simple Youtube Video Embedder/BBC
Post by: electricwildflower on August 07, 2013, 08:28:14 AM
OMG Thank you i have wanting to update my forum with a much simple way of youtube inbedding for ages but never got round to looking for a replacement for the large avemedia mod. Replaced avemedia in my test forums and embeds the videos like normal. I no longer have to have avemedia installed and disabled enough to just let forum video posting.

Again Thanks for fantastic mod.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 07, 2013, 09:46:44 AM
Quote from: donut42day on August 07, 2013, 07:53:33 AM
hi xPandax can u kindly help to edit my Post.php? can't locate the <img>

I've edited the file. Please check the attachment. :)

For your reference, you can find the <img> tag 2 times in Post.php.

#1 - Line 1524
#2 - Line 2730


Quote from: electricwildflower on August 07, 2013, 08:28:14 AM
OMG Thank you i have wanting to update my forum with a much simple way of youtube inbedding for ages but never got round to looking for a replacement for the large avemedia mod. Replaced avemedia in my test forums and embeds the videos like normal. I no longer have to have avemedia installed and disabled enough to just let forum video posting.

Again Thanks for fantastic mod.

You're welcome and thank you very much.  :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: donut42day on August 07, 2013, 02:03:33 PM
Quote from: xPandax on August 07, 2013, 09:46:44 AM
Quote from: donut42day on August 07, 2013, 07:53:33 AM
hi xPandax can u kindly help to edit my Post.php? can't locate the <img>

I've edited the file. Please check the attachment. :)

For your reference, you can find the <img> tag 2 times in Post.php.

#1 - Line 1524
#2 - Line 2730

Tks for your help and quick respond  xPandax  :D 
After editing my Class-Package.php from 32m to 128m, your mod work instantly ! Greatly appreciate your work, thanks again  :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 08, 2013, 03:39:31 AM
Quote from: donut42day on August 07, 2013, 02:03:33 PM
Tks for your help and quick respond  xPandax  :D 
After editing my Class-Package.php from 32m to 128m, your mod work instantly ! Greatly appreciate your work, thanks again  :)

Glad to help. Thanks. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Hypnos76 on August 12, 2013, 09:40:06 AM
Just installed this (it was my first MOD) and it seems to work perfect vary clean light and fast. Thanks :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 12, 2013, 10:19:59 AM
Quote from: Hypnos76 on August 12, 2013, 09:40:06 AM
Just installed this (it was my first MOD) and it seems to work perfect vary clean light and fast. Thanks :)

Thanks & you're welcome. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: granddaddy on August 13, 2013, 01:48:39 PM
Thanks for the wonderful mod. It works great.

Is it possible to support linking videos with a specific time stamp? e.g. ending with t=1m44s
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 14, 2013, 04:29:42 AM
Quote from: granddaddy on August 13, 2013, 01:48:39 PM
Thanks for the wonderful mod. It works great.

Is it possible to support linking videos with a specific time stamp? e.g. ending with t=1m44s

Sorry, its not possible to link a video with time stamp as this mod uses regex which extracts just the video id from the url and then embed that video id in the code to display the video. Thanks.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: electricwildflower on August 14, 2013, 08:31:22 AM
I have a problem well not sure if it's a problem that i need help with.

I was using avemedia and switched to your mod as it's much better now when i add a video just using the youtube url it works fine and shows up but when anyone else posts a url it just shows up the url but clickable and nothing more.

Also the links that where posted before i removed avemedia and added your mod show up as band name - name of song and this is clickable.

Here is a link to my video posting section does it look alright for you or does it come up with as i stated above.

http://keepitrealkeepitgoth.com/forum/index.php/topic,264.0.html (http://keepitrealkeepitgoth.com/forum/index.php/topic,264.0.html)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 15, 2013, 05:15:21 AM
Youtube links wrapped within 'url' tags won't be parsed as videos.

I think the members of your forum are posting youtube links using 'url' tags.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: electricwildflower on August 15, 2013, 08:54:50 AM
I will have to check it out just to make sure but when using ave media i stated to my members to post a link you just copy a url and nothing more.  But some might do it the other way i will see how they post and make sure there not using the wrapped way.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 16, 2013, 02:51:53 AM
Quote from: electricwildflower on August 15, 2013, 08:54:50 AM
I will have to check it out just to make sure but when using ave media i stated to my members to post a link you just copy a url and nothing more.  But some might do it the other way i will see how they post and make sure there not using the wrapped way.

Yes, thanks. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: electricwildflower on August 18, 2013, 03:08:46 PM
It was my members fault i had to edit every post and remove the tags and have told my members it's changed so hopefully all will be cool.

Thanks
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on August 20, 2013, 06:32:19 AM
Quote from: electricwildflower on August 18, 2013, 03:08:46 PM
It was my members fault i had to edit every post and remove the tags and have told my members it's changed so hopefully all will be cool.

Thanks

Happy to help, thanks. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: sun-man on August 27, 2013, 04:23:46 AM
Hi,

is it possible to disable it - to long to explain, but my members can need that for some special-threads. [nyoutube] as an example?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: mhason on August 27, 2013, 06:32:37 AM
Hi, I am having an issue with installing this mod.
First, I installed it on a local dev. environment to make sure it works as expected. No problem here.
Then, I went ahead and installed in on my production environment.
I had a write permission error to the directory, I fixed the permission and the mod installed, but didn't work.
Looking into the file system I noticed that the mod didn't do any editing to Post.php, although it looked like installed perfect without any errors, neither in the front end or in the logs.

I can go ahead and edit Post.php manually but I don't understand why the installation didn't do this.
Any ideas?

Thanks in advance
Maurice
Title: Re: Simple Youtube Video Embedder/BBC
Post by: impreza on August 27, 2013, 08:44:21 AM
Very good modification, works without a problem
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on August 27, 2013, 08:50:06 PM
Quote from: sun-man on August 27, 2013, 04:23:46 AM
Hi,

is it possible to disable it - to long to explain, but my members can need that for some special-threads. [nyoutube] as an example?

It does not have that functionality included, unfortunately.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on August 27, 2013, 08:51:03 PM
Quote from: mhason on August 27, 2013, 06:32:37 AM
Hi, I am having an issue with installing this mod.
First, I installed it on a local dev. environment to make sure it works as expected. No problem here.
Then, I went ahead and installed in on my production environment.
I had a write permission error to the directory, I fixed the permission and the mod installed, but didn't work.
Looking into the file system I noticed that the mod didn't do any editing to Post.php, although it looked like installed perfect without any errors, neither in the front end or in the logs.

I can go ahead and edit Post.php manually but I don't understand why the installation didn't do this.
Any ideas?

Thanks in advance
Maurice

Hi Maurice,

I am sorry to hear that you are having issues with this modification. Feel free to make the edit to the file manually, but remember to backup. Let us know how it goes.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: fatyhxd41 on August 31, 2013, 11:30:13 AM
Hey all. I was installed this mod and was working well. Today I tried to intall a mod but cant. Then remove some files from my FTP and replace them with originals (subs.php and more some files i can't remember now their names). And now this mod not working. Im using
. But not working..
Title: Re: Simple Youtube Video Embedder/BBC
Post by: electricwildflower on August 31, 2013, 03:11:22 PM
fatyhxd41

Have you tried going through the manual install steps relevant to your smf install version and check them with your installed files to see if any of the code is missing.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 03, 2013, 01:13:53 AM
I just installed this mod on SMF 2.0.5. It installs just fine. No errors. This is the only mod installed for youtube. I tried the manual update you have posted. Nogo! Attached are my post and subs files. I have also uploaded the youtube .gif to the theme bbc directory. When I make a thread on my forum there is no youtube gif button.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on September 03, 2013, 02:17:37 AM
Quote from: goodwinml on September 03, 2013, 01:13:53 AM
I just installed this mod on SMF 2.0.5. It installs just fine. No errors. This is the only mod installed for youtube. I tried the manual update you have posted. Nogo! Attached are my post and subs files. I have also uploaded the youtube .gif to the theme bbc directory. When I make a thread on my forum there is no youtube gif button.

Would you mind giving us a dummy login and link to your forum so we can have a look?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 03, 2013, 02:48:12 AM
]
Quote from: Colin on September 03, 2013, 02:17:37 AM
Quote from: goodwinml on September 03, 2013, 01:13:53 AM
I just installed this mod on SMF 2.0.5. It installs just fine. No errors. This is the only mod installed for youtube. I tried the manual update you have posted. Nogo! Attached are my post and subs files. I have also uploaded the youtube .gif to the theme bbc directory. When I make a thread on my forum there is no youtube gif button.

Would you mind giving us a dummy login and link to your forum so we can have a look?

will pm you user/pass

http://halorace.org/forum/index.php (http://halorace.org/forum/index.php)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on September 03, 2013, 02:58:02 AM
It looks like I skimmed over your question a bit too quickly. This modification does not include a BBC button. I did appear to install correctly, though. Have a look at the demo post I made (http://halorace.org/forum/index.php?action=post;msg=1468;topic=433.0)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 03, 2013, 03:02:57 AM
Quote from: Colin on September 03, 2013, 02:58:02 AM
It looks like I skimmed over your question a bit too quickly. This modification does not include a BBC button. I did appear to install correctly, though. Have a look at the demo post I made (http://halorace.org/forum/index.php?action=post;msg=1468;topic=433.0)

Saw that. But it is a link not a youtube player imbedded in post. I thought this would do this.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on September 03, 2013, 03:06:56 AM
That's because someone surrounded it with URL tags. Have a look now.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 03, 2013, 03:07:32 AM
The Mod download page has 3 example pics. All 3 show a player.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on September 03, 2013, 03:08:40 AM
Correct, which is what is showing here http://halorace.org/forum/index.php?topic=433.msg1468#msg1468
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 03, 2013, 03:12:29 AM
I just posted there and only got link. I copied address from youtube and pasted in forum. Posted and got link.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on September 03, 2013, 03:15:30 AM
Alright. I will have a glance tomorrow as soon as I can. It is past 12 am here.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 03, 2013, 03:17:23 AM
I see you have beginning and ending youtube. Did you type in or was that input by mod?

Thanks, 1 am here!
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 04, 2013, 02:18:43 PM
Still not working, anyone want to chime in? The ONLY way to get the player to show is to manually type in the youtube opening and closing brackets.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on September 05, 2013, 08:26:17 AM
@Colin - Thank you very much for providing support for this mod. :)


Quote from: sun-man on August 27, 2013, 04:23:46 AM
Hi,

is it possible to disable it - to long to explain, but my members can need that for some special-threads. [nyoutube] as an example?

In such case, just wrap the youtube links within [url] tags. Youtube links within [url] tags won't be parsed into videos.



Quote from: mhason on August 27, 2013, 06:32:37 AM
Hi, I am having an issue with installing this mod.
First, I installed it on a local dev. environment to make sure it works as expected. No problem here.
Then, I went ahead and installed in on my production environment.
I had a write permission error to the directory, I fixed the permission and the mod installed, but didn't work.
Looking into the file system I noticed that the mod didn't do any editing to Post.php, although it looked like installed perfect without any errors, neither in the front end or in the logs.

I can go ahead and edit Post.php manually but I don't understand why the installation didn't do this.
Any ideas?

Thanks in advance
Maurice

I think that the issue should have been with the file permissions.



Quote from: fatyhxd41 on August 31, 2013, 11:30:13 AM
Hey all. I was installed this mod and was working well. Today I tried to intall a mod but cant. Then remove some files from my FTP and replace them with originals (subs.php and more some files i can't remember now their names). And now this mod not working. Im using
. But not working..

Could you please attach the "Subs.php" & "Post.php" files?



Quote from: goodwinml on September 03, 2013, 01:13:53 AM
I just installed this mod on SMF 2.0.5. It installs just fine. No errors. This is the only mod installed for youtube. I tried the manual update you have posted. Nogo! Attached are my post and subs files. I have also uploaded the youtube .gif to the theme bbc directory. When I make a thread on my forum there is no youtube gif button.
Quote from: goodwinml on September 04, 2013, 02:18:43 PM
Still not working, anyone want to chime in? The ONLY way to get the player to show is to manually type in the youtube opening and closing brackets.


This mod does "not" add a youtube bbc button.

Did you enable "Automatically link posted URLs" option?

http://wiki.simplemachines.org/smf/Posts_and_Topics#Bulletin_Board_Code
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 05, 2013, 01:34:41 PM
Quote from: xPandax on September 05, 2013, 08:26:17 AM
@Colin - Thank you very much for providing support for this mod. :)


Quote from: goodwinml on September 03, 2013, 01:13:53 AM
I just installed this mod on SMF 2.0.5. It installs just fine. No errors. This is the only mod installed for youtube. I tried the manual update you have posted. Nogo! Attached are my post and subs files. I have also uploaded the youtube .gif to the theme bbc directory. When I make a thread on my forum there is no youtube gif button.
Quote from: goodwinml on September 04, 2013, 02:18:43 PM
Still not working, anyone want to chime in? The ONLY way to get the player to show is to manually type in the youtube opening and closing brackets.


This mod does "not" add a youtube bbc button.

Did you enable "Automatically link posted URLs" option?

http://wiki.simplemachines.org/smf/Posts_and_Topics#Bulletin_Board_Code

Yes it is ticked and does not work. See attached pic
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on September 06, 2013, 01:49:45 PM
Could you please PM me a demo login. And could you attach the Subs.php & Post.php files again. Thanks.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 06, 2013, 03:15:47 PM
Here you go.

Title: Re: Simple Youtube Video Embedder/BBC
Post by: Rayleigh on September 06, 2013, 06:13:52 PM
Hi!
First of all, thanks for your mod, it works as smooth as butter and is perfect!

Is it possible to adjust the size of the youtube window? If yes, can you tell me how? If not, is it possible to add that feature to your mod?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on September 07, 2013, 05:27:13 AM
Quote from: goodwinml on September 06, 2013, 03:15:47 PM
Here you go.

Ok, the mod is working the way it should. The youtube links posted by you were not parsed into videos because you wrapped it within [url] tags. If you wrap a link within [url] tags, then it means you are forcing it to be displayed as url. Kindly check attachment.  :)

Ill add this info. in the mod page too since a few other people also got into the same issue.



Quote from: Rayleigh on September 06, 2013, 06:13:52 PM
Hi!
First of all, thanks for your mod, it works as smooth as butter and is perfect!

Is it possible to adjust the size of the youtube window? If yes, can you tell me how? If not, is it possible to add that feature to your mod?

Thank you. And regarding the window size, yes, its possible.

In ~/Subs.php, find the following code and replace width="642" height="392" to your choice. :)


array(
'tag' => 'youtube',
'type' => 'unparsed_content',
'content' => '<iframe style="border:0;" width="642" height="392" src="http://www.youtube.com/embed/$1" allowfullscreen></iframe>',
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 07, 2013, 02:32:39 PM
Quote from: xPandax on September 07, 2013, 05:27:13 AM
Quote from: goodwinml on September 06, 2013, 03:15:47 PM
Here you go.

Ok, the mod is working the way it should. The youtube links posted by you were not parsed into videos because you wrapped it within [url] tags. If you wrap a link within [url] tags, then it means you are forcing it to be displayed as url. Kindly check attachment.  :)

Ill add this info. in the mod page too since a few other people also got into the same issue.


You said, I wrapped it within url tags. What I am doing is going to YouTube. I get a vid. I click share. I copy share link. I paste link in forum. I post. And ALL I get is a link to a video NOT a player! The ONLY way I can get a player is to MANUALLY type in the opening and closing youtube statements!

Those url tags are being inserted by SMF! Not me.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Rayleigh on September 07, 2013, 07:02:37 PM
Quote from: xPandax on September 07, 2013, 05:27:13 AM
Quote from: goodwinml on September 06, 2013, 03:15:47 PM
Here you go.

Ok, the mod is working the way it should. The youtube links posted by you were not parsed into videos because you wrapped it within [url] tags. If you wrap a link within [url] tags, then it means you are forcing it to be displayed as url. Kindly check attachment.  :)

Ill add this info. in the mod page too since a few other people also got into the same issue.



Quote from: Rayleigh on September 06, 2013, 06:13:52 PM
Hi!
First of all, thanks for your mod, it works as smooth as butter and is perfect!

Is it possible to adjust the size of the youtube window? If yes, can you tell me how? If not, is it possible to add that feature to your mod?

Thank you. And regarding the window size, yes, its possible.

In ~/Subs.php, find the following code and replace width="642" height="392" to your choice. :)


array(
'tag' => 'youtube',
'type' => 'unparsed_content',
'content' => '<iframe style="border:0;" width="642" height="392" src="http://www.youtube.com/embed/$1" allowfullscreen></iframe>',



I was talking about changing the size but not for all the videos, just for one. :D
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on September 08, 2013, 12:56:14 AM
Quote from: Rayleigh on September 07, 2013, 07:02:37 PM
Quote from: xPandax on September 07, 2013, 05:27:13 AM
Quote from: goodwinml on September 06, 2013, 03:15:47 PM
Here you go.

Ok, the mod is working the way it should. The youtube links posted by you were not parsed into videos because you wrapped it within [url] tags. If you wrap a link within [url] tags, then it means you are forcing it to be displayed as url. Kindly check attachment.  :)

Ill add this info. in the mod page too since a few other people also got into the same issue.



Quote from: Rayleigh on September 06, 2013, 06:13:52 PM
Hi!
First of all, thanks for your mod, it works as smooth as butter and is perfect!

Is it possible to adjust the size of the youtube window? If yes, can you tell me how? If not, is it possible to add that feature to your mod?

Thank you. And regarding the window size, yes, its possible.

In ~/Subs.php, find the following code and replace width="642" height="392" to your choice. :)


array(
'tag' => 'youtube',
'type' => 'unparsed_content',
'content' => '<iframe style="border:0;" width="642" height="392" src="http://www.youtube.com/embed/$1" allowfullscreen></iframe>',



I was talking about changing the size but not for all the videos, just for one. :D

Unfortunately, there is not a way to do that without some more major code changes.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on September 08, 2013, 05:14:20 AM
Quote from: goodwinml on September 07, 2013, 02:32:39 PM
You said, I wrapped it within url tags. What I am doing is going to YouTube. I get a vid. I click share. I copy share link. I paste link in forum. I post. And ALL I get is a link to a video NOT a player! The ONLY way I can get a player is to MANUALLY type in the opening and closing youtube statements!

Those url tags are being inserted by SMF! Not me.

Just post the youtube links as plain text. Don't insert links using the "Insert Hyperlink" button on the post box. Please check attachment.



Quote from: Colin on September 08, 2013, 12:56:14 AM
Quote from: Rayleigh on September 07, 2013, 07:02:37 PM
I was talking about changing the size but not for all the videos, just for one. :D

Unfortunately, there is not a way to do that without some more major code changes.

This!

The mod has to be rewritten to make that feature available for individual videos.  O:)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 08, 2013, 02:51:14 PM
Quote from: xPandax on September 08, 2013, 05:14:20 AM
Quote from: goodwinml on September 07, 2013, 02:32:39 PM
You said, I wrapped it within url tags. What I am doing is going to YouTube. I get a vid. I click share. I copy share link. I paste link in forum. I post. And ALL I get is a link to a video NOT a player! The ONLY way I can get a player is to MANUALLY type in the opening and closing youtube statements!

Those url tags are being inserted by SMF! Not me.

Just post the youtube links as plain text. Don't insert links using the "Insert Hyperlink" button on the post box. Please check attachment.


I do not use Insert Hyperlink button. Like I said before. I go to video, click share, control-c to copy link, control-v to paste link! As stated before this works great if you manually type in the youtube tags! You are saying I need to type in 50 plus characters instead of just ctrl-c and ctrl-v then post?????????
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Colin on September 08, 2013, 06:58:58 PM
Nice work xPandax!
Title: Re: Simple Youtube Video Embedder/BBC
Post by: goodwinml on September 08, 2013, 07:45:40 PM
Quote from: Colin on September 08, 2013, 06:58:58 PM
Nice work xPandax!
Nice work? no fix yet!

Again, why should I have to type in a youtube link to make this work instead of ctrl-c and ctrl-v? SMF is causing the url to be input. How do you stop this? Hmmmmmmmmmmmmm?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on September 09, 2013, 04:40:30 AM
Quote from: Colin on September 08, 2013, 06:58:58 PM
Nice work xPandax!

Thanks. :)



Quote from: goodwinml on September 08, 2013, 02:51:14 PM
I do not use Insert Hyperlink button. Like I said before. I go to video, click share, control-c to copy link, control-v to paste link! As stated before this works great if you manually type in the youtube tags! You are saying I need to type in 50 plus characters instead of just ctrl-c and ctrl-v then post?????????
Quote from: goodwinml on September 08, 2013, 07:45:40 PM
Nice work? no fix yet!

Again, why should I have to type in a youtube link to make this work instead of ctrl-c and ctrl-v? SMF is causing the url to be input. How do you stop this? Hmmmmmmmmmmmmm?

What fix do you want? The mod is working fine.

I just tested in my test forum with WYSIWYG editor "enabled" as well as "disabled" and Ctrl-c & Ctrl-v works fine.

When I posted in your forum too, I copy pasted the youtube link & it parsed as video. I just don't understand why it doesn't work for you.

Maybe try disabling WYSIWYG editor.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: TrueZone on September 14, 2013, 06:48:30 AM
well, for me not work.. when i  make a reply or a new topic the page remain  whit !!! What`s happening ? I folowed all instuction thee...
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on September 15, 2013, 08:12:53 AM
Quote from: TrueZone on September 14, 2013, 06:48:30 AM
well, for me not work.. when i  make a reply or a new topic the page remain  whit !!! What`s happening ? I folowed all instuction thee...

Are you using any other video related mods?

Could you please attach the Subs.php & Post.php files? Or PM a demo login for your forum?

Thanks.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: TrueZone on September 16, 2013, 06:46:35 AM
Quote from: xPandax on September 15, 2013, 08:12:53 AM
Quote from: TrueZone on September 14, 2013, 06:48:30 AM
well, for me not work.. when i  make a reply or a new topic the page remain  whit !!! What`s happening ? I folowed all instuction thee...

Are you using any other video related mods?

Could you please attach the Subs.php & Post.php files? Or PM a demo login for your forum?

Thanks.

My firend, i make the changes in a fressh copy of forum on a test page, so, all was in original files, i veryfied 3 times and was eneterd corectly...
I`m not using any othe video mods.. was on emty and fresh instaled forum

Thank you
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on September 17, 2013, 12:21:19 PM
Quote from: TrueZone on September 16, 2013, 06:46:35 AM
My firend, i make the changes in a fressh copy of forum on a test page, so, all was in original files, i veryfied 3 times and was eneterd corectly...
I`m not using any othe video mods.. was on emty and fresh instaled forum

Thank you

Could you please PM me the link to your forum along with a demo login.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: TrueZone on September 23, 2013, 06:12:25 AM
Quote from: xPandax on September 17, 2013, 12:21:19 PM
Quote from: TrueZone on September 16, 2013, 06:46:35 AM
My firend, i make the changes in a fressh copy of forum on a test page, so, all was in original files, i veryfied 3 times and was eneterd corectly...
I`m not using any othe video mods.. was on emty and fresh instaled forum

Thank you

Could you please PM me the link to your forum along with a demo login.

I resolved this problem in the meanwile. The problem was with my Subs-Post.php file, that was quarantined  by the host...

Have a good day
Title: Re: Simple Youtube Video Embedder/BBC
Post by: TrackMustangsOnline on October 06, 2013, 12:47:22 AM
That was easy, great mod thanks!
Title: Re: Simple Youtube Video Embedder/BBC
Post by: DaRKeN_58 on October 20, 2013, 12:16:37 AM
Awesome mod. Thank you very much  ;)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: gijs007 on November 12, 2013, 07:03:16 AM
I have one problem with this mod: My SMF forum runs on https and the embedded youtube video's are non https.
Some browsers block non https items on https websites.

Is it possible to edit the mod so it uses https instead of http?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: rnorth6920 on November 12, 2013, 11:59:44 AM
This mod is awesome!! My only complaint is that when pages are viewed using a mobile browser and there are a lot of videos, it crashes the browser.  Anyone else have this issue?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on November 14, 2013, 08:04:33 AM
Quote from: gijs007 on November 12, 2013, 07:03:16 AM
I have one problem with this mod: My SMF forum runs on https and the embedded youtube video's are non https.
Some browsers block non https items on https websites.

Is it possible to edit the mod so it uses https instead of http?

In, /Sources/Subs.php, replacing http (marked with bold) with https should work.

Quote
         array(
            'tag' => 'youtube',
            'type' => 'unparsed_content',
            'content' => '<iframe style="border:0;" width="642" height="392" src="http://www.youtube.com/embed/$1" allowfullscreen></iframe>',
            'validate' => create_function('&$tag, &$data, $disabled', '
            if (isset($disabled[\'url\']))
               $tag[\'content\'] = \'http://www.youtube.com/watch?v=$1\';
            $pattern = \'~(?:http|https|)(?::\/\/|)(?:www.|)(?:youtu\.be\/|youtube\.com(?:\/embed\/|\/v\/|\/watch\?v=|\/ytscreeningroom\?v=|\/feeds\/api\/videos\/|\/user\S*[^\w\-\s]|\S*[^\w\-\s]))([\w\-]{11})[a-z0-9;:@?&%=+\/\$_.-]*~i\';
            if (preg_match($pattern, $data, $matches))
               $data = $matches[1];'),
            'disabled_content' => 'http://www.youtube.com/watch?v=$1',
         ),



Quote from: rnorth6920 on November 12, 2013, 11:59:44 AM
This mod is awesome!! My only complaint is that when pages are viewed using a mobile browser and there are a lot of videos, it crashes the browser.  Anyone else have this issue?

It has nothing to do with this mod. Its the flash player that's crashing the browser.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: rnorth6920 on November 14, 2013, 08:51:41 AM
Even though mobile browsers so not support flash?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arantor on November 14, 2013, 11:01:23 AM
Except that YouTube won't be using Flash. The obscene amount of memory that gets allocated to make this stuff work in iframes is the problem: too many embeds on one page has *always* been an issue. It's just worse on mobile where there's a limited amount of memory and the browser crashes when the oomkiller pays a visit.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: gijs007 on November 14, 2013, 04:13:20 PM
Thank you  ;D
That solved it.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: mycousinvinny on November 17, 2013, 07:56:47 AM
Great Mod Simple and Eloquent. Very Nice work Pandax. Thanks Very Much
Title: Re: Simple Youtube Video Embedder/BBC
Post by: FragaCampos on November 17, 2013, 07:40:12 PM
Hi there.

I was trying to substitute Aeva's mod by this one, since xPandax's mod is more up-to-date and supports short links and https, but after years using Aeva, by forum's Youtube links get "weird" after uninstalling it, and Simple Youtube Video Embedder/BBC doesn't recognize them.
They show up like this after uninstalling Aeva:
[url=http://www.youtube.com/watch?v=bZwMIIJLWOw#ws]www.youtube.com/watch?v=bZwMIIJLWOw#ws[/url]

Since I have hundreds of Youtube links in my forum I don't know how to solve this issue. Any thoughts?

Title: Re: Simple Youtube Video Embedder/BBC
Post by: amadeos on November 18, 2013, 09:04:39 AM
It's probably the wrong discussion, but anyway is there a mod to enable Vimeo video?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: margarett on November 18, 2013, 10:29:20 AM
FragaCampos, tás bom? :P

It should be possible to write a SQL query to automagically fix the links for you. Not sure if I can do it, though. But I can try ;)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arantor on November 18, 2013, 10:48:12 AM
While you can do a SELECT ... WHERE body RLIKE... to do a regular expression search, you can't do a regex replace directly in SQL :(
Title: Re: Simple Youtube Video Embedder/BBC
Post by: FragaCampos on November 19, 2013, 09:43:19 PM
[portuguese mode on]Está tudo rijo, margarett. Espero que contigo também. [/portuguese mode off] ;)

Yes, I thought this wouldn't be easy to do via SQL, but it is worth the shot.

Thanks again for your help, margarett and Arantor.
Any suggestion would be much appreciated. ;)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: margarett on November 20, 2013, 07:38:41 AM
Well, I put up a script that, I believe, could be resumed in 1/3 of the lines. regex is still really, really far in my to-learn list :P

It works, as far as I could test here. FragaCampos, you will backup, right? :P
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Nickwan on November 20, 2013, 01:40:32 PM
Works like a charm for 2.0.2 too.
Thx alot for this great mod!
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arantor on November 20, 2013, 02:10:57 PM
You really should use the package manager to update through 2.0.3, 2.0.4, 2.0.5 to 2.0.6.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on November 23, 2013, 09:01:59 AM
Quote from: FragaCampos on November 17, 2013, 07:40:12 PM
Hi there.

I was trying to substitute Aeva's mod by this one, since xPandax's mod is more up-to-date and supports short links and https, but after years using Aeva, by forum's Youtube links get "weird" after uninstalling it, and Simple Youtube Video Embedder/BBC doesn't recognize them.
They show up like this after uninstalling Aeva:
[url=http://www.youtube.com/watch?v=bZwMIIJLWOw#ws]www.youtube.com/watch?v=bZwMIIJLWOw#ws[/url]

Since I have hundreds of Youtube links in my forum I don't know how to solve this issue. Any thoughts?

Well, this mod won't convert youtube links inside "url" tags because its one of the feature, just in case if someone wants to just display the youtube url as link rather than a video frame.



Quote from: amadeos on November 18, 2013, 09:04:39 AM
It's probably the wrong discussion, but anyway is there a mod to enable Vimeo video?

Yes, this is the wrong thread but here is the answer, http://custom.simplemachines.org/mods/index.php?mod=3398.

Here after, post queries in the board in this link, http://www.simplemachines.org/community/index.php?board=147.0.



Quote from: Nickwan on November 20, 2013, 01:40:32 PM
Works like a charm for 2.0.2 too.
Thx alot for this great mod!

Yes, this mod will work with all version of 2.x but as Arantor had posted, you should upgrade the forum first.

Quote from: Arantor on November 20, 2013, 02:10:57 PM
You really should use the package manager to update through 2.0.3, 2.0.4, 2.0.5 to 2.0.6.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: FragaCampos on November 24, 2013, 07:47:08 AM
Quote from: margarett on November 20, 2013, 07:38:41 AM
Well, I put up a script that, I believe, could be resumed in 1/3 of the lines. regex is still really, really far in my to-learn list :P

It works, as far as I could test here. FragaCampos, you will backup, right? :P


Thank you, margarett.
I'll try this as soon as I get home. I'll keep you posted.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: diesy on December 01, 2013, 04:46:29 PM
Hello,

just wondering if we can assign you has the ability to embed and who doesnt. I want only the moderators or global mods to be able to use the embedding.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: freestyler7 on December 02, 2013, 12:35:31 AM
Greetings. Thank you for this mode Pandax
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on December 02, 2013, 04:25:18 AM
Quote from: diesy on December 01, 2013, 04:46:29 PM
Hello,

just wondering if we can assign you has the ability to embed and who doesnt. I want only the moderators or global mods to be able to use the embedding.

That feature is not available as of now. And I have no time to implement that feature for this mod, sorry.



Quote from: freestyler7 on December 02, 2013, 12:35:31 AM
Greetings. Thank you for this mode Pandax


Thank you very much. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: smoked on December 03, 2013, 02:01:40 PM
Good work :)

Thank you.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arvacon on January 08, 2014, 05:26:10 AM
Thanks a tone for this useful mod!
I was waiting long time for this one  ;D
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arvacon on January 09, 2014, 05:48:54 AM
Hi again.
When I don't have Aeva media installed at my forum, your mod works fine.
But, when I install the Aeva mod, then your mod stops working, as auto-embedding future of aeva dominates.
I went at the settings and I disabled the auto-embedding Aeva's function, but your mod still not working.
Do you have any idea of how could I solve this problem and make them work together?

As I see when I edit a post, the youtube link that you just pasted at the post, is taking automatically [url/url] code when you have installed the aeva mod, so maybe that's the problem. It would be nice if you could tell us how can we change the code, to make your mod react the same with the links that they have url code, as in some cases this is useful. For example if my members want to share a video, they just want the video to be visible at the post. When this seems as link, they keep asking how to change it to make it looks like at my posts.
With Aeva there was problem with the https links, so your mod is necessary for me.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: margarett on January 09, 2014, 07:48:31 AM
And why do you need to use 2 MODs to the same purpose? It's extremely likely they can't coexist...
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arvacon on January 09, 2014, 07:55:00 AM
I use the Aeva as gallery for the forum, so I tried to disable the auto-embedding function for youtube and use only the simple youtube mod for youtube links in the posts, because Aeva doesn't work for https links.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: margarett on January 09, 2014, 08:12:46 AM
Good point ;)

But even if you don't use the auto embed feature, the code is still there...
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arvacon on January 09, 2014, 08:21:52 AM
So the only solution I guess it would be, to do some change at the code of the simple youtube mod, to use the [url/url] links too.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: fmofmpls on January 09, 2014, 07:28:56 PM
Arvacon, I'm in the same boat as you are. I use Aeva for the gallery and had been using it for simple YouTube sharing as well. That is until the mod suddenly stopped playing nice with YouTube. I also found out that these two mods cannot coexist. There's a conflict. I'm not willing to sacrifice my gallery with hundreds of pics, so I'm going to have to do some simple code editing so that https will play nice with Aeva and YouTube.

In the meantime, for a quick fix, all you have to do is remove the letter "s" from the http part of the YouTube link and the mod will work.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: margarett on January 09, 2014, 08:04:43 PM
Check the latest posts in AEVA topic. A possible fix was just added there.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arvacon on January 09, 2014, 11:26:42 PM
As I was searching the hundreds of pages of that topic, I found a simple solution.

https://www.youtube.com => http://www.youtube.com

You add the above at the censored words and then the https links change to http automatically, so at least for the post's area that I am interesting, this is working. It doesn't work when you add a new video at the gallery's area, but that's not big deal, as if you just remove manually the s from https, it works.
Unfortunately I had to remove the Simple youtube video embedder mod for make this work, but I had to post this solution, to prevent similar questions and help some people with the same requirements.  :)

Title: Re: Simple Youtube Video Embedder/BBC
Post by: fmofmpls on January 10, 2014, 07:44:48 AM
Quote from: Arvacon on January 09, 2014, 11:26:42 PM
As I was searching the hundreds of pages of that topic, I found a simple solution.

Brilliant workaround! Thanks so much for sharing that!
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Arvacon on January 10, 2014, 09:22:05 AM
 ;)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: HRM on January 15, 2014, 06:58:44 AM
I have to take some time to say: GREAT MOD, plain and simple and it works!

Thanks!

Only note is that it would be handy having [url]youtube. supported or removed for old posts automatically.  But only when url + Youtu* cause otherwise normal url's wont work.  ;D

Anyway ,still great Mod!
Title: Re: Simple Youtube Video Embedder/BBC
Post by: HRM on January 20, 2014, 05:58:03 AM
There was an old mod (very long time ago)  that would support the tags yt and /yt.

Like in:
[yt=425,350]rsVGTEUNlK0&hl[/yt]

How can I make this mod do those tags too?
This because I have very old post with that tag that now are not working.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: pikapower on January 25, 2014, 05:28:55 AM
is there a smf 2.0.7 update ?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: HRM on January 28, 2014, 12:51:12 PM
It just works on smf 2.0.7.
I have it running and I ran the patch.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on February 25, 2014, 02:16:39 PM
Quote from: diesy on December 01, 2013, 04:46:29 PM
Hello,

just wondering if we can assign you has the ability to embed and who doesnt. I want only the moderators or global mods to be able to use the embedding.

That feature is not available for this mod. Sorry for the very late reply.



Quote from: HRM on January 20, 2014, 05:58:03 AM
There was an old mod (very long time ago)  that would support the tags yt and /yt.

Like in:
[yt=425,350]rsVGTEUNlK0&hl[/yt]

How can I make this mod do those tags too?
This because I have very old post with that tag that now are not working.

Its not possible with the current mod. To make that feature available, the mod has to be re-written which will break the current mod, so I'm not going to do that. Sorry for the very late reply.



Quote from: pikapower on January 25, 2014, 05:28:55 AM
is there a smf 2.0.7 update ?

This mod will work with all versions of SMF 2.0.x. :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: PixelClyde on March 04, 2014, 09:28:08 AM
First: nice mod.

My Q: I wonder wether I can integrate a whole playlis or not? When I try so, only the first video is shown. How do I integrate a whole playlist?
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on March 04, 2014, 09:46:44 PM
Quote from: PixelClyde on March 04, 2014, 09:28:08 AM
First: nice mod.

My Q: I wonder wether I can integrate a whole playlis or not? When I try so, only the first video is shown. How do I integrate a whole playlist?

The embed code for playlist is different from videos, so playlist won't work. To make playlist work, the mod has to be re-written including another bbc for playlist. Ill try to do that when I find time. Thanks for the idea. Cheers! :)
Title: Re: Simple Youtube Video Embedder/BBC
Post by: PixelClyde on March 05, 2014, 06:45:24 AM
Quote from: xPandax on March 04, 2014, 09:46:44 PM
Quote from: PixelClyde on March 04, 2014, 09:28:08 AM
First: nice mod.

My Q: I wonder wether I can integrate a whole playlis or not? When I try so, only the first video is shown. How do I integrate a whole playlist?

The embed code for playlist is different from videos, so playlist won't work. To make playlist work, the mod has to be re-written including another bbc for playlist. Ill try to do that when I find time. Thanks for the idea. Cheers! :)
That would be nice, thanks.
Title: Re: Simple Youtube Video Embedder/BBC
Post by: Neo_TE on March 13, 2014, 03:54:15 AM
Mod updated to v2.0. Please upgrade to the latest version. :P

Changelog / New Features
v2.0 - Mod totally rewritten using hooks (13 March 2014)