Author Topic: [MOD]Music for your Pictures  (Read 31060 times)

0 Members and 1 Guest are viewing this topic.

Rembrandt

  • Guest
[MOD]Music for your Pictures
« on: July 26, 2009, 09:52:10 PM »
Hi!

Mit dieser Modifikation ist es möglich zu jeden Bild auf der Detailseite mittels eines integrierten Flashplayers,
eine andere mp3 Datei abzuspielen.
Der Flashplayer ist includiert.

Demo:http://demo.vienna-pictures.com

Neu Dateien:
audio_bit.html
emff_silk.swf

Dateien zu ändern:
ein neuer Datenbank eintrag
admin/images.php
includes/db_definitions.php
lang/yourLanguage/main.php
details.php
templates/yourTemplates/detail.html

1.)Erstellt einen neuen Datenbankeintrag, im Anhang befindet sich die Datei "audio_install.php"
kopiert sie in euren rootorder der Galerie und führt sie aus.

2.)Im Anhang befindet sich die Datei "emff_silk.swf", kopiert sie in euer templates/YourTemplates Verzeichniss.

3.)Erstellt eine neue Datei mit den Namen "audio_bit.html" ,
 und kopiert sie in euer Templates/YourTemplates Verzeichniss, mit folgenden inhalt:

<object type="application/x-shockwave-flash" data="{template_url}/emff_silk.swf" width="88" height="40"/>
 <
param name="movie" value="{template_url}/emff_silk.swf"/>
 <
param name="bgcolor" value="#ffffff"/>
 <
param name="FlashVars" value="src={media_src}&amp;autoload=yes&amp;autostart=yes&amp;repeat=yes&amp;volume=99"/>
 </
object>


4.)Sucht in templates/YourTemplates detail.html:

{lightbox_button}&nbsp;&nbsp;{postcard_button}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{download_button}&nbsp;&nbsp;{download_zip_button}

und ersetzt die Zeile mit:

{lightbox_button}&nbsp;&nbsp;{postcard_button}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{download_button}&nbsp;&nbsp;{download_zip_button}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{show_audio}


5.)sucht in lang/yourLanguage/main.php

//--- Image Details -----------------------------------

und fügt danach ein:

//################################## Music for your Pictures ######################################
$lang['image_audio'] = "Audio Datei:<br /><span class=\"smalltext\">ID number of audio file</span>";
//################################## Music for your Pictures ######################################


6.)sucht in der detail.php:

$cat_id 
= (isset($image_row['cat_id'])) ? $image_row['cat_id'] : 0;

und fügt davor ein:

//############################### Music for your Pictures ###############################################
$image_audio = ($image_row['image_audio']); 
if(
$image_audio >= 1){
	
$sql "SELECT image_id, cat_id, image_name, image_active, image_media_file, image_thumb_file, image_audio
                           FROM "
.IMAGES_TABLE."
	
           WHERE image_id = '
$image_audio' ";
	
$row $site_db->query_firstrow($sql);
	
show_image($row);
	
$show_audio $site_template->parse_template("audio_bit");
	
$site_template->register_vars("show_audio"$show_audio);
}
//############################### Music for your Pictures ###############################################


7.)sucht in includes/db_definitions.php:

?>

und fügt davor ein:

//################################ Music for your Pictures ############################################   
$additional_image_fields['image_audio'] = array($lang['image_audio'], "int"0);
//################################ Music for your Pictures ############################################   


8.)sucht in admin/images.php:

echo "<td class=\"tableseparator\">".$lang['field_image_name']."</td>\n<td class=\"tableseparator\">".$lang['field_category']."</td>\n<td class=\"tableseparator\">".$lang['field_username']."</td>\n<td class=\"tableseparator\">".$lang['field_date']."</td>\n<td class=\"tableseparator\">".$lang['options']."</td>\n</tr>\n";

und ersetzt es mit:

//################################ Music for your Pictures ###############################################   
//
	
echo "<td class=\"tableseparator\">".$lang['field_image_name']."</td>\n<td class=\"tableseparator\">".$lang['field_category']."</td>\n<td class=\"tableseparator\">".$lang['field_username']."</td>\n<td class=\"tableseparator\">".$lang['field_date']."</td>\n<td class=\"tableseparator\">".$lang['options']."</td>\n</tr>\n";
	
	
echo 
"<td class=\"tableseparator\">ID</td>\n<td class=\"tableseparator\">".$lang['field_image_name']."</td>\n<td class=\"tableseparator\">".$lang['field_category']."</td>\n<td class=\"tableseparator\">".$lang['field_username']."</td>\n<td class=\"tableseparator\">".$lang['field_date']."</td>\n<td class=\"tableseparator\">".$lang['options']."</td>\n</tr>\n";
//################################ Music for your Pictures ################################################

sucht in admin/images.php:

echo "<td><input type=\"checkbox\" name=\"deleteimages[]\" value=\"".$image_row['image_id']."\" /></td>";

und fügt danach ein:

//################################ Music for your Pictures ################################################   
echo "<td>".$image_row['image_id']."</td>";
//################################ Music for your Pictures ################################################


in ACP unter Bild bearbeiten/bearbeiten findet ihr jetzt eine neue Zeile "Audio Datei:"  dort tragt ihr die ID nummer der mp3 Datei ein, die zu dem Bild abgespielt werden soll.

so das war es, ich hoffe ich habe nicht vergessen. :)

