Yet Another YouTube BBCode Tag

Started by dougiefresh, December 10, 2014, 06:09:01 PM

Previous topic - Next topic

dougiefresh

Quote from: Gryzor on August 24, 2017, 11:34:04 AM
Ok, weird thing. I often have to edit my users' posts to add the BBcode. I now tried just pasting a YT link and it was auto-embedded!! Are there special permissions?
No, there are no special permissions in the link.

Quote from: Gryzor on August 24, 2017, 11:34:04 AM
Right now I can't find a simple link because as I said I edit them, but let me know if you want me to try and replicating it? I've already asked my users over at http://www.cpcwiki.eu/forum/off-topic/just-a-test-13793/msg148577/#msg148577 ...
Well, I can't fix what I don't know is wrong....  Really need a sample link in order to know what I need to fix....

Gryzor

In that thread they did post one, but it's a youtu.be link, not sure if the package supports those. I will try creating a normal (=long) link later, too

dougiefresh

Version 4.4 does support the youtu.be link in the form you supplied properly.  Previous versions do not.

Gryzor

Ohhh yes, it works now, and perfectly so!

Thanks :)

Jailer

My error log is getting spammed with error messages since installing this mod. Merely visiting the site will cause this error. Any idea what may be causing this?

https://mlcnfriends.com/index.php?
8: Undefined index:
File: /usr/local/www/nginx/Sources/Subs-BBCode-YouTube.php
Line: 385


The line in question:

383: {
384: if (strpos($param, '=') === false)
==>385: $order[$old] .= ' ' . $param;
386: else
387: $order[$old = substr($param, 0, strpos($param, '='))] = substr($param, strpos($param, '=') + 1);
388: }

peterparker

I wanted to upload my videos on youtube, what will I do for uploading my videos on youtube

Gryzor

Quote from: peterparker on August 30, 2017, 09:04:38 PM
I wanted to upload my videos on youtube, what will I do for uploading my videos on youtube

You just go and upload your videos on YouTube.

dougiefresh

Uploaded v4.5 - August 31st, 2017
o Fixed undefined array element error in Subs-BBCode-YouTube.php.




@Jailer:  Thank you for the bug report!  It's been fixed for version 4.5!

Jailer

Looks like that fixed it. Thanks for the quick update!

landyvlad

"Put as much effort into your question as you'd expect someone to give in an answer"

Please do not PM, IM or Email me with questions on astrophysics or theology.  You will get better and faster responses by asking homeless people in the street. Thank you.

Be the person your dog thinks you are.

asmith

@dougiefresh,

My forum (2.0.14) runs under https. I noticed youtube links starting with http get blocked and are not shown. I modified Subs-BBCode-YouTube.php to forced all youtube links to be https and it worked. Thought to let you know.

dougiefresh

Uploaded v4.6 - October 9th, 2017
o Added option to force using HTTPS instead of allowing HTTP in links.




@asmith:  Thank you for the bug report.  Hopefully this update will assist in solving your problem.

asmith

Thanks for the fix.

But isn't YouTube all https now? I mean there's no http anymore in any of google products. (why the option to force?)

dougiefresh

Uploaded v4.7 - October 17th, 2017
o Removed option to force HTTPS mode.
o Modified code to force HTTPS mode in all YouTube tags.



Quote from: asmith on October 09, 2017, 02:34:38 PM
But isn't YouTube all https now? I mean there's no http anymore in any of google products. (why the option to force?)
Sorry about the delay in responding.  I just looked into the YouTube thing.  You're 100% right.  The mod has been corrected so that YouTube tags work correctly now (*at least everything that I know of....  :P )

neoweb

Hi.. my button images weren't showing up, so I uploaded the files to the theme BBC directory, but it still is not showing up 'nice' (see attachement)

What can I do?

-Rock Lee-

It's a very good variant :D to play in local that I'm just putting together something similar and can help me understand some things, thanks for sharing!


Regards!
¡Regresando como cual Fenix! ~ Bomber Code
Ayudas - Aportes - Tutoriales - Y mucho mas!!!

landyvlad

What is the update process please?  Is it just upload and install the new one, or do I uninstall./delete the old one first?
(It'd be cool if this info was included in the description of the mod, for easy reference)

Thanks
"Put as much effort into your question as you'd expect someone to give in an answer"

Please do not PM, IM or Email me with questions on astrophysics or theology.  You will get better and faster responses by asking homeless people in the street. Thank you.

Be the person your dog thinks you are.

dougiefresh

Quote from: landyvlad on December 18, 2017, 07:39:38 AM
What is the update process please?  Is it just upload and install the new one, or do I uninstall./delete the old one first?
(It'd be cool if this info was included in the description of the mod, for easy reference)
First, Package Manager won't allow you to install a newer version of a mod while an older version is installed.  If the package supports upgrading, Package Manager will give you the option to upgrade to the new version.  Most of my mods do not support upgrades in that fashion, mostly because some servers have issues with multiple install XML files and aren't smart enough to make it work....

The proper way to upgrade any mod that doesn't give the option through Package Manager is to uninstall the current version of the mod, then install  the new version.  Immediately deleting the old version is not mandatory at any stage of the upgrade process, although if you are happy with the new version, deletion of the old version is recommended.

Quote from: neoweb on November 24, 2017, 02:46:15 AM
Hi.. my button images weren't showing up, so I uploaded the files to the theme BBC directory, but it still is not showing up 'nice' (see attachement)
I'll fix the installer so that the BBC button images are properly installed.

You're right, that doesn't look "nice".  If you want to redesign better button images, please feel free to share them and I'll include them.

Dwev

I want to remove this mod and it throws two errors while trying to do this.

The test failed on ./Sources/PortalBlocks.php
It says that it should find the following code:


$context['bbc_youtube']['ignore'] = true;
$shoutbox['warning'] = parse_bbc($shoutbox['warning']);


and replace it with this one:


$shoutbox['warning'] = parse_bbc($shoutbox['warning']);


Funny thing is that in that file there's nothing that resembles that, even a search for just the word "youtube" yields no results at all.

The second error is for ./Themes/default/languages/index.english.php
It tell me that I should replace the code "?>" with nothing at all (empty field).

If I look into that file I do find the "?>" all the way at the end, just before it are 5 times that are clearly related to YouTube.

Does anyone know how I can safely remove this mod?

dougiefresh

Quote from: Dwev on December 28, 2017, 11:13:45 AM
I want to remove this mod and it throws two errors while trying to do this.

The test failed on ./Sources/PortalBlocks.php
It says that it should find the following code:


$context['bbc_youtube']['ignore'] = true;
$shoutbox['warning'] = parse_bbc($shoutbox['warning']);


and replace it with this one:


$shoutbox['warning'] = parse_bbc($shoutbox['warning']);


Funny thing is that in that file there's nothing that resembles that, even a search for just the word "youtube" yields no results at all.
Okay, you can ignore this error.  I'm thinking you aren't running the portal that this mod makes a change to, are you?  Even if you were, the line isn't in there, so you can safely ignore the error....

Quote from: Dwev on December 28, 2017, 11:13:45 AM
The second error is for ./Themes/default/languages/index.english.php
It tell me that I should replace the code "?>" with nothing at all (empty field).

If I look into that file I do find the "?>" all the way at the end, just before it are 5 times that are clearly related to YouTube.

Does anyone know how I can safely remove this mod?
Hmmm....  That's a weird issue....  :-[  I'll see if I can duplicate it.  If I can, then I will see about fixing the mod....

Go into Themes/default/languages/index.english.php and remove each of the lines that are clearly related to this mod, then proceed to ignore this error as well....

Advertisement: