Advertisement:

Author Topic: Play Media Attachments  (Read 27509 times)

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 73,189
Re: Play Media Attachments
« Reply #100 on: September 18, 2017, 06:04:22 AM »
Because this stuff is actually *hard* to get right.

SMF attachments never provide content-range out of the box, not 100% sure if this mod does it, because it's also hard to get right as ranged headers in general are the devils work. (For more information, take a look at LevGal which has a lot of code that might be useful to you)
No good deed goes unpunished
All helpful urges should be circumvented

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #101 on: September 18, 2017, 10:31:30 AM »
OH MY GOD!!!   SERIOUSLY??!?!?!?   ARGHHH!!!

Okay, now that I got that out of my system, I can try to fix the mod using this new information.  I was completely unaware that I was missing anything in this regard.  Thanks, Juanchoartes and Arantor for providing the clues I needed to get this right.



@Arantor:  Nope, this mod does not provide content-range or content-length as a part of it's standard response.  SMF 2.0.x provides content-length, but only if either we're doing compressed output or the file size is greater than 4M....

EDIT:  Looks like SMF 2.1 Beta 3 is pretty similar to SMF 2.0.x in this regard.

@Juanchoartes:  I'll try to implement a fix for this issue.

Offline Steve

  • Freak
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 4,733
  • Gender: Male
  • I have not yet begun to procrastinate.
Re: Play Media Attachments
« Reply #102 on: September 18, 2017, 10:48:07 AM »
And the error I'm getting?
Please do not PM me for support.

I just ordered a life alert bracelet so
if I get a life, I'll be notified immediately.

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #103 on: September 18, 2017, 11:09:22 AM »
And the error I'm getting?
Whoops!  Sorry I missed that message!  I've fixed it for the next version.

Offline Juanchoartes

  • Semi-Newbie
  • *
  • Posts: 28
Re: Play Media Attachments
« Reply #104 on: September 18, 2017, 11:34:09 AM »
Thank you very much @dougiefresh!

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #105 on: September 22, 2017, 10:49:18 PM »
UPDATE:  I've been trying to integrate code into the attachment download function in order to do ranged downloads and it is screwing up my test install (where it concerns media files)....  It is being a complete b#tch... 

Also, Levertine Gallery (which I assume is LevGal) is still live, but registering on the forum is disabled, purchasing is disabled (as if I had the money!), plus the ability to downloading it is non-existent....  So I'm at a loss on how to look at that project to see how it was done....  Frankly, from what little is available on their forum, that project might be dead and buried....

I've found a few more minor bugs and have fixed them for the next version.  I'll release the fixed version probably tomorrow, as I'm going to sleep now.

Offline lurkalot

  • Support Specialist
  • SMF Hero
  • *
  • Posts: 1,759
  • Gender: Male
  • Tinyportal Support
    • guitaristguild on Facebook
    • Tinyportal on GitHub
    • @GuitaristGuild on Twitter
    • Guitarist Guild
Re: Play Media Attachments
« Reply #106 on: September 23, 2017, 04:06:51 AM »

Also, Levertine Gallery (which I assume is LevGal) is still live, but registering on the forum is disabled, purchasing is disabled (as if I had the money!), plus the ability to downloading it is non-existent....  So I'm at a loss on how to look at that project to see how it was done....  Frankly, from what little is available on their forum, that project might be dead and buried....


