Welcome to TalkGraphics.com
Page 1 of 2 12 LastLast
Results 1 to 10 of 27

Thread: Media Player

Hybrid View

  1. #1
    Join Date
    Dec 2018
    Location
    Australia
    Posts
    1,792

    Default Re: Media Player

    Although this one of the better looking ones, it's still of a jukebox/playlist style.

    However, and more importantly, I actually (nearly) understood how it all works. True, I have no clue as to the codelandic language in the page header, but I did understand why the different elements were needed and what role they played.

    If it were a maths test, I would have a B+ in add ups.

  2. #2
    Join Date
    Apr 2012
    Location
    SW England
    Posts
    17,918

    Default Re: Media Player

    Quote Originally Posted by Chris M View Post
    Although this one of the better looking ones, it's still of a jukebox/playlist style.
    However, and more importantly, I actually (nearly) understood how it all works. True, I have no clue as to the codelandic language in the page header, but I did understand why the different elements were needed and what role they played.
    If it were a maths test, I would have a B+ in add ups.
    Chris, now you have confused me. You provided an image of multiple players and I built as close a facsimile. Earlier, I had suggested the use of a single Player with selectable Tracks.
    The multi-player design I came up with will keep state of where any paused Track has reached and only plays one Track at a time.

    What is missing?

    Acorn
    Acorn - installed Xara software: Cloud+/Pro+ and most others back through time (to CC's Artworks). Contact for technical remediation/consultancy for your web designs.
    When we provide assistance, your responses are valuable as they benefit the community. TG Nuggets you might like. Report faults: Xara Cloud+/Pro+/Magix Legacy; Xara KB & Chat

  3. #3
    Join Date
    Dec 2018
    Location
    Australia
    Posts
    1,792

    Default Re: Media Player

    Maybe nothing is missing. Maybe it's me that is missing something. Let me rephrase the 'it's still a playlist' to it's still a playlist...the way I tried it.

    I'd like to try and work it out for myself as I'm clearly clumping all the tracks into one player (placeholder). I'm still playing and head scratching, like you said I would . I haven't given up yet, I have faith.

  4. #4
    Join Date
    Dec 2018
    Location
    Australia
    Posts
    1,792

    Default Re: Media Player

    I've worked out how to change the path to the audio files, which is quite important in this case.

    Unless I'm still missing something, this is a playlist/jukebox style of player. In other words, one player, multiple tracks. For instance, if you want a block of text separating two genres then this won't do it as the tracks are in an array, you would need a separate page for each genre.

    I've never played with Supersites, but I'm under the impression a Supersite will make separate pages appear to act as one with, for instance, vertical scrolling as an option. If so, this would be an answer presuming the changing of pages would kill off the previous page's player.

    It may also be possible to have several 'named' players, but I'm wandering into the great unknown on my part with that theory.
    Still happily playing and learning.

  5. #5
    Join Date
    Dec 2018
    Location
    Australia
    Posts
    1,792

    Default Re: Media Player

    Created a Supersite with four separate pages set to Vertical scrolling.
    Created a placeholder on 2 of the pages and set up the media player files on each page (2 tracks per page)
    Previewed the site and had all four tracks in the first player and a blank space in the second player

  6. #6
    Join Date
    Apr 2012
    Location
    SW England
    Posts
    17,918

    Default Re: Media Player

    Quote Originally Posted by Chris M View Post
    Created a Supersite with four separate pages set to Vertical scrolling.
    Created a placeholder on 2 of the pages and set up the media player files on each page (2 tracks per page)
    Previewed the site and had all four tracks in the first player and a blank space in the second player
    The code for each Player must have different name= and id=.

    Acorn
    Acorn - installed Xara software: Cloud+/Pro+ and most others back through time (to CC's Artworks). Contact for technical remediation/consultancy for your web designs.
    When we provide assistance, your responses are valuable as they benefit the community. TG Nuggets you might like. Report faults: Xara Cloud+/Pro+/Magix Legacy; Xara KB & Chat

  7. #7
    Join Date
    Dec 2018
    Location
    Australia
    Posts
    1,792

    Default Re: Media Player

    I couldn't find the 'name=', but did find references to the player in general and after adding and removing the identifiers 80 and 90 (80s & 90s tracks) I managed to fail miserably.

    They both work as intended on separate pages, but convert to a Supersite and the players show, but will not play. Too tired to play anymore tonight...to be resumed.

    Attached: the bits I added the 80 & 90 to and a zoomed out screenshot showing the players in place.

    Click image for larger version. 

Name:	Audio Player.jpg 
Views:	117 
Size:	124.8 KB 
ID:	123545 Click image for larger version. 

Name:	SS.jpg 
Views:	107 
Size:	83.8 KB 
ID:	123546
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	1.png 
Views:	91 
Size:	34.3 KB 
ID:	123544  

  8. #8
    Join Date
    Mar 2019
    Posts
    1

    Default Re: Media Player

    Can someone just tell me how I can get a sound file to play when someone clicks on a picture? I know this is the wrong place to pose this question, but I cannot see how to start a thread.

  9. #9
    Join Date
    Dec 2018
    Location
    Australia
    Posts
    1,792

    Default Re: Media Player

    An elegant answer is to have the controls available for the visitor.

    Clone your picture (ctrl+k)
    Right click the clone and choose 'Web Properties'
    Click 'Placeholder' > 'HTML Code (Body)' and paste the following code

    <audio style="width:500px;height:60px" controls>
    * * <source src="PATH TO YOUR AUDIO FILE.mp3" type="audio/mpeg">
    Your browser does not support the audio element.
    </audio>

    The results look like the image below.
    Click image for larger version. 

Name:	Player.png 
Views:	124 
Size:	201.1 KB 
ID:	123622

  10. #10
    Join Date
    Apr 2012
    Location
    SW England
    Posts
    17,918

    Default Re: Media Player

    Quote Originally Posted by Chris M View Post
    An elegant answer is to have the controls available for the visitor.

    Clone your picture (ctrl+k)
    Right click the clone and choose 'Web Properties'
    Click 'Placeholder' > 'HTML Code (Body)' and paste the following code

    <audio style="width:500px;height:60px" controls>
    * * <source src="PATH TO YOUR AUDIO FILE.mp3" type="audio/mpeg">
    Your browser does not support the audio element.
    </audio>

    The results look like the image below.
    Click image for larger version. 

Name:	Player.png 
Views:	124 
Size:	201.1 KB 
ID:	123622
    Chris, my approach is a complete flip to yours.
    Drag and drop your mp3 onto the design page and accept the Do not Autostart option.
    This creates your audio controls placeholder.
    In the body code of the placeholder include the phrase id="songX"
    <audio id="weapon" class="xar_meplayer" id="songX" src="index_htm_files/chooseyourweapon.mp3" controls width = "100%" height="100%"/>
    On the image, add a Link:
    javascript: document.getElementById("songX").play();
    "songX" can be any phrase, just ensure it is the same in the control and the link.

    Clicking the actual image starts the audio.

    Other shapes can have .pause() or .stop() and the audio control can be then hidden away.

    Acorn
    Acorn - installed Xara software: Cloud+/Pro+ and most others back through time (to CC's Artworks). Contact for technical remediation/consultancy for your web designs.
    When we provide assistance, your responses are valuable as they benefit the community. TG Nuggets you might like. Report faults: Xara Cloud+/Pro+/Magix Legacy; Xara KB & Chat

 

 

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •