Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: 1 2 [3]   Go Down

Author Topic: Music for your site  (Read 75278 times)

0 Members and 1 Guest are viewing this topic.

rphMedia

  • Contributor
  • Coppermine addict
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 515
  • ***muvipix.com***
    • muvipix - Music | Video | Pictures
Re: Music for your site
« Reply #40 on: March 26, 2005, 04:48:25 pm »

Opps, sorry about that.  Change the span tag and the document.getElementById to music1.  

<span id="music1">
document.getElementById('music1')


I also fixed the above posted code.

I guess FF was confused about the player and the span ID being the same name - IE didn't care.  Should work perfect now. Thanks for catching that!

Nik

  • Coppermine newbie
  • Offline Offline
  • Posts: 13
Re: Music for your site
« Reply #41 on: March 27, 2005, 12:55:05 am »

thanks
Logged

jarekn

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 47
Re: Music for your site
« Reply #42 on: November 07, 2005, 05:16:25 am »

Nice One :)

Any way to set default song to play on load? and better yet any way for it to keep on playing the ohter songs after it in sequence? So if someone were to select 3rd song that it would play 4th song right after it and so on?



Here's a new code for a dropdown menu if desired.  Works in all browsers (as far as I know - IE / FF for sure).  Modify the urls to your liking.

Enjoy!

Code: [Select]
<HTML>
<HEAD>
<title>Your Title</title>
<script type="text/javascript"><!--
function song(){
document.getElementById('music1').innerHTML="<embed type='application/x-mplayer2' id='music' pluginspage='http://www.microsoft.com/Windows/MediaPlayer/' src='"+document.getElementById('cancion').value+"' name='music' width='100%' height='45' controltype='2' showcontrols='1' showstatusbar='0' AutoStart='true'></embed>";
}
//-->
</script>
</head>
<body bgcolor="#E1E4F2" topmargin="0px" rightmargin="0px" bottommargin="0px" leftmargin="0px" scroll="no">
<center><iframe src="index.php" width="100%" height="92%" frameborder="0" allowtransparency="true" scrolling="auto" name="myInlineFrame"></center>
Your browser doesn't seem to support "frames"</iframe>
<div align="center">
  <center>
  <table border="0" cellpadding="0" cellspacing="0" width="100%">
    <tr>
      <td width="28%" valign="middle" align="center">
<select  id="cancion" onchange="song()" size="1">
<OPTION selected>::::::::::::: Choose Your Music Here :::::::::::::</OPTION>        
      <OPTION value=http://radio.msn.com/asx/generate.aspx?type=genre&id=10002389>New Age</OPTION>
      <OPTION value=http://radio.msn.com/asx/generate.aspx?type=genre&id=10002399>Pop</OPTION>
      <OPTION value=http://radio.msn.com/asx/generate.aspx?type=genre&id=10002392>Jazz</OPTION>
      <OPTION value=http://radio.msn.com/asx/generate.aspx?type=genre&id=10002364>Country</OPTION>
      <OPTION value=http://radio.msn.com/asx/generate.aspx?type=genre&id=10002378>Rock</OPTION></SELECT></td>
      <td width="72%" valign="bottom" align="center">
<span id="music1"><embed type="application/x-mplayer2" id="music" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" width="100%" height="45" enablecontextmenu="0" src="" ShowDisplay="0" showcontrols="1">
     </td>
    </tr>
  </table>
  </center>
</div>
</body>
</html>

You can see it here




« Last Edit: November 07, 2005, 07:14:16 am by jarekn »
Logged

peps

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 21
    • Photos of famous people
Re: Music for your site
« Reply #43 on: May 11, 2006, 01:38:54 pm »

The code works just fine. I have one small problem when I write out my page url the iframe does not show up! If I however write our mydomain.com/index.htm I can see the drop down menu with stations. What should I change in order to load index.htm as strat page and not index.php?

peps

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 21
    • Photos of famous people
Re: Music for your site
« Reply #44 on: May 11, 2006, 01:56:29 pm »

OK i solved it. Here is the solution if some other newbie is looking for this:

With note pad make a file named: .htaccess (no txt extension or whatever just this)
Then add the line:

DirectoryIndex index.html index.htm index.php

Put the .htaccess file in your web root directory.

louisli

  • Coppermine newbie
  • Offline Offline
  • Posts: 12
Re: Music for your site
« Reply #45 on: June 29, 2008, 10:29:32 am »

Does this work for some specific albums?
I don't want the whole gallery has music, just 1 of my albums

same editing method? ???
thanks.
Logged
QNAP TS-109 pro NAS box
Apache 1.3.28
PHP 5.2.0
MySQL 5.0.27
CPG 1.4.18

troy77

  • Coppermine newbie
  • Offline Offline
  • Posts: 7
Re: Music for your site
« Reply #46 on: November 13, 2008, 07:50:57 pm »

Hi all.
The mod is great thanx, just 1 small thing. Im using mp3s instead of a station which works fine the only thing is i can only have 1 track on the site. Is it possible to put more in, say up 2 around 10 tracks?
This is what i tried:
<param name="URL" value="music/02.mp3, 01.mp3, 05.mp3">
But had no joy it will only play the first 1, 02.mp3.
Can someone help with this please?
Was going to start another thread but didnt think that would go down well so just hopeing someone sees this one.

Thanks guys
Logged

rphMedia

  • Contributor
  • Coppermine addict
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 515
  • ***muvipix.com***
    • muvipix - Music | Video | Pictures
