rejetto forum

Play sound file on home page load

Guest · 7 · 6878

0 Members and 1 Guest are viewing this topic.

Drise

  • Guest
Is this possible? And if so, how? I would assume it would use the RAWR player and have it stream it as is the magnifying glass "preview" was clicked.


Offline TSG

  • Moderator
  • Tireless poster
  • *****
    • Posts: 1935
    • View Profile
    • RAWR-Designs
Yeah, there is several ways you could do it actually. We already have a 'play media' function in the code. I don't remember now but there is a way to popup a preview box and play the media in Terayon and RAWR-Template, via a function/url variable. Play a song, then right click the player, you will receive a link. Then figure out how to use that on page load.

It would be very annoying for visitors though, I am not sure its the best way.

You could also just embed the player somehow on the homepage.


Drise

  • Guest
Well, I'm not very proficient with web page coding/design. Could you, or someone, give like an example piece of code for the embedded player?


Offline Mars

  • Operator
  • Tireless poster
  • *****
    • Posts: 2063
    • View Profile
Quote
someone, give like an example piece of code for the embedded player?


We are waiting all for the return of Giant Eagle for that, media players are the privilege of the rawr team  ;D
« Last Edit: June 13, 2010, 08:23:33 PM by Mars »


Offline TSG

  • Moderator
  • Tireless poster
  • *****
    • Posts: 1935
    • View Profile
    • RAWR-Designs
Code: [Select]
<object type="application/x-shockwave-flash" data="[color=red]--LINK TO PLAYER--[/color]rawr_player.swf" width="500" height="50">
<param name="movie" value="[color=red]--LINK TO PLAYER--[/color]rawr_player.swf"/>
<param name="allowscriptaccess" value="always"/>
<param name="allowfullscreen" value="true"/>
<param name="wmode" value="direct"/>
<param name="flashvars" value="theme={.!theme.}&autoplay=1&file=[color=red]--LINK TO FILE--[/color]"/>
</object>

I think that is set up for MP3.
« Last Edit: June 14, 2010, 12:45:18 PM by TSG »



Drise

  • Guest
For anyone who is wanting to know how to specifically play only on the home page:

Under [special:strings] you'll find this bit bellow:

Code: [Select]
--- Other settings:
mod_updates=off
mod_folder_tasks=on
mod_search=on
mod_statistics=off
mod_shoutbox=on
sym_ip=on
btn_back=on
create_folder=on
rename=on

Add onto those variables with something like

Code: [Select]
--- Other settings:
mod_updates=off
mod_folder_tasks=on
mod_search=on
mod_statistics=off
mod_shoutbox=on
sym_ip=on
btn_back=on
create_folder=on
rename=on
example=

and past the = paste (on one line)

Code: [Select]
<object type="application/x-shockwave-flash" data...

/template/rawr_default/players/rawr_player.swf

given above.

Now find

Code: [Select]
<!--{.comment|--><h1>WARNING: This template will only work with HFS 2.3 or greater; macros must be enabled.</h1><!--.} -->
and right above it paste

Code: [Select]
{.switch|%folder%|;|
/|{.!example.}|
.}


P.S.

The link to the player that comes default with the RAWR template is

Code: [Select]
http://<SERVER ADDRESS HERE>/template/rawr_default/players/rawr_player.swf
I'm also attaching my template, which does have some minor modifications, for anyone wanting to see the whole thing.
« Last Edit: June 21, 2010, 07:40:12 AM by TSG »