I'd like to leave a YouTube link as it is. How is the syntax then?

Anything that creates a link or a code block.

[url]https://www.youtube.com/watch?v=FlsCjmMhFmw[/url]
[whatever](https://www.youtube.com/watch?v=FlsCjmMhFmw)
`https://www.youtube.com/watch?v=FlsCjmMhFmw`
10 days later

@JoshyPHP all versions tagged for beta 8 support will cause users on beta 7 to fail installation we just identified on Discord. Best to do is (temporarily) remove your tags for code related to beta 8 or instruct users to require the extension with a constraint.

Composer seems to identify the last extension version as the most plausible candidate for beta 7.

I think that should work better with this? I updated the first post.

composer require s9e/flarum-ext-mediaembed:*
5 months later

I just installed, seems I can only get it to work on youtube if I use the [media] tags but its working!

Also is there a way to have imgu links just display the image instead of having the imgur bar show up on top and bottom like this:

It would be sweet if we could just drop the imgur link in the post and have it show the picture only. Maybe if you click on it than it will bring you to the imgur site?

    2 months later

    JoshyPHP Hello Joshy, I tried to apply your solution but I get this error:

    ./composer.json has been updated
    Loading composer repositories with package information
    Updating dependencies (including require-dev)
    Your requirements could not be resolved to an installable set of packages.

    Problem 1
    - Installation request for s9e/flarum-ext-mediaembed 0.3.2 -> satisfiable by s9e/flarum-ext-mediaembed[0.3.2].
    - s9e/flarum-ext-mediaembed 0.3.2 requires flarum/core 0.1.0-beta.3 -> satisfiable by flarum/core[0.1.x-dev, v0.1.0-beta.3, v0.1.0-beta.4, v0.1.0-beta.5, v0.1.0-beta.6, v0.1.0-beta.7, v0.1.0-beta.7.1] but these conflict with your requirements or minimum-stability.

    Installation failed, reverting ./composer.json to its original content.
    -bash-4.2$ composer require s9e/flarum-ext-mediaembed:0.1.0
    ./composer.json has been updated
    Loading composer repositories with package information
    Updating dependencies (including require-dev)
    Your requirements could not be resolved to an installable set of packages.

    Problem 1
    - The requested package s9e/flarum-ext-mediaembed 0.1.0 exists as s9e/flarum-ext-mediaembed[0.3.0, 0.3.1, 0.3.2, 1.0.0, dev-master] but these are rejected by your constraint.

    Installation failed, reverting ./composer.json to its original content.
    -bash-4.2$ C
    -bash-4.2$ composer require s9e/flarum-ext-mediaembed:0.1.0
    ./composer.json has been updated
    Loading composer repositories with package information
    Updating dependencies (including require-dev)
    Your requirements could not be resolved to an installable set of packages.

    Problem 1
    - The requested package s9e/flarum-ext-mediaembed 0.1.0 exists as s9e/flarum-ext-mediaembed[0.3.0, 0.3.1, 0.3.2, 1.0.0, dev-master] but these are rejected by your constraint.

    Installation failed, reverting ./composer.json to its original content.

    I use Flarum 0.1.0-beta.7

    I really would like your help with this ?...Thank you very much in advance.

    I don't know. Did you run composer require s9e/flarum-ext-mediaembed:*?

    I tried with this: composer require s9e/flarum-ext-mediaembed:0.1.0 (The version that I have of Flarum), but I tried too with the command that you say: composer require s9e/flarum-ext-mediaembed:*, and the error that I get is this:

    -bash-4.2$ composer require s9e/flarum-ext-mediaembed:*
    ./composer.json has been updated
    Loading composer repositories with package information
    Updating dependencies (including require-dev)
    Your requirements could not be resolved to an installable set of packages.
    
      Problem 1
        - s9e/flarum-ext-mediaembed 1.0.0 requires flarum/core ^0.1.0-beta.8 -> satisfiable by flarum/core[0.1.x-dev] but these conflict with your requirements or minimum-stability.
        - s9e/flarum-ext-mediaembed 0.3.2 requires flarum/core ^0.1.0-beta.3 -> satisfiable by flarum/core[0.1.x-dev, v0.1.0-beta.3, v0.1.0-beta.4, v0.1.0-beta.5, v0.1.0-beta.6, v0.1.0-beta.7, v0.1.0-beta.7.1] but these conflict with your requirements or minimum-stability.
        - s9e/flarum-ext-mediaembed 0.3.1 requires flarum/core ^0.1.0-beta.3 -> satisfiable by flarum/core[0.1.x-dev, v0.1.0-beta.3, v0.1.0-beta.4, v0.1.0-beta.5, v0.1.0-beta.6, v0.1.0-beta.7, v0.1.0-beta.7.1] but these conflict with your requirements or minimum-stability.
        - s9e/flarum-ext-mediaembed 0.3.0 requires flarum/core ^0.1.0-beta.3 -> satisfiable by flarum/core[0.1.x-dev, v0.1.0-beta.3, v0.1.0-beta.4, v0.1.0-beta.5, v0.1.0-beta.6, v0.1.0-beta.7, v0.1.0-beta.7.1] but these conflict with your requirements or minimum-stability.
        - Installation request for s9e/flarum-ext-mediaembed * -> satisfiable by s9e/flarum-ext-mediaembed[0.3.0, 0.3.1, 0.3.2, 1.0.0].
    
    Installation failed, reverting ./composer.json to its original content.

    I'm doing something wrong?

      jordanjay29 I feel so embarrassed, you're right, I didn't check if were the correct IP and I was connecting me via ssh to another of my sites where is not installed Flarum.

      Now the extension is correctly installed. Thank you very much for your support ?

      I want to use only the bbcode [media] because i want direct links as they are and not embed them directly. Is possible deactivate the embeding of the direct links?

      No, if you post a URL in plain text you let the software decide how to present it. If you specifically want to create a link, you can use markup, e.g. [url]https://www.youtube.com/watch?v=FlsCjmMhFmw[/url]

        JoshyPHP Yes, the problem is that i have more than 200 posts with plain URLs that i want that they remain as links and not embed them.

        If i install the plugin and activate it, the autoembed will break the contents when plain urls are something that can be embeded ?

        Installing the extension now should not affect posts that were submitted before it was installed. For new posts you'd need to create an extension that disables the MediaEmbed plugin at parsing time with $event->parser->disablePlugin('MediaEmbed').

          9 days later

          MikeJones Yes, this is really bothering me. At least the links with the extension at the end (.gif, .png, etc) should only show the image. Other than that, the plugin is awesome. ?

          25 days later

          Ok I found the solution!
          Type: composer require s9e/flarum-ext-mediaembed:0.3.2
          To the putty.

          There's no user configuration for it, you'd need to program in PHP. If you want to post a link and not have it transformed, use explicit markup, e.g. [url]http://example.org[/url]