Re: Music for your site
« Reply #47 on: November 13, 2008, 08:25:01 pm »

If you read through the thread, there are ways - http://forum.coppermine-gallery.net/index.php/topic,11106.msg74854.html#msg74854 ( hint - look for "option" [dropdown menu] ). Just replace the URLs with your MP3 paths.

troy77

  • Coppermine newbie
  • Offline Offline
  • Posts: 7
Re: Music for your site
« Reply #48 on: November 13, 2008, 08:46:02 pm »

Thanx for that. I was going off the first code.
Is it possible to not have the dropdown and have it play automaticly with the media player at the bottom with the skip feature like the first code?
Thanx
Logged

rphMedia

  • Contributor
  • Coppermine addict
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 515
  • ***muvipix.com***
    • muvipix - Music | Video | Pictures
Re: Music for your site
« Reply #49 on: November 13, 2008, 08:53:10 pm »

A playlist is probably what you're looking for. Try Google for that and if you get stuck, I'll see what I can do.

troy77

  • Coppermine newbie
  • Offline Offline
  • Posts: 7
Re: Music for your site
« Reply #50 on: November 13, 2008, 08:58:38 pm »

Yeah something like a playlist, ill keep looking for 1,
thanx alot mate
Logged

troy77

  • Coppermine newbie
  • Offline Offline
  • Posts: 7
Re: Music for your site
« Reply #51 on: November 13, 2008, 09:30:11 pm »

Ok everyone I sorted it, I took the first code and just created a .m3u file which is just a list of the songs you want to play. This is what it should look like in the index.htm:
<param name="URL" value="play.m3u">

This gives your visitors the choice to change track as well
Logged

troy77

  • Coppermine newbie
  • Offline Offline
  • Posts: 7
Re: Music for your site
« Reply #52 on: November 16, 2008, 08:50:31 pm »

Hi again, Im gonna be a pain now lol.

Is there a way to have diffrent music for certain albums??
I ask because Im do a special album for someone close who has passed so didnt want the music from the main site coming through but the music fron the memories.

Thanx again ;D
Logged

rphMedia

  • Contributor
  • Coppermine addict
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 515
  • ***muvipix.com***
    • muvipix - Music | Video | Pictures
Re: Music for your site
« Reply #53 on: November 18, 2008, 01:08:55 pm »

Hi again, Im gonna be a pain now lol.

Is there a way to have diffrent music for certain albums??
I ask because Im do a special album for someone close who has passed so didnt want the music from the main site coming through but the music fron the memories.

Thanx again ;D
Sorry, I have no idea if that's possible.

VaporDesigns

  • Coppermine newbie
  • Offline Offline
  • Posts: 12
    • Vapor Designs
Re: Music for your site
« Reply #54 on: January 07, 2009, 06:17:40 pm »

Interesting bit o code...i will test later :)
Logged

KOREntertainment

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 72
Re: Music for your site
« Reply #55 on: January 15, 2009, 03:46:07 am »

OK, here's a trick if you want music at your Coppermine Gallery.  I see many, many posts by users who are struggling with this one.  It's so simple, it's not even funny :) and this is really not that invasive (later I will try to create a dhtml to open and close the player [window]).

Put your start page in an iframe.  Here's the basic code, you can play with all the parameters to get it to where you want it.  Mine's pointing to a new age streaming radio station on the net (nice for viewing images anyway).

Code: [Select]
<html>
<head>
<title>Online Photo Album</title>
<link rel="stylesheet" href="themes/yourtheme/style.css" />
</head>
<body bgcolor="#000000" topmargin="0" leftmargin="0" scroll="no">
<div align="center">
<table width="100%" height="90%">
<tr>
<td align="center">
<iframe src="index.php" width="100%" height="100%" frameborder="0" ALLOWTRANSPARENCY="true" scrolling="auto" name="myInlineFrame">
Your browser doesn't seem to support "frames"</iframe>
</td>
</tr>
</table>
<object classid="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6" id="WMP1" Style="border-style: none; border-width: 0; margin: 0" width="100%" height="60">
<param name="URL" value="yourmusic.mp3">
<param name="AutoStart"    value=false>
<param name="AutoRewind"   value=true>
</object>
</div>
</body>

Name it index.htm and you can still access your gallery with a folder. This is simply embedding the WMP ActiveX control below the iFrame.  Now, when your vistor navigates around your gallery, the music continues throughout and of course, they can stop/pause anytime.  Your visitor has the option to play music (or not) upon arrival.  I personally wouldn't want it to start auto, though it can be done by changing that parameter.  And it doesn't have to be on the bottom; I thought mine looked better this way. The music itself could be a playlist, one file, or a url to streaming media (lots of them out there).  I hope you find this useful - enjoy!






I incerted this code in a blank page on dream weaver, added my file and opened it in the browser and it played.  Can I get some step by step instructions on how to import this code into my gallery?  I have no clue as to where to start.
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Music for your site
« Reply #56 on: February 05, 2009, 08:41:26 am »

Don't use Dreamweaver. Please read up http://forum.coppermine-gallery.net/index.php/topic,57889.0.html or similar threads that explain what editors to use. Dreamweaver doesn't fall into the category "recommended editor", as it tends to "beautify" code by its own.
Logged
Pages: 1 2 [3]   Go Up
 

Page created in 0.031 seconds with 19 queries.