Nenesse

Detail_Film.php Nenesse 1.0

Sep 29th, 2015
183
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 40.60 KB | None | 0 0
  1.  
  2. <script src="http://code.jquery.com/jquery-1.7.2.min.js"></script>
  3. <script>
  4. $(document).ready(function() {
  5.     $("#content").find("[id^='tab']").hide(); // Hide all content
  6.     $("#tabs li:first").attr("id","current"); // Activate the first tab
  7.     $("#content #tab1").fadeIn(); // Show first tab's content
  8.    
  9.     $('#tabs a').click(function(e) {
  10.         e.preventDefault();
  11.         if ($(this).closest("li").attr("id") == "current"){ //detection for current tab
  12.          return;      
  13.         }
  14.         else{            
  15.           $("#content").find("[id^='tab']").hide(); // Hide all content
  16.           $("#tabs li").attr("id",""); //Reset id's
  17.           $(this).parent().attr("id","current"); // Activate this
  18.           $('#' + $(this).attr('name')).fadeIn(); // Show content for the current tab
  19.         }
  20.     });
  21. });
  22. $(function () {
  23.   $('[data-toggle="popover"]').popover()
  24. })
  25. </script>
  26. <head>
  27.       <meta charset="utf-8" />
  28.     <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  29.     <title>Free Bootstrap Admin Template : Binary Admin</title>
  30.     <!-- BOOTSTRAP STYLES-->
  31.     <link href="assets/css/bootstrap.css" rel="stylesheet" />
  32.      <!-- FONTAWESOME STYLES-->
  33.     <link href="assets/css/font-awesome.css" rel="stylesheet" />
  34.         <!-- CUSTOM STYLES-->
  35.     <link href="assets/css/custom.css" rel="stylesheet" />
  36.      <!-- GOOGLE FONTS-->
  37.    <link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css' />
  38. </head>
  39. <?php
  40.  
  41.     function remplacer_support($support)
  42.     {
  43.         $support = str_replace(
  44.             array(
  45.                 'Dvix',
  46.                 'Blu-Ray 720p',
  47.                 'Blu-Ray 1080p',
  48.                 'DVD',
  49.                 'Mkv 720p',
  50.                 'Mkv 1080p',
  51.  
  52.             ),
  53.             array(
  54.                 '<img width="140px"  src="img/dvix1.png" alt="Dvix" title=" Support Dvix ">',
  55.                 '<img width="160px"  src="img/Blu-Ray2.png" alt="Blu-Ray 720p" title=" Support Blu-Ray Hd 720p ">',
  56.                 '<img width="160px"  src="img/Blu-Ray3.png" alt="Blu-Ray 1080p" title=" Support Blu-Ray Hd 1080p ">',
  57.                 '<img width="130px"  src="img/DVD.png" alt="DVD" title=" Support DVD ">',
  58.                 '<img width="160px"  src="img/mkv720p.png" alt="Mkv 720p" title=" Support Mkv 720p ">',
  59.                 '<img width="160px"  src="img/mkv1080p.png" alt="Mkv 1080p" title=" Support Mkv 1080p ">'
  60.  
  61.             ),
  62.             $support
  63.         );
  64.         return $support;
  65.     }  
  66.  
  67.     function remplacer_image($image)
  68.     {
  69.         $image = str_replace(
  70.             array(
  71.                 'Anglais',
  72.                 ',',
  73.                 'Français',
  74.                 'Néerlandais',
  75.                 'Espagnol',
  76.                 'Portugais',
  77.                 'Allemand',
  78.                 'Roumain',
  79.                 'Bulgare',
  80.                 'Grec',
  81.                 'Suédois',
  82.                 'Islandais',
  83.                 'Norvégien',
  84.                 'Danois',
  85.                 'Finlandais',
  86.                 'Polonais',
  87.                 'Tchèque',
  88.                 'Turc',
  89.                 'Hongrois',
  90.                 'Italien',
  91.                 'Castillan',
  92.                 'Chinois',
  93.                 'Thaïlandais',
  94.                 'Cantonais',
  95.                 'Coréen',
  96.                 'Indonésien',
  97.                 'Mandarin',
  98.                 'Arabe',
  99.                 'Chtimi'
  100.             ),
  101.             array(
  102.                 '<img width="45px"  src="img/Drapeaux/Anglais.gif" title=" Langue Anglaise ">',
  103.                 '&nbsp;&nbsp;',
  104.                 '<img width="45px"  src="img/Drapeaux/Français.gif" title=" Langue Francaise ">',
  105.                 '<img width="45px"  src="img/Drapeaux/Néerlandais.gif" title=" Langue Néerlandaise ">',
  106.                 '<img width="45px"  src="img/Drapeaux/Espagnol.gif" title=" Langue Espagnol ">',
  107.                 '<img width="45px"  src="img/Drapeaux/Portugais.gif" title=" Langue Portugaise ">',
  108.                 '<img width="45px"  src="img/Drapeaux/Allemand.gif" title=" Langue Allemande ">',
  109.                 '<img width="45px"  src="img/Drapeaux/Roumain.gif" title=" Langue Roumaine ">',
  110.                 '<img width="45px"  src="img/Drapeaux/Bulgare.gif" title=" Langue Bulgare ">',
  111.                 '<img width="45px"  src="img/Drapeaux/Grec.gif" title=" Langue Grec ">',
  112.                 '<img width="45px"  src="img/Drapeaux/Suédois.gif" title=" Langue Suédoise ">',
  113.                 '<img width="45px"  src="img/Drapeaux/Islandais.gif" title=" Langue Islandaise">',
  114.                 '<img width="45px"  src="img/Drapeaux/Norvégien.gif" title=" Langue Norvégienne ">',
  115.                 '<img width="45px"  src="img/Drapeaux/Danois.gif" title=" Langue Danoise ">',
  116.                 '<img width="45px"  src="img/Drapeaux/Finlandais.gif" title=" Langue Finlandaise ">',
  117.                 '<img width="45px"  src="img/Drapeaux/Polonais.gif" title=" Langue Polonaise ">',
  118.                 '<img width="45px"  src="img/Drapeaux/Tchèque.gif" title=" Langue Tchèque ">',
  119.                 '<img width="45px"  src="img/Drapeaux/Turc.gif" title=" Langue Turc ">',
  120.                 '<img width="45px"  src="img/Drapeaux/Hongrois.gif" title=" Langue Hongroise">',
  121.                 '<img width="45px"  src="img/Drapeaux/Italien.gif" title=" Langue Italienne ">',
  122.                 '<img width="45px"  src="img/Drapeaux/Castillan.gif" title=" Langue Castillanne ">',
  123.                 '<img width="45px"  src="img/Drapeaux/Chinois.gif" title=" Langue Chinoise ">',
  124.                 '<img width="45px"  src="img/Drapeaux/Thaïlandais.gif" title=" Langue Thaïlandaise ">',
  125.                 '<img width="45px"  src="img/Drapeaux/Cantonais.gif" title=" Langue Cantonaise ">',
  126.                 '<img width="45px"  src="img/Drapeaux/Coréen.gif" title=" Langue Coréenne ">',
  127.                 '<img width="45px"  src="img/Drapeaux/Indonésien.gif" title=" Langue Indonésienne ">',
  128.                 '<img width="45px"  src="img/Drapeaux/Chinois.gif" title=" Langue Mandarin ">',
  129.                 '<img width="45px"  src="img/Drapeaux/Arabe.gif" title=" Langue Arabe ">',
  130.                 '<img width="45px"  src="img/Drapeaux/chtimi.png" title=" Langue Chtimi ">',
  131.  
  132.             ),
  133.             $image
  134.         );
  135.         return $image;
  136.     }
  137.  
  138.    
  139.     function remplacer_image_soustitres($image_soustitres)
  140.     {
  141.         $image_soustitres = str_replace(
  142.             array(
  143.                 'Anglais',
  144.                 ',',
  145.                 'Français',
  146.                 'Néerlandais',
  147.                 'Espagnol',
  148.                 'Portugais',
  149.                 'Allemand',
  150.                 'Roumain',
  151.                 'Bulgare',
  152.                 'Grec',
  153.                 'Suédois',
  154.                 'Islandais',
  155.                 'Norvégien',
  156.                 'Danois',
  157.                 'Finlandais',
  158.                 'Polonais',
  159.                 'Tchèque',
  160.                 'Turc',
  161.                 'Hongrois',
  162.                 'Italien',
  163.                 'Castillan',
  164.                 'Chinois',
  165.                 'Thaïlandais',
  166.                 'Cantonais',
  167.                 'Coréen',
  168.                 'Indonésien',
  169.                 'Mandarin',
  170.                 'Arabe',
  171.                 'Chtimi'
  172.             ),
  173.             array(
  174.                 '<img width="45px"  src="img/Drapeaux/Anglais.gif" title=" Langue Anglaise ">',
  175.                 '&nbsp;&nbsp;',
  176.                 '<img width="45px"  src="img/Drapeaux/Français.gif" title=" Langue Francaise ">',
  177.                 '<img width="45px"  src="img/Drapeaux/Néerlandais.gif" title=" Langue Néerlandaise ">',
  178.                 '<img width="45px"  src="img/Drapeaux/Espagnol.gif" title=" Langue Espagnol ">',
  179.                 '<img width="45px"  src="img/Drapeaux/Portugais.gif" title=" Langue Portugaise ">',
  180.                 '<img width="45px"  src="img/Drapeaux/Allemand.gif" title=" Langue Allemande ">',
  181.                 '<img width="45px"  src="img/Drapeaux/Roumain.gif" title=" Langue Roumaine ">',
  182.                 '<img width="45px"  src="img/Drapeaux/Bulgare.gif" title=" Langue Bulgare ">',
  183.                 '<img width="45px"  src="img/Drapeaux/Grec.gif" title=" Langue Grec ">',
  184.                 '<img width="45px"  src="img/Drapeaux/Suédois.gif" title=" Langue Suédoise ">',
  185.                 '<img width="45px"  src="img/Drapeaux/Islandais.gif" title=" Langue Islandaise">',
  186.                 '<img width="45px"  src="img/Drapeaux/Norvégien.gif" title=" Langue Norvégienne ">',
  187.                 '<img width="45px"  src="img/Drapeaux/Danois.gif" title=" Langue Danoise ">',
  188.                 '<img width="45px"  src="img/Drapeaux/Finlandais.gif" title=" Langue Finlandaise ">',
  189.                 '<img width="45px"  src="img/Drapeaux/Polonais.gif" title=" Langue Polonaise ">',
  190.                 '<img width="45px"  src="img/Drapeaux/Tchèque.gif" title=" Langue Tchèque ">',
  191.                 '<img width="45px"  src="img/Drapeaux/Turc.gif" title=" Langue Turc ">',
  192.                 '<img width="45px"  src="img/Drapeaux/Hongrois.gif" title=" Langue Hongroise">',
  193.                 '<img width="45px"  src="img/Drapeaux/Italien.gif" title=" Langue Italienne ">',
  194.                 '<img width="45px"  src="img/Drapeaux/Castillan.gif" title=" Langue Castillanne ">',
  195.                 '<img width="45px"  src="img/Drapeaux/Chinois.gif" title=" Langue Chinoise ">',
  196.                 '<img width="45px"  src="img/Drapeaux/Thaïlandais.gif" title=" Langue Thaïlandaise ">',
  197.                 '<img width="45px"  src="img/Drapeaux/Cantonais.gif" title=" Langue Cantonaise ">',
  198.                 '<img width="45px"  src="img/Drapeaux/Coréen.gif" title=" Langue Coréenne ">',
  199.                 '<img width="45px"  src="img/Drapeaux/Indonésien.gif" title=" Langue Indonésienne ">',
  200.                 '<img width="45px"  src="img/Drapeaux/Chinois.gif" title=" Langue Mandarin ">',
  201.                 '<img width="45px"  src="img/Drapeaux/Arabe.gif" title=" Langue Arabe ">',
  202.                 '<img width="45px"  src="img/Drapeaux/chtimi.png" title=" Langue Chtimi ">',
  203.             ),
  204.             $image_soustitres
  205.         );
  206.         return $image_soustitres;
  207.     }  
  208.    
  209.    
  210.     function remplacer_audio($image_audio)
  211.     {
  212.         $image_audio = str_replace(
  213.             array(
  214.                 'Dolby Digital 5.1',
  215.                 ',',
  216.                 'DD2.0 mono Français',
  217.                 'DD2.0 Français',
  218.                 'DD5.1 Français',
  219.                 'DD5.1 Anglais',
  220.                 'DDTHD 5.1',
  221.                 'DTS 5.1',
  222.                 'DTSHD-MA 5.1',
  223.                 'DTSHD-MA2.0 Français',
  224.                 'DTSHD-MA5.1 Français',       
  225.                 'DTSHD-MA5.1 Anglais',
  226.                 'DTSHD-MA7.1 Français',
  227.                 'DTSHD-MA7.1 Anglais',
  228.                 'DTSHD-HRA5.1 Français',
  229.                 'DTSHD-HRA7.1 Français'
  230.             ),
  231.             array(
  232.                 '<img width="85px"  src="img/Formats/DD.png" title=" Audio Dolby Digital 5.1">',
  233.                 '&nbsp;&nbsp;&nbsp;',
  234.                 '<img width="85px"  src="img/Formats/DD.png" title=" Audio Dolby Digital Français 2.0 mono">',
  235.                 '<img width="85px"  src="img/Formats/DD.png" title=" Audio Dolby Digital Français 2.0">',
  236.                 '<img width="85px"  src="img/Formats/DD.png" title=" Audio Dolby Digital Français 5.1">',
  237.                 '<img width="85px"  src="img/Formats/DD.png" title=" Audio Dolby Digital Anglais 5.1">',
  238.                 '<img width="85px"  src="img/Formats/DDTHD.png" title=" Audio DDTHD 5.1">',
  239.                 '<img width="85px"  src="img/Formats/DTS.png" title=" DTS 5.1">',
  240.                 '<img width="85px"  src="img/Formats/DTSHD.png" title=" DTSHD-MA 5.1">',
  241.                 '<img width="85px"  src="img/Formats/DTSHD.png" title=" Audio DTSHD Français 2.0">',
  242.                 '<img width="85px"  src="img/Formats/DTSHD.png" title=" Audio DTSHD Français 5.1 ">',
  243.                 '<img width="85px"  src="img/Formats/DTSHD.png" title=" Audio DTSHD Anglais 5.1 ">',
  244.                 '<img width="85px"  src="img/Formats/DTSHD 7.png" title=" Audio DTSHD Français 7.1">',
  245.                 '<img width="85px"  src="img/Formats/DTSHD 7.png" title=" Audio DTSHD Anglais 7.1">',
  246.                 '<img width="85px"  src="img/Formats/DTSHD HRA.png" title=" Audio DTSHD-HRA  Français 5.1">',
  247.                 '<img width="85px"  src="img/Formats/DTSHD HRA.png" title=" Audio DTSHD-HRA  Français 7.1">'
  248.             ),
  249.             $image_audio
  250.         );
  251.         return $image_audio;
  252.     }
  253.    
  254.    
  255.  
  256.    
  257.     // CONFIGURATION
  258.     $cfg = new CONFIG();
  259.  
  260.     // DATABASE
  261.     try
  262.     {
  263.         if ( $cfg->DB_TYPE == 'sqlite' ) {
  264.             $db = new PDO('sqlite:'.$cfg->DB_NAME.'.sqlite3');
  265.         } else {
  266.             $db = new PDO('mysql:host='.$cfg->DB_SERVER.';dbname='.$cfg->DB_NAME, $cfg->DB_USER, $cfg->DB_PASSWORD);
  267.             $db->query("SET NAMES UTF8");
  268.         }
  269.     }
  270.     catch (Exception $e)
  271.     {
  272.         die('Erreur : ' . $e->getMessage());
  273.     }
  274.    
  275.     if ($_POST['addactor2'] == "ok")
  276.     {
  277.         function gw2_api_request($request)
  278.         {
  279.             $api_url = "http://api.themoviedb.org";
  280.             $api_version = "3";
  281.             $api_key = '79f65cf6667f54e297a68a4ef6bc862e';
  282.            
  283.             $url = parse_url($api_url . '/' . $api_version . '/person/' . $request . '?api_key=' . $api_key);
  284.             if(!$fp = @fsockopen('ssl://' . $url['host'], 443, $errno, $errstr, 5)){
  285.                 return 'connection error: ' . $errno . ', ' . $errstr;
  286.             }
  287.  
  288.             $nl = "\r\n";
  289.             $header = 'GET ' . $url['path'] . '?' . $url['query'] . ' HTTP/1.1' . $nl . 'Host: ' . $url['host'] . $nl . 'Connection: Close' . $nl . $nl;
  290.             fwrite($fp, $header);
  291.             stream_set_timeout($fp, 5);
  292.  
  293.             $response = '';
  294.             do
  295.             {
  296.                 if(strlen($in = fread($fp,1024))==0)
  297.                 {
  298.                     break;
  299.                 }
  300.                 $response .= $in;
  301.             }
  302.             while(true);
  303.  
  304.             $response = explode($nl,$response);
  305.  
  306.             if(isset($response[0]) && $response[0] == 'HTTP/1.1 200 OK')
  307.             {
  308.                 $response = json_decode($response[count($response)-1]);
  309.             }
  310.  
  311.             return $response;
  312.         }
  313.         function DateTime($datein)
  314.         {
  315.             $mois = array('janvier', 'février', 'mars', 'avril', 'mai', 'juin', 'juillet', 'aout', 'septembre', 'octobre', 'novembre', 'décembre');
  316.             preg_match('/([0-9]+)-([0-9]+)-([0-9]+)/', $datein, $m);
  317.             $lemois = $mois[$m[2]-1];
  318.             return $m[3] . ' ' . $lemois . ' ' . $m[1];
  319.         }
  320.         $id_acteur              = $_POST['ID_acteur'];
  321.        
  322.         $name                   = gw2_api_request($id_acteur)->name;
  323.         $biography              = gw2_api_request($id_acteur)->biography;
  324.         $birthday               = gw2_api_request($id_acteur)->birthday;
  325.         $place_of_birth         = gw2_api_request($id_acteur)->place_of_birth;
  326.         $deathday               = gw2_api_request($id_acteur)->deathday;
  327.        
  328.         if (!empty($birthday))
  329.         {
  330.             $birthday2 = DateTime($birthday);
  331.         }
  332.         else
  333.         {
  334.             $birthday2 = '';
  335.         }
  336.        
  337.         if (!empty($deathday))
  338.         {
  339.             $deathday2 = DateTime($deathday);
  340.         }
  341.         else
  342.         {
  343.             $deathday2 = '';
  344.         }
  345.        
  346.         $db->query('INSERT INTO ' . $cfg->DB_TABLE . '_acteurs (ID, NomActeur, DateNaissance, LieuNaissance, DateDeces, Biographie) VALUES ("", "' . $name . '", "' . $birthday2 . '", "' . $place_of_birth . '", "' . $deathday2 . '", "' . str_replace( '"', '\"', $biography) . '")');
  347.         refresh('index.php?op=details&id=' . $_GET['id']);
  348.     }
  349.    
  350.     if ($_POST['addactor'] == "ok")
  351.     {
  352.         if (isset($_POST['Password']) && $_POST['Password'] == '60078') /* LE MOT DE PASSE ICI EST DEFINIT PAR MOI, MAIS TU PEUX METTRE CEUX QUE TU VEUX A LA PLACE DE 60078 */
  353.         {
  354.             $NomActeur              = strip_tags($_POST['NomActeur']);
  355.             $DateNaissance          = strip_tags($_POST['DateNaissance']);
  356.             $LieuNaissance          = strip_tags($_POST['LieuNaissance']);
  357.             $DateDeces              = strip_tags($_POST['DateDeces']);
  358.             $Biographie             = strip_tags($_POST['Biographie']);
  359.            
  360.             $db->query('INSERT INTO ' . $cfg->DB_TABLE . '_acteurs (ID, NomActeur, DateNaissance, LieuNaissance, DateDeces, Biographie) VALUES ("", "' . $NomActeur . '", "' . $DateNaissance . '", "' . $LieuNaissance . '", "' . $DateDeces . '", "' . str_replace( '"', '\"', $Biographie) . '")');
  361.             refresh('index.php?op=details&id=' . $_GET['id']);
  362.         }
  363.         else
  364.         {
  365.             $messageno = 'Mauvais mot de passe';
  366.         }
  367.     }
  368.     else
  369.     {
  370. ?>
  371.  
  372. <?php
  373.  
  374. $cfg->DB_TABLE=$_SESSION['table'];
  375. $_SESSION['table']=$cfg->DB_TABLE;
  376. $cfg->POSTERS_DIRECTORY=$_SESSION['poster'];
  377. $_SESSION['poster']=$cfg->POSTERS_DIRECTORY;
  378. // Select Movie ID
  379. if ((isset($_GET['id']))) $id=$_GET['id']; else $id=-1;
  380. $req = $db->prepare('SELECT * FROM ' . $cfg->DB_TABLE . ' WHERE ID = :id');
  381. $req->execute(array('id' => $id));
  382.  
  383. // Formatting functions
  384. function add_commas( $string,$search_label ) {
  385.     $string = str_replace("\r",", ",$string);
  386.     $unique = explode(", ",$string);
  387.     $result="";
  388.         foreach ($unique as $key => $value) {  
  389.             //formulaire de recherche
  390.             $result.="<a style='color:blue' href='#' onclick=\"javascript:document.forms['$value-$search_label'].submit();\">$value</a>, ";
  391.     }
  392.     return $result;
  393. }
  394. function add_forms( $string,$search_label ) {
  395.     $string = str_replace("\r",", ",$string);
  396.     $unique = explode(", ",$string);
  397.     $result="";
  398.         foreach ($unique as $key => $value) {  
  399.             //formulaire de recherche
  400.             $result.="<form name='$value-$search_label' method='post' action='index.php'>
  401.            <input type='hidden' name='search_query' value='$value'>
  402.            <input type='hidden' name='search_field' value='$search_label'>
  403.            </form>";
  404.     }
  405.     return $result;
  406. }
  407. function add_br( $string ) {
  408.     return str_replace("\r","<br />",str_replace("\n","<br />",$string));
  409. }
  410.  
  411. ?>
  412. <?php
  413. $bandeannonce=0;
  414. while ($data = $req->fetch()) {
  415.  
  416.         ?>
  417.  
  418.     <!-- <div id="fade" class="black_overlay" onclick="document.getElementById('light').style.display='none';document.getElementById('fade').style.display='none';"></div> -->
  419. <?php
  420.  if (isset($_GET['id']))
  421. $id=$_GET['id'];
  422. else $id=-1;
  423. $query_66 = 'SELECT *, (SELECT ID FROM ' . $cfg->DB_TABLE . ' WHERE ID < ' . $id . ' ORDER BY ID DESC LIMIT 1) AS prec, (SELECT ID FROM ' . $cfg->DB_TABLE . ' WHERE ID > ' . $id . ' LIMIT 1) AS suiv FROM ' . $cfg->DB_TABLE . ' WHERE ID=' . $id;
  424. $result_66 = $db->query($query_66) or die(print_r($bdd->errorInfo()));
  425. $result_fetch_66 = $result_66->fetch();
  426. $result_66->closeCursor();
  427. ?>
  428. <?php
  429.  
  430. echo add_forms($data['Realisateurs'],'Realisateurs');
  431. echo add_forms($data['Acteurs'],'Acteurs');
  432. ?>
  433. <div id="wrapper">
  434.     <nav class="navbar navbar-default navbar-cls-top " role="navigation" style="margin-bottom: 0">
  435.         <div class="navbar-header">
  436.             <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".sidebar-collapse">
  437.                 <span class="sr-only">Toggle navigation</span>
  438.                 <span class="icon-bar"></span>
  439.                 <span class="icon-bar"></span>
  440.                 <span class="icon-bar"></span>
  441.             </button>
  442.             <?php echo($config['titre']['baseconf']) ?>
  443.         </div>
  444.         <div style="color: white;padding: 15px 50px 5px 50px;float: right;font-size: 16px;">
  445.  
  446.             <script>
  447.               function date_heure(id)
  448.             {
  449.             date = new Date;
  450.             annee = date.getFullYear();
  451.             moi = date.getMonth();
  452.             mois = new Array('Janvier', 'F&eacute;vrier', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Ao&ucirc;t', 'Septembre', 'Octobre', 'Novembre', 'D&eacute;cembre');
  453.             j = date.getDate();
  454.             jour = date.getDay();
  455.             jours = new Array('Dimanche', 'Lundi', 'Mardi', 'Mercredi', 'Jeudi', 'Vendredi', 'Samedi');
  456.             h = date.getHours();
  457.             if(h<10)
  458.             {
  459.             h = "0"+h;
  460.             }
  461.             m = date.getMinutes();
  462.             if(m<10)
  463.             {
  464.             m = "0"+m;
  465.             }
  466.             s = date.getSeconds();
  467.             if(s<10)
  468.             {
  469.             s = "0"+s;
  470.             }
  471.             resultat = ''+jours[jour]+' '+j+' '+mois[moi]+' '+annee+' : '+h+':'+m+':'+s;
  472.             document.getElementById(id).innerHTML = resultat;
  473.             setTimeout('date_heure("'+id+'");','1000');
  474.             return true;
  475.             }
  476.             </script>
  477.             <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  478.             <script type="text/javascript" src="date_heure.js"></script>
  479.             <span id="date_heure"></span>
  480.        
  481.             <script type="text/javascript">window.onload = date_heure('date_heure');</script>
  482.             &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="?op=logout" class="btn btn-danger square-btn-adjust">Déconnexion</a>
  483.         </div>
  484.     </nav>  
  485.            <!-- /. NAV TOP  -->
  486.             <nav class="navbar-default navbar-side" role="navigation">
  487.             <div class="sidebar-collapse">
  488.                 <ul class="nav" id="main-menu">
  489.                 <li class="text-center">
  490.  
  491.                      <?php  if ($user['permission']=="Administrateur"&&$_GET['id']!="") {       $id=$_GET['id'];    }   else $id=$user['id'];   $nfsql = $db->query("SELECT * from ".$cfg->DB_TABLE."_users WHERE `id`='$id'"); $changeuser = $nfsql->fetch();  $nfsql->closeCursor(); ?>
  492.                     <img style="border: 1px solid #667882; box-shadow: 1px 1px 2px #555" class="user-image img-responsive img-circle" width="145" src="../Avatars/<?php echo $user['username']; ?>.jpg" />
  493.  
  494.  
  495.                
  496.                     </li>
  497.                     <li>
  498.                     <a href="?op=liste"><i class="fa fa-desktop fa-2x"></i> Ecran principal</a>
  499.                     </li>
  500.                     <li>
  501.                         <a class="active-menu" href="javascript:history.go(-1)"><i class="fa fa-fast-backward fa-2x"></i>&nbsp; &nbsp; Page précédente</a>
  502.                     </li>
  503.                 </ul>
  504.              </div>
  505.         </nav>  
  506.         <!-- /. NAV SIDE  -->
  507.         <div id="fade" class="black_overlay" onclick="document.getElementById('light').style.display='none';document.getElementById('fade').style.display='none';"></div>  
  508.         <div id="page-wrapper" >
  509.     <div id="page-inner">
  510.         <?php if ($user['permission']=="Invite") { ?>  
  511.                     <div class="col-md-12 col-sm-12">
  512.                     <h2> Vous n'avez pas accès aux détails du film en tant qu'invité pensez à vous inscrire ! </h2>
  513.                     <h4 > <a href="http://br.nenessentertainment.fr/register.php"> CREER UN COMPTE UTILISATEUR PAR ICI </a></h4>
  514.                     </div>
  515.                     <?php }
  516.                     else { ?>
  517.                    <!-- /. ROW  -->
  518.             <div class="row">
  519.                 <div class="col-md-6 col-sm-6">
  520.            
  521.            
  522.                     <style>
  523.                         essais{
  524.                         border: 2px solid red;
  525.                         -webkit-box-shadow: 0px 4px 14px 10px rgba(133,70,133,1);
  526.                         -moz-box-shadow: 0px 4px 14px 10px rgba(133,70,133,1);
  527.                         box-shadow: 0px 4px 14px 10px rgba(133,70,133,1);
  528.                             margin-left: auto;
  529.                             margin-right: auto;
  530.                         }
  531.                         h4{
  532.                             color: red;
  533.                         }
  534.  
  535.  
  536.                     </style>
  537.                            
  538.                             <br /><br /><br /><br />
  539.                             <?php
  540.                            
  541.                             $filename = sprintf('%s/Filmotech_%05d.jpg' , $cfg->POSTERS_DIRECTORY , $data['ID'] );
  542.                             if (file_exists($filename))  echo('<center><table width="50%"><tr align="center"><td><img class="essais" max-widht:100% src="' . $filename . '" "></td></tr></table></center>');
  543.                             ?>
  544.                             <br /><br /><br /><br />
  545.                    
  546.                
  547.                 </div>
  548.                 <div class="col-md-6 col-sm-6">
  549.                     <div class="panel panel-info">
  550.                         <div class="panel-heading">
  551.                             <i class="fa fa-video-camera fa-2x"></i>&nbsp;&nbsp; La bande annonce
  552.                         </div>
  553.                         <div class="panel-body">
  554.                             <center>
  555.                             <div style="height:360px;" >       
  556.                                                    
  557.                             <?php       // Bandes Annonce
  558.                             if (($data['BAChemin'] <> "") && ($data['BAType'] = "URL")) {
  559.                                 $taille_ba="width=\"100%\" height=\"100%\"";
  560.                                 //echo substr($data['BAChemin'],11,7);
  561.                                
  562.                                 // allociné
  563.                                                 if (substr($data['BAChemin'],11,8)=="allocine") {
  564.                                                 $id_ba_temp=explode("=", $data['BAChemin']); $id_ba=explode("&", $id_ba_temp['1']);
  565.                                                 echo '<object '.$taille_ba.'><param name="movie" value="http://www.allocine.fr/blogvision/'.$id_ba['0'].'
  566.                                                 "></param><param name=allowFullScreen value=true></param><param name=allowScriptAccess value=always></param>
  567.                                                 <embed src="http://www.allocine.fr/blogvision/'.$id_ba['0'].'"
  568.                                                 type="application/x-shockwave-flash" allowFullScreen="true" allowScriptAccess="always" '.$taille_ba.'></embed></object>';
  569.                                                 $bandeannonce=1;
  570.                                                 }
  571.  
  572.                                 // youtube
  573.                                                 if(substr($data['BAChemin'],11,7)=="youtube") {
  574.                                                 $id_ba_temp=explode("v=", $data['BAChemin']); $id_ba=explode("&", $id_ba_temp['1']);
  575.                                                 echo '<object '.$taille_ba.'><param name="movie" value="http://www.youtube.com/v/'.$id_ba[0].'?fs=1&amp;hl=fr_FR"
  576.                                                 ></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param>
  577.                                                 <embed src="http://www.youtube.com/v/'.$id_ba[0].'?fs=1&amp;hl=fr_FR" type="application/x-shockwave-flash" allowscriptaccess=
  578.                                                 "always" allowfullscreen="true" '.$taille_ba.'></embed></object>';
  579.                                                 $bandeannonce=1;
  580.                                 }              
  581.                                 // dailymotion
  582.                                                 if(substr($data['BAChemin'],11,11)=="dailymotion") {
  583.                                                 $id_ba_temp=explode("video/", $data['BAChemin']); $id_ba=explode("_", $id_ba_temp['1']);
  584.                                                 echo '<object '.$taille_ba.'><param name="movie" value="http://www.dailymotion.com/swf/video/'.$id_ba[0].
  585.                                                 '?additionalInfos=0"></param><param name="allowFullScreen" value="true"></param><param name="allowScriptAccess" value="always"></param>
  586.                                                 <embed src="http://www.dailymotion.com/swf/video/'.$id_ba[0].'?additionalInfos=0" type="application/x-shockwave-flash" '.$taille_ba.
  587.                                                 ' allowfullscreen="true" allowscriptaccess="always"></embed></object>';
  588.                                                 $bandeannonce=1;
  589.                                                 }
  590.                                 // cinemovie
  591.                                                 if(substr($data['BAChemin'],11,10)=="cinemovies") {
  592.                                                 $id_ba=explode("-", $data['BAChemin']);
  593.                                                 echo '<object '.$taille_ba.'><param value="http://www.cinemovies.fr/player/cinemovies-playerexport.swf?IDBA=ba_'.$id_ba[3].'" name="movie"/>
  594.                                                 <embed src="http://www.cinemovies.fr/player/cinemovies-playerexport.swf?IDBA=ba_'.$id_ba[3].'" type="application/x-shockwave-flash" '.
  595.                                                 $taille_ba.'></embed></object>';
  596.                                                 $bandeannonce=1;
  597.                                                 }
  598.                              
  599.                                
  600.  
  601.                             }
  602.                                   ?>
  603.                              
  604.                             <?php if (substr($data['BAChemin'],11,8)=="allocine") {
  605.                                            
  606.                                     }
  607.                                    
  608.                                     else {
  609.  
  610.                                    
  611.                                    
  612.                                 ?>  <img style="max-width: 30px;" class="img-monitor" src="img/bobine.png"> <?php } ?>
  613.                             </div> 
  614.                            
  615.                                     <br />
  616.                             </center>  
  617.                         </div>
  618.                     </div>
  619.                 </div>
  620.             </div>
  621.             <div class="row">
  622.                 <div class="col-md-12 col-sm-12">
  623.                     <div class="panel panel-info">
  624.                         <div class="panel-heading">
  625.                             <i class="fa fa-comment-o fa-2x"></i> Information
  626.                         </div>
  627.                         <div class="panel-body">
  628.                             <ul class="nav nav-tabs">
  629.                                 <li class="active"><a href="#home" data-toggle="tab"><label style="color:black">Acteur(s) et réalisateur(s)</label></a>
  630.                                 </li>
  631.                                 <li class=""><a href="#profile" data-toggle="tab"><label style="color:black">Détails et support</label></a>
  632.                                 </li>
  633.                                 <li class=""><a href="#messages" data-toggle="tab"><label style="color:black">Synopsis</label></a>
  634.                                 </li>
  635.                                 <li class=""><a href="#musique" data-toggle="tab"><label style="color:black">Musique du film</label></a>
  636.                                 </li>
  637.                             </ul>
  638.  
  639.                             <div class="tab-content">
  640.                                 <div class="tab-pane fade active in" id="home">
  641.                                     <br />
  642.                                     <h4>Acteur(s) et réalisateur(s)</h4>
  643.                            
  644.                                                              <?php
  645.                             echo add_forms($data['Realisateurs'],'Realisateurs');
  646.                             echo add_forms($data['Acteurs'],'Acteurs' );
  647.                            
  648.                            
  649.                         ?>
  650.                             <?php echo( '<h4>' . $media_informations2 . '</h4>' ); ?>
  651.                             <p><span class="nftext-info"><span style="color:black"><?php echo($field_labels['Realisateurs']); ?> : </span> </span>
  652.                             <span style="color:#000000" class="muted"><?php echo add_commas($data['Realisateurs'],'Realisateurs'); ?></span></p>
  653.                             <p style="color:black"><span class="nftext-info"><span style="color:black"><?php echo($field_labels['Acteurs']); ?> : </span> </span>
  654.                             <span style="color:#000000"><?php echo add_commas($data['Acteurs'],'Acteurs'); ?></span>
  655.                             <br /><br />
  656.                             <?php
  657.                            
  658.                                 $acteurs = str_replace("\r", '|', $data['Acteurs'], $count); //on remplace les sauts de ligne par |
  659.                                 $liste_acteurs = explode("|", $acteurs); //on récupère les données de chaque ligne
  660.                                
  661.                                 for($i=0;$i<count($liste_acteurs);$i++) // on fait une boucle
  662.                                 {
  663.                             ?>
  664.  
  665.                         <div id="larg" class="col-md-2 col-sm-2">
  666.                                 <div class="actor">
  667.                                     <table align="center">
  668.                                         <tr>
  669.                                             <td class="bulcol">
  670.                                                 <a class="Bulle">
  671.                                                     <?php $filename = sprintf('acteurs/' . $liste_acteurs[$i] . '.jpg'); ?>
  672.                                                     <?php if (file_exists($filename)) { ?>
  673.                                                         <img src="<?php echo $filename; ?>" class="actor-img" width="144px" height="200px" alt="Acteur" />
  674.                                                        
  675.                                                     <?php } else { ?>
  676.                                                         <img src="acteurs/image_non_disponible.png" class="actor-img" width="144px" height="200px" alt="Acteur" />
  677.                                                     <?php } ?>
  678.  
  679.                                                            
  680.                                                     <span class="cote" style="border:solid 2px red; border-radius: 8px";>
  681.                                                         <table>
  682.                                                             <tr>
  683.  
  684.                                                                 <td style="vertical-align:top">
  685.                                                                     <?php
  686.                                                                         $query_actor = 'SELECT * FROM ' . $cfg->DB_TABLE . '_acteurs WHERE NomActeur = "' . $liste_acteurs[$i] . '"';
  687.                                                                         $result_actor = $db->query($query_actor);
  688.                                                                        
  689.                                                                         while ($donnees_actor = $result_actor->fetch())
  690.                                                                         {
  691.                                                                     ?>
  692.                                                                         <div align="center"></div>
  693.        
  694.                                                                 </td>
  695.                                                                             <br />
  696.                                                                                                                                            
  697.                                                                                 <i style="color:black">Prénom & Nom : </i>
  698.                                                                                 <br />
  699.                                                                                 <i style="color:blue"><?php echo $liste_acteurs[$i]; ?></i>
  700.                                                                    
  701.                                                                             <br /><br />
  702.                                                                            
  703.                                                                                 <i style="color:black">Lieu de Naissance : </i>
  704.                                                                                 <br />
  705.                                                                                 <i style="color:blue"><?php echo $donnees_actor['LieuNaissance']; ?></i>
  706.                                                                            
  707.                                                                        
  708.                                                                             <br /><br />
  709.                                                                                 <!----- AGE ----->
  710.                                                                                
  711.                                                                                     <?php
  712.                                                                                         // tableau des mois
  713.                                                                                         $moischiffre = array('janvier'=>'01', 'février'=>'02', 'mars'=>'03', 'avril'=>'04', 'mai'=>'05', 'juin'=>'06', 'juillet'=>'07', 'août'=>'08', 'septembre'=>'09', 'octobre'=>'10', 'novembre'=>'11', 'décembre'=>'12');
  714.                                                                                         // date de naissance
  715.                                                                                         $naissance = $donnees_actor['DateNaissance'];
  716.                                                                                         $naissance2 = explode(' ', $naissance);
  717.                                                                                         ?> <!-- $naissance3 = mktime(0, 0, 0, $moischiffre[$naissance2[1]], $naissance2[0], $naissance2[2]);--> <?php
  718.                                                                                         $naissance3 =  mktime(0, 0, 0, $moischiffre[$naissance2[1]], $naissance2[0], $naissance2[2]);
  719.                                                                                         // Date de décès ou date d'aujourd'hui
  720.                                                                                         if ($donnees_actor['DateDeces'] != '')
  721.                                                                                         {
  722.                                                                                             $deces = $donnees_actor['DateDeces'];
  723.                                                                                             $deces2 = explode(' ', $deces);
  724.                                                                                             $deces3 = mktime(0, 0, 0, $moischiffre[$deces2[1]], $deces2[0], $deces2[2]);
  725.                                                                                             $aujourdhui = $deces3;
  726.                                                                                         } else {
  727.                                                                                             $aujourdhui = time();
  728.                                                                                         }
  729.                                                                                         // soustraction => nombre de secondes de la différence
  730.                                                                                         $ecart = $aujourdhui - $naissance3;
  731.                                                                                         // on repasse en nombre de jours
  732.                                                                                         $ecart = floor($ecart / 3600 / 24);
  733.                                                                                         // on repasse en années
  734.                                                                                         $ecart = floor($ecart / 365);
  735.                                                                                         // affichage de l'age
  736.                                                                                        
  737.                                                                                     ?>
  738.                                                                                 </td>
  739.  
  740.                                                                                 <i style="color:black">Date de Naissance :</i>
  741.                                                                                 <br />
  742.                                                                                 <i style="color:blue"><?php echo $donnees_actor['DateNaissance']; ?> </i>
  743.                                                                                    
  744.                                                                                 <!----- FIN AGE ----->
  745.                                                                                 <br /><br />
  746.                                                                        
  747.                                                                                 <i style="color:black">Date de décès : </i>
  748.                                                                                 <br />
  749.                                                                                 <i style="color:blue"><?php echo $donnees_actor['DateDeces']; ?></i>
  750.                                                                                 <br /><br />
  751.                                                                            
  752.                                                                                 <i style="color:black">Age actuel ~~ décès : </i>
  753.                                                                                 <br />
  754.                                                                                 <i style="color:blue"><?php echo $ecart . ' ans'; ?></i>
  755.                                                                                 <br /><br />
  756.                                                                     <?php
  757.                                                                         }
  758.                                                                     ?>
  759.                                                                                                                        
  760.                                                                 </td>
  761.                                                             </tr>
  762.                                                         </table>
  763.                                                     </span>
  764.                                                 </a>
  765.                                             </td>  
  766.                                         </tr>
  767.                                     </table>
  768.                                     <h4>
  769.                                         <div class="text-actor text-center">
  770.                                             <?php echo $liste_acteurs[$i]; ?>
  771.                                                                                 <!--                <p style="color:black">Lieu de Naissance : </p>
  772.                                                                                 <br />
  773.                                                                                 <p style="color:blue"><?php echo $donnees_actor['LieuNaissance']; ?></p> -->
  774.                                         </div>
  775.  
  776.                                        
  777.                                     </h4>
  778.                                    
  779.                                 </div>
  780.                                        
  781.                             </div> 
  782.                                        
  783.        
  784.                                     <?php } ?> 
  785.                                    
  786.                                    
  787.                             <div class="col-md-12 col-sm-12">      
  788.                             </br>
  789.                             <?php if ($user['permission']=="Administrateur") { ?>
  790.                                 <h4> Encodage acteur <h6> Uniquement visible aux admins</h6></h4>
  791.                                 <form class="form-horizontal" role="form" method="post">
  792.                                     <input type="hidden" name="addactor2" value="ok">
  793.                                     <div class="form-group"><br /><br />
  794.                                         <input style="width:200px" type="text" class="form-control" placeholder="Référence de l'acteur" name="ID_acteur" value="" required>
  795.                                     </div>
  796.                                     <button type="submit" class="btn btn-success"><span class="glyphicon glyphicon-ok"></span> Enregistrer</button><br /><br />
  797.                                     <a href='https://www.themoviedb.org' target="blank"><img src="img/website.png" title="Aller vers le site The movie Db"></a>
  798.                                 </form>
  799.                             <?php } ?>
  800.                             </div>
  801.  
  802.                                 </div>
  803.                                 <div class="tab-pane fade" id="profile">
  804.                                     <br />
  805.                                     <h4>Détails et support</h4>
  806.                                     <div class="col-md-12 col-sm-12">
  807.                                         <?php echo( '<span style="color:#0000FF"><strong>' . $field_labels['TitreVF'] . ' : </strong></span>'); ?>
  808.                                         <h1 style="color:red"><?php echo $data['TitreVF']; ?></h1>
  809.                                     </div> 
  810.                                     <br />
  811.                                     <div class="col-md-4 col-sm-4">
  812.                                    
  813.                                             <?php if ($show_media_infos) {
  814.                                         echo( '<br />' );
  815.                                        
  816.                                         echo( '<span style="color:#0000FF"><strong>' . $field_labels['TitreVO'] . ' : </strong></span>');
  817.                                         echo( '<br />' );echo( '<br />' );
  818.                                         echo('<span style="color:#000000"><strong> '. $data['TitreVO'] . '<br /></strong></span>' ) ;
  819.  
  820.                                         echo( '<br />' );
  821.                                         echo( '<span style="color:#0000FF"><strong>' . $field_labels['Reference'] . ' : </strong></span>');
  822.                                        
  823.                                         echo( '<br />' );echo( '<br />' );
  824.                                         if ( $data['Reference'] == "Hdd")
  825.                                         {  ?> <img width="65px" src="img/hdd.png" data-toggle="tooltip" data-original-title=" Disque dur ">  <?php }
  826.                                         else { echo('<img width="45px"src="img/Boitecd.png"> '. $data['Reference'] . '<br />' ) ;  }
  827.                                                                    
  828.                                         echo( '<br />' );echo( '<br />' );
  829.                                                                    
  830.                                         echo( '<span style="color:#0000FF"><strong>' . $field_labels['Support'] . ' : </strong></span>');
  831.                                         echo( '<br />' );echo( '<br />' );
  832.                                         ?><!-- echo(' '. $data['Support']. '<br />' ) ; --> <?php
  833.                                         $support = $data['Support'];
  834.                                         echo remplacer_support($support);
  835.                                         echo( '<br />' );echo( '<br />' ); }?>
  836.  
  837.                                     </div>
  838.                                     <div class="col-md-5 col-sm-5">
  839.                                         <?php echo( '<br />' );
  840.                                         echo( '<span style="color:#0000FF"><strong>' . $field_labels['Langues'] . ' : </strong></span>');
  841.                                         echo( '<br />' );echo( '<br />' );
  842.                                         ?> <!-- echo(' '. $data['Langues'] . '<br />' ) ;  --> <?php
  843.                                         $essais = $data['Langues'];
  844.                                         echo remplacer_image($essais);
  845.                                         echo( '<br />' );echo( '<br />' );
  846.                                        
  847.                                             echo( '<span style="color:#0000FF"><strong>' . $field_labels['SousTitres'] . ' : </strong></span>');
  848.                                         echo( '<br />' );echo( '<br />' );
  849.                                         ?> <!-- echo(' '. $data['SousTitres'] . '<br />' ) ; --> <?php
  850.                                         $soustitres = $data['SousTitres'];
  851.                                         echo remplacer_image_soustitres($soustitres);
  852.                                         echo( '<br />' );echo( '<br />' );
  853.  
  854.                                
  855.                                         echo( '<br />' );
  856.                                         echo( '<span style="color:#0000FF"><strong>' . $field_labels['Audio'] . ' : </strong></span>');
  857.                                         echo( '<br />' );echo( '<br />' );
  858.                                         ?> <!-- echo(' '. $data['Audio'] . '<br />' ) ; --> <?php
  859.                                         $audio = $data['Audio'];
  860.                                         echo remplacer_audio($audio);
  861.                                         echo( '<br />' );echo( '<br />' );
  862.                    
  863.                                          ?>
  864.  
  865.                                     </div>
  866.                                     <div class="col-md-3 col-sm-3">
  867.                                         <form name='search-date' method='post' action='index.php'>
  868.                                         <input type='hidden' name='search_query_annee' value='<?php echo $data['Annee']; ?>'>
  869.                                         <input type='hidden' name='search_field' value='Annee'>
  870.                                         </form>
  871.                                    
  872.                                             <?php
  873.  
  874.                                                 $uniquegenre = array();
  875.                                                 $uniquegenre = explode(" / ",$data['Genre']);
  876.                                                 foreach ($uniquegenre as $key => $value) {  
  877.                                                     $uniquegenre2 = explode(" - ",$value);
  878.                                                     foreach ($uniquegenre2 as $key => $value) {
  879.                                                         ?>
  880.                                                         <form name='search-genre-<?php echo $value; ?>' method='post' action='index.php'>
  881.                                                         <input type='hidden' name='search_query_genre' value='<?php echo $value; ?>'>
  882.                                                         <input type='hidden' name='search_field' value='Genre'>
  883.                                                         </form>
  884.                                                        
  885.                                                        
  886.                                                         <?php
  887.                                                     }
  888.                                                    
  889.                                                 }
  890.                                                 $uniquegenre = array();
  891.                                                 $uniquegenre = explode(" / ",$data['Pays']);
  892.                                                 foreach ($uniquegenre as $key => $value) {  
  893.                                                     $uniquegenre2 = explode(" - ",$value);
  894.                                                     foreach ($uniquegenre2 as $key => $value) {
  895.                                                         ?>
  896.                                                         <form name='search-pays-<?php echo $value; ?>' method='post' action='index.php'>
  897.                                                         <input type='hidden' name='search_query_pays' value='<?php echo $value; ?>'>
  898.                                                         <input type='hidden' name='search_field' value='Pays'>
  899.                                                         </form>
  900.                                                        
  901.                                                        
  902.                                                         <?php
  903.                                                     }
  904.                                                    
  905.                                                 }
  906.                                                 function creategenre($genre) {
  907.                                                     $list="";
  908.                                                     $i=0;
  909.                                                     $uniquegenre = array();
  910.                                                     $uniquegenre = explode(" / ",$genre);
  911.                                                     foreach ($uniquegenre as $key => $value) {  
  912.                                                         $uniquegenre2 = explode(" - ",$value);
  913.                                                         foreach ($uniquegenre2 as $key => $value) {
  914.                                                             if ($i!=0) $list.=" / ";   
  915.                                                             $list.="<a style='color:#000000' href='#' onclick=\"javascript:document.forms['search-genre-$value'].submit();\">$value</a>";
  916.                                                             $i++;
  917.                                                         }
  918.                                                        
  919.                                                     }
  920.                                                     return $list;
  921.                                                 }
  922.                                                 function createpays($genre) {
  923.                                                     $list="";
  924.                                                     $i=0;
  925.                                                     $uniquegenre = array();
  926.                                                     $uniquegenre = explode(" / ",$genre);
  927.                                                     foreach ($uniquegenre as $key => $value) {  
  928.                                                         $uniquegenre2 = explode(" - ",$value);
  929.                                                         foreach ($uniquegenre2 as $key => $value) {
  930.                                                             if ($i!=0) $list.=" / ";   
  931.                                                             $list.="<a style='color:#000000' href='#' onclick=\"javascript:document.forms['search-pays-$value'].submit();\">$value</a>";
  932.                                                             $i++;
  933.                                                         }
  934.                                                
  935.                                                     }
  936.                                                     return $list;
  937.                                                         }
  938.                                                     ?>  
  939.                                                 <?php
  940.  
  941.                                                 if ($data['TitreVF']!=$data['TitreVO']) {
  942.                                                
  943.                                                 }
  944.                                                 ?>
  945.                                                
  946.                                                
  947.                                                 <h4><span><img width="32px" src="img/genre.png">&nbsp;&nbsp;&nbsp; <?php echo creategenre($data['Genre']); ?></span></p>
  948.                                                                                    
  949.                                                 </h4>
  950.                                                 <h4><span><a style="color:#000000" href='#' onclick="javascript:document.forms['search-date'].submit();"><img width="32px" src="img/calendar.png">&nbsp;&nbsp;&nbsp; <?php echo $data['Annee']; ?></a>
  951.                                                 <br /><br /><img width="32px" src="img/temps.png">&nbsp;<?php echo gmstrftime( "%kh %Mmn", $data['Duree'] * 60 ); ?></span>
  952.                                                
  953.                                                 <br /><br />
  954.                                                 <img width="32px"src="img/globe.png">&nbsp;&nbsp;<?php echo createpays($data['Pays']); ?>
  955.                                                 <br /><br />
  956.                                                 <img width="32px"src="img/like.png">&nbsp;&nbsp;&nbsp;&nbsp;<img width="96px" src="img/note<?php echo $data['Note']; ?>.png" />
  957.                                                 <br /><br /></h4>
  958.                                     </div>
  959.                                 </div>
  960.                    
  961.                                 <div class="tab-pane fade" id="messages">
  962.                                     <br />
  963.                                     <h4>Synopsis</h4>
  964.                                     <br />
  965.                                     <span class="muted"><strong><?php echo add_br($data['Synopsis']); ?></strong></span>
  966.                                 </div>
  967.                                 <div class="tab-pane fade" id="musique">
  968.                                     <br />
  969.                                     <h4>Musique du film</h4>
  970.                                     <br />
  971.                                     <span class="muted"><strong><?php echo add_br($data['Commentaires']); ?></strong></span>
  972.                                 </div>
  973.                             </div>
  974.                         </div>
  975.                     </div>
  976.                 </div>
  977.  
  978.             </div>
  979.  
  980.  
  981.             <?php } ?>
  982.     </div>
  983.  
  984.              <!-- /. PAGE INNER  -->
  985.     </div>
  986.          <!-- /. PAGE WRAPPER  -->
  987. </div>
  988. <?php } ?>
  989.  
  990.  
  991. <?php
  992.     }
  993. ?>
  994.     <!-- SCRIPTS -AT THE BOTOM TO REDUCE THE LOAD TIME-->
  995.     <!-- JQUERY SCRIPTS -->
  996.     <script src="assets/js/jquery-1.10.2.js"></script>
  997.       <!-- BOOTSTRAP SCRIPTS -->
  998.     <script src="assets/js/bootstrap.min.js"></script>
  999.     <!-- METISMENU SCRIPTS -->
  1000.     <script src="assets/js/jquery.metisMenu.js"></script>
  1001.      <!-- MORRIS CHART SCRIPTS -->
  1002.      <script src="assets/js/morris/raphael-2.1.0.min.js"></script>
  1003.     <script src="assets/js/morris/morris.js"></script>
  1004.       <!-- CUSTOM SCRIPTS -->
  1005.     <script src="assets/js/custom.js"></script>
Add Comment
Please, Sign In to add comment