You will find a very generous post by Arantor right here, where you can pick up a copy of Levgal https://www.simplemachines.org/community/index.php?topic=525210.msg3921971#msg3921971

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #107 on: September 23, 2017, 09:59:18 AM »
Holy sheep!  I missed that (although not suprised, since attachments don't show up on Yahoo search....)  Thanks a bunch, lurkalot!

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #108 on: December 08, 2017, 10:51:46 PM »
Uploaded v2.2 - December 8th, 2017
o Fixed several undefined element/variable errors in the mod.

Offline Steve

  • Freak
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 4,733
  • Gender: Male
  • I have not yet begun to procrastinate.
Re: Play Media Attachments
« Reply #109 on: December 09, 2017, 04:11:45 PM »
Why when uninstalling the previous version do I get a test failed with 'ignore errors' in parenthesis? (see attachment)
Please do not PM me for support.

I just ordered a life alert bracelet so
if I get a life, I'll be notified immediately.

Offline Rock Lee

  • Native Language Support Specialist
  • SMF Hero
  • *
  • Posts: 3,873
  • Gender: Male
  • Learning more every day!
    • BomberCode.Oficial on Facebook
    • RockLee-BC on GitHub
    • @Bomber_Code on Twitter
    • Bomber Code ~ La nueva era del conocimiento
Re: Play Media Attachments
« Reply #110 on: December 13, 2017, 07:40:12 PM »
I thought you had left the translation, I leave it attached although I have a question with the MIME itself, that's why I translated it to my opinion if something is wrong you let me know.


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

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #111 on: December 15, 2017, 03:12:04 PM »
Uploaded v2.3 - December 15th, 2017
o Added Spanish Latin translation, courtsey of Rock Lee!
o Added missing add/remove hooks entry for proper mod uninstallation.



@Rock Lee:  Thank you for the translation!  It's been included in this version!

Offline Steve

  • Freak
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 4,733
  • Gender: Male
  • I have not yet begun to procrastinate.
Re: Play Media Attachments
« Reply #112 on: December 15, 2017, 04:51:04 PM »
So what do I do about the errors uninstalling the previous version? Ignore them or not?
Please do not PM me for support.

I just ordered a life alert bracelet so
if I get a life, I'll be notified immediately.

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #113 on: December 15, 2017, 04:54:40 PM »
@Steve:  Sorry for getting back to you so late.  The PersonalMessage.php file has a single operation, which I'm pretty sure is related to PM Attachments.  If you don't have that mod installed, then you can ignore the error.  If you do have it installed, then you need to fix the issue before uninstalling.  Is that the file you are having an issue with?  Your picture shows so much....  ::)

Offline Steve

  • Freak
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 4,733
  • Gender: Male
  • I have not yet begun to procrastinate.
Re: Play Media Attachments
« Reply #114 on: December 15, 2017, 05:15:35 PM »
Sorry about the image. I deserved that verbal spanking lol ...

I don't have PM Attachments installed but attached is the full width image.
Please do not PM me for support.

I just ordered a life alert bracelet so
if I get a life, I'll be notified immediately.

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #115 on: December 15, 2017, 08:23:48 PM »
@Steve: Verbal spanking...   O:)  I LOL'ed at that...   8) That operation is to properly support an installation with the PM attachment mods installed....


I have noticed that in Firefox, the attached audio doesn't play well. The audio plays but the total duration of the audio doesn't appear and you can't go forward in the timeline. When the audio finishes, the following appears in the place where the audio duration was: "Infinity: NaN: NaN". I have attached an image with the explanation. In Chrome, the audio plays perfect and you can click in the timeline to move forward or backward.

I have been researching and it seems that this problem would be more related to Firefox. In this link they say something about that: https://stackoverflow.com/questions/6887867/html5-audio-video-tag-duration-on-firefox

"Make sure that your server sets the content-length and content-range properties in his response-header." (which I haven't understood).

Any idea of why in Firefox the audio file is playing wrong?
I've tried integrating the content-range and content-length and other range-related s#@t into the download code, without success.  I'm working on a seperate script to provide the video download; failing that, the attachment system will be modified to do direct downloads of the video file.  I hate doing that last one, though....  I at least have some control with a script....
« Last Edit: December 15, 2017, 08:35:06 PM by dougiefresh »

Offline Steve

  • Freak
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 4,733
  • Gender: Male
  • I have not yet begun to procrastinate.
Re: Play Media Attachments
« Reply #116 on: December 16, 2017, 01:42:31 PM »
The mod works fine but the attached is what the player looks like after it's done playing the file.

Is that normal?
Please do not PM me for support.

I just ordered a life alert bracelet so
if I get a life, I'll be notified immediately.

Offline Steve

  • Freak
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 4,733
  • Gender: Male
  • I have not yet begun to procrastinate.
Re: Play Media Attachments
« Reply #117 on: December 18, 2017, 09:10:24 AM »
Any chance you've looked at this Dougie?
Please do not PM me for support.

I just ordered a life alert bracelet so
if I get a life, I'll be notified immediately.

Offline dougiefresh

  • SMF Hero
  • ******
  • Posts: 2,859
  • Mod King
    • XPtsp.com Community
Re: Play Media Attachments
« Reply #118 on: December 18, 2017, 09:14:11 AM »
When I run the mod in localhost, the video just stops at (what I assume is) the last frame of the video.  I'm using the attached video to test with....

Offline Steve

  • Freak
  • Support Specialist
  • SMF Hero
  • *
  • Posts: 4,733
  • Gender: Male
  • I have not yet begun to procrastinate.
Re: Play Media Attachments
« Reply #119 on: December 18, 2017, 10:57:24 AM »
Okay ... that's bizarre. Tried your video and it worked fine so I was going to attach the audio file I had tested but I tried it again before I did and it worked fine.

So I guess whatever gremlin was messing with me left town. :P
Please do not PM me for support.

I just ordered a life alert bracelet so
if I get a life, I'll be notified immediately.