News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Ohara YouTube Embed

Started by Suki, December 21, 2011, 03:04:59 PM

Previous topic - Next topic

projectmyst

I'm using english UTF8. do you want me attach it here for you to have a look?

Suki

Sure or if you have a code editor, make sure that file is properly encoded as UTF8 without BOM.
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

projectmyst

here it is what i'm using, the file is named "OharaYTEmbed.english_british-utf8.php"

<?php

global $txt;

$txt['OYTE_master'] = 'Enable the Ohara Youtube Embed mod';
$txt['OYTE_master_sub'] = 'This is the master setting, it needs to be enable for the mod to work.';
$txt['OYTE_video_width'] = 'Video\'s width:';
$txt['OYTE_video_width_sub'] = 'If empty it will take the default value: 420.';
$txt['OYTE_video_height'] = 'Video\'s height:';
$txt['OYTE_video_height_sub'] = 'If empty it will take the default value: 315';
$txt['OYTE_desc'] = 'Embed a youtube video url';
$txt['OYTE_unvalid_link'] = 'Not a valid youtube URL %s';
$txt['OYTE_title'] = 'Ohara Youtube Embed mod';
?>

Suki

Oh, I was expecting the whole file as an attachment, but nevermind, use this one and see if the space disappear:

rename it to OharaYTEmbed.english_british-utf8.php
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

projectmyst

OK i have worked out why its not working, when it copys the files to its places, i.e. OharaYTEmbed, OharaYTEmbed.english_british-utf8.php and so on, it's making the file permission to 666 instead of 644, as soon as i change it to 644 then it works just fine....

Suki

Weird but it can happen, yes, you can have the file at 644 with no issues if that works for you.
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

MadTogger

Hi Suki,

I would dearly love to use your youtube mod but cannot get it to work.

I have installed it manually as per the directions on the mod's page as I have done a number of times with other mods.

The first thing that is noticable is that the 'youtube' button does not appear on the editor.

I have checked to see if the actual bbcode tag works in a post by typing it in manually, it does not.

There is no settings menu in Admin->Configuration->Modifications.

I have also noticed that if I now click my 'Admin' button on the top menu of my forum, the one that goes to url /index.php?action=admin

It just causes a blank page to appear and my forum has gone.

I can get to my Admin CP by clicking any of the sub-menus under Admin, they work fine.

Once in my Admin CP if I then click 'Main>Administration Center', I get the same blank page.

Have you any ideas what the issue could be?

Kind regards..,


Suki

What SMF version are you using?
Why didn't you use the packager manager?

If you installed manually you must run the install script for the hooks to be inserted on the DB
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

MadTogger

Quote from: Suki on February 18, 2012, 08:08:21 AM
What SMF version are you using?
Why didn't you use the packager manager?

If you installed manually you must run the install script for the hooks to be inserted on the DB

Hi,

I am using 2.0.2.

I have a lot of problems installing mods using the package manager, it keeps saying that the directory is not writable when it actually is.

Sometimes I can get around this issue by creating a directory called 'temp' inside the 'Packages' directory and making that writable.

This fix doesn't always work so I tend then to just manually install mods.

I applied my temp folder fix and yes it actually did install your youtube mod perfectly, thank you for the help.

By the way, in the who.php file there is a piece of code:
OYTE_Who(),

and this is called from OharaYTEmbed.php as:
/* DUH! WINNING! */
function OYTE_Who()
{
$MAS = '<a href="http://missallsunday.com" title="Free SMF Mods">Ohara YouTube Embed mod &copy Suki</a>';

return $MAS;
}


I assume this is your copyright but when and where is actually displayed on my forum?

Kind regards..,

MT

Suki

The copyright is displayed on the credits action:

http://www.simplemachines.org/community/index.php?action=credits

http://missallsunday.com/credits/

You need to manually run the install file to apply the hooks, download the mod, unzip it, upload the database.php file to your forum root folder (where SSI.php is)  and call it with your browser:  mysite.com/forum/database.php
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

MadTogger

Quote from: Suki on February 18, 2012, 08:48:34 AM
The copyright is displayed on the credits action:

http://www.simplemachines.org/community/index.php?action=credits

http://missallsunday.com/credits/

You need to manually run the install file to apply the hooks, download the mod, unzip it, upload the database.php file to your forum root folder (where SSI.php is)  and call it with your browser:  mysite.com/forum/database.php

Thank you so much for all your help Suki, I have got it working now along with your FAQ mod.

You are an angel.

Have a great day.

Hasta Luego  ;D

leeman

I have installed the Mod, used the tags, but all it does is place the tags before and after the URL link. Does not embed. Any idea why?

Suki

Quote from: leeman on March 17, 2012, 01:39:09 PM
I have installed the Mod, used the tags, but all it does is place the tags before and after the URL link. Does not embed. Any idea why?

What is your forum version?

Did you installed it via the Package Manager ?
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

leeman

Version 2.0.2

Yes, I used the Package Manager. Funny, I can't embed Flash either. Just shows the tags & the URL

Example:

To me, this stuff is beautiful.  This is one step up from the bottom of the lake's food chain (the bottom would need a microscope to see), and the stuff that feeds everything else in the lake.  When you see these things under a microscope, with their intricate detail, they're as beautiful as any living thing we see with the unaided eye ... to me anyway.



Suki

Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

leeman

Never mind, it appears to be working now for some reason... Go figure! Thanks anyway...

Abnovitas

Hi and thanks for your mod!

I've got a (maybe related) issue as well:
I'm using the WYSIWYG editor for message composing and when I paste a Youtube link into the textbox it gets converted to a link automatically.
So when I now use the Youtube BBC tags it won't work and I get a link like this:



Only when I remove the URL formatting it will work and embed the actual video.
Is there any workaround for this?

Thanks a lot in advance!

Benelton182

Quote from: Hragged on January 07, 2012, 05:01:32 PM
This is great, thanks! ;D

Noticed a little problem on my forum - whenever I have a smiley after a YouTube video in the same post, the smiley image doesn't appear, just the code for the smiley. They work fine when posted above the video though.

Don't know if this happens on all forums (I'm on 2.0.2, I have a couple of other mods installed and a modified template) but thought I should say anyway, just in case!

Cheers! :D


Hi I have the same problem using the defualt theme and smileys pack. I'm not getting the smileys apperaing only the code after the youtube clip.

TIA

Suki

@Benelton182 and Abnovitas

I'm aware of both issues, unfortunately I haven't had the time to actually do some research and find the problem.
Disclaimer: unless otherwise stated, all my posts are personal and does not represent any views or opinions held by Simple Machines.

simon36

Hi, great mod.

When I use it, the clip appears in the centre of the post as opposed to align left?

Is this an option I can specify anywhere?

Thanks!

Advertisement: