Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Dplayer

2

Comments

  • So Dinoboff, it adds the player.js twice?

    Once in the head section and again at the end of the body section?

    Posted: Wednesday, 28 March 2007 at 10:19AM

  • No, there is only one render control instance, that will render just before the footer.
    <?php /* Extension Name: Dplayer Extension Url: http://lussumo.com/addons/ Description: Turns plain links to mp3 files into playable icons. Version: 0.0.1 Author: Wanderer - Joe Debono Author Url: http://www.debono.com.au/forum/ */ if (in_array($Context->SelfUrl, array('index.php', 'categories.php', 'comments.php', 'post.php'))) { class debplayer extends Control { var $Context; function debplayer(&$Context) { $this->Name = 'debplayer'; $this->Context = &$Context; } function Render() { echo '<script type="text/javascript" src="'. $this->Context->Configuration['WEB_ROOT'] .'extensions/Dplayer/player.js"></script>'; } } $debplayer = new debplayer($Context); $Page->AddRenderControl($debplayer, $Configuration['CONTROL_POSITION_FOOT'] - 5); } ?>
  • I beg to differ mate, it, gets added in the head and in the body sections.

    What confuses me is that the head reference is relative and the body reference is absolute, they both work for me, but others say the relative method does not work.

    The other consideration, due to the way the script works, is that it must load after the page load is complete.

    I took out $Head->AddScript('extensions/Dplayer/player.js'); so it only loaded at the end of the body section and it worked.

    Then I took out the function Render() and put back $Head->AddScript('extensions/Dplayer/player.js'); and although the .js file was added to the head correctly, the script failed to activate because the page had not loaded yet.

    Posted: Wednesday, 28 March 2007 at 11:15AM

  • I overlooked the details again and missed it.

    ps: I edited it and took it off
  • We are going around in circles. pic
    Now we are back to the current version 1.0.1 which emsef says causes this error...

    Notice: Trying to get property of non-object in /forum/extensions/Dplayer/default.php on line 20

    Posted: Wednesday, 28 March 2007 at 12:07PM

  • ... class debplayer extends Control { var $Context; function debplayer(&$Context) { ... $this->Context = &$Context; } function Render() { ... $this->Context->Configuration['WEB_ROOT'] ... } } $debplayer = new debplayer($Context);

    $this->Context->Configuration is defined
  • Uploaded version 1.0.2 of Dplayer.
  • v1.0.2 - Includes contextual link to the .js file

    This should address issues to it not being found.

    Posted: Friday, 30 March 2007 at 12:47PM

  • mattmatt ✭✭
    Hoorah! Works immediately on install, no messing around. :)

    Thanks for everybody's effort on this one.
  • *bows* --- *Elvis Voice* Thank you very much! pic

    Posted: Friday, 30 March 2007 at 7:46PM

  • I have problems with version 1.0.2 in Firefox, the play-icon is simply not displayed. In IE6 and Opera everything is ok. It's a problem only in my forum, since the demosite (mentioned in the howto.txt) displays it correctly in Firefox.

    http://audioten.scythoior.com/comments.php?DiscussionID=14&page=1#Item_3
    (You have to log in on audioten.scythoior.com first in order to see the discussion.
    Login: "wartung(scy)", Password: "bluehead")

    Any ideas?
  • OK, I can confirm your test works on Safari and it does not in Mac Firefox 2.0.0.3.
    I don't understand because it works for me on all browsers.

    The .js file is found but something is stopping the script from firing.

    Maybe one of the many errors the page generates...

    Warning: Error in parsing value for property 'display'. Declaration dropped.
    Source File: http://audioten.scythoior.com/themes/vanilla/styles/green/vanilla.css
    Line: 1528

    Warning: Error in parsing value for property 'display'. Declaration dropped.
    Source File: http://audioten.scythoior.com/themes/vanilla/styles/green/vanilla.print.css
    Line: 1069

    Error: $ is not defined
    Source File: http://audioten.scythoior.com/yshout/js/jquery.js
    Line: 14

    Warning: Unknown property 'filter'. Declaration dropped.
    Source File: http://audioten.scythoior.com/yshout/css/yshout.css
    Line: 169

    Error: document.forms.frmPostDiscussion has no properties
    Source File: http://audioten.scythoior.com/extensions/Quicktags/quicktags.js
    Line: 321

    Posted: Sunday, 1 April 2007 at 3:26PM

  • ok, so there's no problem with the player add-on.
    i guess i have to live for a while with that problem, cause the vanilla green style hasn't been updated to match vanilla 1.1.x criteria and, as i just decided to start learning css/xhtml and so on it will take a good while til i'll be able to do fixes myself ;-)
  • It will be great, if this extention will be playing mp3 files added as atttachements to post, like imagess in inlineImages ext. What do you think ?
  • Yup, that would be great. All you need is the URL to the mp3 file and it will work.

    Posted: Tuesday, 17 July 2007 at 7:53AM

  • But the problem is that attachement extention doesen't create direct url to file, but something like this :
    http://mysite.com/discussions/?PostBackAction=Download&AttachmentID=6
    and Dplayer doesen't recognize is it .mp3 or different file type.
  • Surely though, the mp3 file has a URL you can point to?

    In any case Dplayer is complete as it meets my original needs and no further development is planned.

    Feel free to use it to develop your own if you wish.

    Posted: Tuesday, 17 July 2007 at 8:14PM

  • This is a good point - perhaps MSB would be willing to add this "Attachments compatibility" to JQMedia (although it may require Jazzman changing something in Attachments I'd imagine).
  • there is also some stuff with a .swf in the code. can i use the flash version instead of that image stuff?
  • The .swf is the Flash engine that drives it, a mini Flash application actually.
    The images are required for the interface, make your own if you like, that's why they are external to the .swf

    Posted: Tuesday, 20 November 2007 at 6:04AM

This discussion has been closed.