mfg Andi

« Last Edit: September 20, 2009, 08:29:31 AM by Rembrandt »

Offline Kurman

  • Newbie
  • *
  • Posts: 42
    • View Profile
    • www.kurman.ru
Re: [MOD]Music for your Pictures
« Reply #1 on: July 28, 2009, 04:32:05 AM »
Sehr gut! Very nice!

Extending features of 4images!  :)
4images running as a music portal http://music.kurman.ru/

Offline hlalink

  • Pre-Newbie
  • Posts: 8
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #2 on: July 29, 2009, 01:02:32 AM »
hello
can you attach the file please

and where can i bot the mp3 and who can i get the id

thank you
« Last Edit: July 29, 2009, 04:00:15 AM by hlalink »

Rembrandt

  • Guest
Re: [MOD]Music for your Pictures
« Reply #3 on: July 31, 2009, 02:14:31 PM »
hi!
... and who can i get the id...

in ACP/ edit images /edit images search


Offline hlalink

  • Pre-Newbie
  • Posts: 8
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #4 on: July 31, 2009, 03:21:40 PM »
Thank's

This is good Can I get the  different music for the  images  i get  only one i have make a change in the code for the tone 

<object type="application/x-shockwave-flash" data="{template_url}/emff_silk.swf" width="88" height="40"/>
 <param name="movie" value="{template_url}/emff_silk.swf"/>
 <param name="bgcolor" value="#ffffff"/>
 <param name="FlashVars" value="data\media\1/MHO-0003.mp3"/>
 </object>


so i get only one tone  for all the images so  what i have  to do to get different tones

thank's
« Last Edit: August 01, 2009, 05:29:29 AM by hlalink »

Offline mawenzi

  • Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #5 on: August 20, 2009, 04:48:27 PM »
... toll Andi, die Idee mit dem variablen Verknüpfen der einzelnen Im-/Au-Dateien gefällt mir gut ...
... verschoben nach "Mods & Plugins (Releases & Support)" ...
Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

Offline Sunny C.

  • Addicted member
  • ******
  • Posts: 1.805
  • I ♥ 4I
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #6 on: August 20, 2009, 08:27:25 PM »
Irgendwie eine richtig geile Idee!
Hab das mal aufgenommen: http://www.4homepages.de/forum/index.php?topic=24888.0

Offline mxnn

  • Pre-Newbie
  • Posts: 7
  • Chileno
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #7 on: June 12, 2013, 05:11:40 PM »
where can I put the mp3 file? because I installed the mod but the music wasn't listening...

Offline nobby

  • 4images Guru
  • *******
  • Posts: 2.873
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #8 on: June 12, 2013, 05:31:24 PM »
where can I put the mp3 file? because I installed the mod but the music wasn't listening...

Hi,

Then you have a mistake somewhere in there ...

nobby

Rembrandt

  • Guest
Re: [MOD]Music for your Pictures
« Reply #9 on: June 12, 2013, 05:45:58 PM »
Hi!
@nooby ich habe jetzt auch erst drei mal nachschauen müßen wie der Mod funktioniert. :)

@mxnn
Upload a mp3 file and notice the ID number from the mp3 file.
Go to a Image and  "Edit image" and put the ID number from the mp3 file in the new image- field: "Audio Datei:"

mfg Andi

Offline mxnn

  • Pre-Newbie
  • Posts: 7
  • Chileno
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #10 on: June 13, 2013, 07:25:27 PM »
thanks rembrandt

Offline Papabaer6

  • Pre-Newbie
  • Posts: 4
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #11 on: October 24, 2013, 08:09:03 PM »
Hi!
@nooby ich habe jetzt auch erst drei mal nachschauen müßen wie der Mod funktioniert. :)

@mxnn
Upload a mp3 file and notice the ID number from the mp3 file.
Go to a Image and  "Edit image" and put the ID number from the mp3 file in the new image- field: "Audio Datei:"

mfg Andi

Also angezeit bekomm ich alles , aber sagt mir auch jemand in welches verzeichnis die musikdatei muss ?

LG

 Papabaer6

Offline nobby

  • 4images Guru
  • *******
  • Posts: 2.873
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #12 on: October 24, 2013, 09:34:45 PM »
Hallo,

ich denke mal ins MEDIA Verzeichnis.

nobby

Offline Papabaer6

  • Pre-Newbie
  • Posts: 4
    • View Profile
Re: [MOD]Music for your Pictures
« Reply #13 on: October 24, 2013, 11:07:43 PM »
Hallo,

ich denke mal ins MEDIA Verzeichnis.

nobby

nein leider nicht egal wo ich es hinpacke es klappt leider nicht


Rembrandt

  • Guest
Re: [MOD]Music for your Pictures
« Reply #14 on: October 25, 2013, 05:37:06 AM »
Willkommen im Forum!
.....
Also angezeit bekomm ich alles , aber sagt mir auch jemand in welches verzeichnis die musikdatei muss ?
.....

Die Musikdateien ladest du genauso wie die Bilder in irgend eine Kategorie hoch.
Die ID der Musikdatei siehst du entweder wenn du mit der Maus über das MP3 Bild der entsprechenden Musikdatei fährst in der Browser Statuszeile, oder unter  "ACP/ Bilder Verwalten / Bilder Bearbeiten".
Diese ID trägst du bei dem Bild ein.

mfg Andi