User Controls

Video Embeds - Case Sensitive

  1. #1
    aldra JIDF Controlled Opposition
    you can use video tags to embed standard videos with lowercase extensions, but if they're either uppercase or partially uppercase the embed fails

    ie.

    [video]https://pomf2.lain.la/f/4qxmuz0c.MP4[/video]

    does not work even though the file is valid. normally I'd just rename and reupload, but hosts often detect the video hash and just give me a link to the original uppercase file instead of re-generating a new one:

  2. #2
    Bradley Florida Man
    I've been wondering about this extensively.
  3. #3
    aldra JIDF Controlled Opposition
    I'm hoping it's something lanny can fix with a one-line change

    I could download the code and HAVE A PULL but I don't want to
  4. #4
    so thats why.

    edit: just manually change the ext to small case
  5. #5
    Originally posted by vindicktive vinny edit: just manually change the ext to small case


    Wow, you must be some kind of computer genius or something...
  6. #6
    Originally posted by Jiggaboo_Johnson Wow, you must be some kind of computer genius or something…

    why yes.

    i am.
  7. #7
    troon African Astronaut
    I'm thinking line 121 is looking for a lower-case extension and then deciding it's not a video.

    Maybe Sophie could fix this. Sophie?

    iss_bbcode.py


    113 ext = url.path.split('.')[-1]
    114
    115 if url.netloc in ('www.youtube.com', 'youtube.com', 'm.youtube.com'):
    116 return _embed_youtube(url)
    117 elif url.netloc in ('youtu.be',):
    118 return _embed_youtube_shortcode(url)
    119 elif url.netloc in ('bitchute.com', 'www.bitchute.com'):
    120 return _embed_bitchute(url)
    121 elif ext in ('webm', 'mp4'):
    122 return _embed_html5_video(url)
    123 else:
    124 raise EmbeddingNotSupportedException('Unrecognized service.')
    125

Jump to Top