redirect to main page if(preg_match($pattern, $page, $matches)) { header("HTTP/1.1 301 Moved Permanently"); header("Location: ".SITE_URL."/".$matches[2]."/band/".$matches[1]); } else if(preg_match($pattern2, $page, $matches)) { header("HTTP/1.1 301 Moved Permanently"); header("Location: ".SITE_URL."/".$matches[1]."/band/".$matches[2]); } else if(empty($_SERVER['HTTPS'])) { header("HTTP/1.1 301 Moved Permanently"); header("Location: ".SITE_URL.$_SERVER['REQUEST_URI']); } include("fonctions/divers.php"); include("class/membre.php"); include("class/f_groupe.php"); include("class/f_admin.php"); //pour create_dir_groupe include("class/f_date.php"); //include("class/f_forum.php"); //class topic pour les news include("class/f_design.php"); include("class/f_liens.php"); include("class/amazonS3.class.php"); require_once 'amazon/sdk.class.php'; if(isset($_GET['groupe'])) $groupe=derewritevar($_GET['groupe']); // VF else if(isset($_GET['band'])) $groupe=derewritevar($_GET['band']); // VO $stmt = $db_PDO->prepare("SELECT G.id_groupe,G.update_disco,G.obscenity AS BandObscenity,S.*,P.* FROM groupe G LEFT JOIN style S ON G.id_style=S.IDSTYLE LEFT JOIN pays P ON G.id_pays=P.id_pays WHERE nom_groupe_ref=?"); $stmt->bindValue(1,$groupe, PDO::PARAM_STR); $stmt->execute(); if($stmt->RowCount()==1) { $rows = $stmt->fetchAll(PDO::FETCH_ASSOC); extract($rows[0]); $style=new styleLgn($rows[0]); $pays=new paysLgn($rows[0]); define("CURRENT_PAGE",set_current_page_seo("band",array(clean($groupe)),$_GET['l'])); if($BandObscenity==1 && CLEAN_SITE) { header("HTTP/1.1 301 Moved Permanently"); header("Location: ".SITE_URL."/error.php"); exit(); } } else { define("CURRENT_PAGE",set_current_page("index.php",null,$_GET['l'])); } class groupeInfo extends groupe { function make_comments_lineup($comments,$lang) { global $txt_groupe; $comments=strip_tags($comments); // en cas de réencodage $tab_groupe=explode(",",$comments); $i=0; while($ilien_en onMouseOver=\"PopInfoGroupe('$id_groupe','en');\" onmouseout=\"killInfoGroupe()\">$NOMGROUPE",$tab_groupe[$i]); } $i++; } return implode(",", $tab_groupe); } function write_line_upXML($lang) { global $txt_groupe; $dir=getcwd(); if(!chdir(DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/")) { create_dir_groupe($conn_id,$this->nom_groupe_dir); //nothing seems there, let's try to create it chdir(DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/"); } if (!$handle = fopen("line_up.xml", 'w')) echo "Impossible to open the file ($path_to_file)"; // $rq="SELECT * FROM groupe_lineup WHERE id_groupe='$this->id_groupe' AND passe='0' AND comments!=''"; // $res=mysqli_query($GLOBALS['iconnexion'],$rq); // $comment_actu=mysqli_num_rows($res); // $rq="SELECT * FROM groupe_lineup WHERE id_groupe='$this->id_groupe' AND passe='1' AND comments!=''"; // $res=mysqli_query($GLOBALS['iconnexion'],$rq); // $comment_passe=mysqli_num_rows($res); $line_up=' '; //'.$comment_actu.''.$comment_passe.' $rq="SELECT * FROM groupe_lineup L INNER JOIN artists A ON L.id_artist = A.id_artist WHERE id_groupe='$this->id_groupe' AND passe='0'"; $res=mysqli_query($GLOBALS['iconnexion'],$rq); while($ligne=mysqli_fetch_array($res)) { extract($ligne); $instru_membre=display_instru($code_instru,$instru,$lang); $photo1=str_replace(' ','%20',$photo1); $line_up.=" ".$id_artist." $code_instru $instru"; // $line_up.=""; $otherbands=""; $rq2="SELECT G.*,L.passe FROM groupe_lineup L INNER JOIN groupe G ON L.id_groupe = G.id_groupe WHERE id_artist='$id_artist' AND G.id_groupe!='$this->id_groupe'"; $res2=mysqli_query($GLOBALS['iconnexion'],$rq2); $nb_other_bands=mysqli_num_rows($res2); $i=1; while($ligne2=mysqli_fetch_array($res2)) { extract($ligne2); if(!$passe) $otherbands.=$nom_groupe; else $otherbands.='ex-'.$nom_groupe; if($i<$nb_other_bands) $otherbands.=', '; $i++; } $line_up.=""; $line_up.=""; } $line_up.=""; $rq2="SELECT * FROM groupe_lineup L INNER JOIN artists A ON L.id_artist = A.id_artist WHERE id_groupe='$this->id_groupe' AND passe='1'"; $res2=mysqli_query($GLOBALS['iconnexion'],$rq2); if(mysqli_num_rows($res2)) { while($ligne2=mysqli_fetch_array($res2)) { extract($ligne2); $instru_membre=display_instru($code_instru,$instru,$lang); // $comments=$this->make_comments_lineup($comments,$lang); $photo1=str_replace(' ','%20',$photo1); $line_up.=" ".$id_artist." $code_instru $instru"; $otherbands=""; $rq3="SELECT G.*,L.passe FROM groupe_lineup L INNER JOIN groupe G ON L.id_groupe = G.id_groupe WHERE id_artist='$id_artist' AND G.id_groupe!='$this->id_groupe'"; $res3=mysqli_query($GLOBALS['iconnexion'],$rq3); $nb_other_bands=mysqli_num_rows($res3); $i=1; while($ligne3=mysqli_fetch_array($res3)) { extract($ligne3); if(!$passe) $otherbands.=$nom_groupe; else $otherbands.='ex-'.$nom_groupe; if($i<$nb_other_bands) $otherbands.=', '; $i++; } if($start!='0000' && $end!='0000') $otherbands=$start.' - '.$end.'
'.$otherbands; $line_up.=""; $line_up.="
"; } } // if($_SESSION['login']=='Kivan') // echo $line_up; $line_up.="
"; if (fwrite($handle, $line_up) === FALSE) echo "Impossible to write in the file ($path_to_file)"; fclose($handle); chdir($dir); // echo '
'.$line_up.'
'; } function affiche_lineupXML() { global $availableLanguage; global $txt_groupe; global $common; // if($this->update_lineup=="0" || $_SESSION['login']=='Kivan') //on efface tous les fichiers de langues if($this->update_lineup=="0") //on efface tous les fichiers de langues { foreach($availableLanguage as $Cachelang) { @unlink(DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/line_up_$Cachelang.htm"); // get rid of all .htm cache files } @unlink(DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/line_up.xml"); $rq2="UPDATE groupe SET update_lineup='1' WHERE id_groupe='$this->id_groupe'"; $res2=mysqli_query($GLOBALS['iconnexion'],$rq2); } // if($_SESSION['login']=='Kivan') // $this->write_line_upXML(LANG_TEXT); if(!is_file(DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/line_up.xml")) $this->write_line_upXML(LANG_TEXT); // if($_SESSION['login']=='Kivan') // echo DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/line_up.xml"; if(is_file(DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/line_up.xml")) { $XML = simplexml_load_file(DIR_SITE."/les goupes/$this->lettre/$this->nom_groupe_dir/line_up.xml"); $line_up.='
'; if(count($XML->current->member)>0) $line_up.='

Line-up

'; if(count($XML->past->member)>0) { // if($_SESSION['login']='Kivan') // echo "Some past members found
"; $line_up.='

'.$txt_groupe[10].'

    '; $i=1; foreach($XML->past->member as $member) { /* if($XML->comment_passe) { $member->comment=strip_tags($member->comment); /// temporary $member->comment=str_replace('"','',$member->comment); } */ $instru_membre=display_instru($member->code_instru,$member->instru); if($member->picture!='' && $member->picture!='/membre_groupe/photo/') $tooltip='data-toggle="tooltip" data-html="true" data-title="
    '.str_replace('"','"',$member->name).'
    "'; else $tooltip=""; $line_up.="

    ".stripslashes($member->name)."

    $instru_membre

    ".str_replace('/en/','/'.LANG_TEXT.'/',$member->comment)."

    "; $i++; if($i==6 && count($XML->past->member)>6) $line_up.=' '.$common['SeeMore'].' '; $line_up.="
"; } else { // if($_SESSION['login']='Kivan') // echo "No past members found
"; } $line_up.="
"; /* $i=1; $rq="SELECT * FROM groupe_asso_membre G,groupe_membre M WHERE G.id_groupe='$this->id_groupe' AND G.id_membre=M.id_groupe_membre LIMIT 1"; $res=mysqli_query($GLOBALS['iconnexion'],$rq); if(mysqli_num_rows($res)) { $line_up.=" "; while($ligne=mysqli_fetch_array($res)) { extract($ligne); $membre_groupe=new groupe_membre($id_groupe_membre); $line_up.="lien."\" title=\"open image\" class=\"open\"> photo\" class=\"full\" width=150 border=0>"; } $line_up.=""; } else $line_up.=""; $line_up.=""; */ echo $line_up; } } } $groupe=new groupeInfo($id_groupe); GetS3($groupe->dir_groupe.'pics/'.$groupe->logo,'bands'.SITE_ID.'/'.$groupe->lettre.'/'.$groupe->id_groupe.'/'.$groupe->logo); if($groupe->photo1) GetS3($groupe->dir_groupe.'pics/'.$groupe->photo1,'bands'.SITE_ID.'/'.$groupe->lettre.'/'.$groupe->id_groupe.'/pic_1.jpg'); if($groupe->photo2) GetS3($groupe->dir_groupe.'pics/'.$groupe->photo2,'bands'.SITE_ID.'/'.$groupe->lettre.'/'.$groupe->id_groupe.'/pic_2.jpg'); if($groupe->photo3) GetS3($groupe->dir_groupe.'pics/'.$groupe->photo3,'bands'.SITE_ID.'/'.$groupe->lettre.'/'.$groupe->id_groupe.'/pic_3.jpg'); echo " $groupe->nom_groupe - ".$txt_groupe[12]." "; // include("style.htm"); include("styleNEW.htm"); //include("gallery.htm"); echo ""; if($groupe->nom_groupe=="") echo ''; if(!isset($_GET['l'])) { echo ""; // no duplicate content /// redirection pour les humains echo ""; } ?> '; $style=new style($groupe->id_style); include("js/InfoBulle.htm"); include("tableaux/type_lien_fan.php"); if($groupe->nom_groupe=="") { //include("class/f_recherche.php"); $txt_disco[3]=str_replace('SITE_NAME',SITE_NAME,$txt_disco[3]); echo "
".$txt_disco[3]."
"; if($_GET['groupe']=="") exit(); $nom_groupe=mysqli_real_escape_string($GLOBALS['iconnexion'],$_GET['groupe']); if(strlen($nom_groupe)==1) $rq="SELECT N.id_groupe,G.nom_groupe,G.nom_groupe_ref,G.autre_nom,G.id_style,P.nom_pays_en,P.nom_pays_fr,S.nom_fr,S.nom_en FROM groupe_nom N,groupe G LEFT JOIN pays P ON G.id_pays=P.id_pays LEFT JOIN style S ON G.id_style=S.IDSTYLE WHERE N.nom_groupe LIKE \"$nom_groupe\" AND G.id_groupe=N.id_groupe GROUP BY id_groupe ORDER BY N.nom_groupe"; else// if(strlen($nom_groupe)<4) $rq="SELECT N.id_groupe,G.nom_groupe,G.nom_groupe_ref,G.autre_nom,G.id_style,P.nom_pays_en,P.nom_pays_fr,S.nom_fr,S.nom_en FROM groupe_nom N,groupe G LEFT JOIN pays P ON G.id_pays=P.id_pays LEFT JOIN style S ON G.id_style=S.IDSTYLE WHERE N.nom_groupe LIKE \"$nom_groupe%\" AND G.id_groupe=N.id_groupe GROUP BY id_groupe ORDER BY N.nom_groupe"; $res=mysqli_query($GLOBALS['iconnexion'],$rq); $nb_groupe=mysqli_num_rows($res); if($nb_groupe==1) { $ligne=mysqli_fetch_array($res); $groupe=new groupeLgn($ligne); if($groupe->lien) echo "Groupe : "; } else if($nb_groupe) { echo '

'.$txt_moteur[6].'

'; while($ligne=mysqli_fetch_array($res)) { extract($ligne); if($autre_nom) $txt_autre_nom=" - ".$txt_moteur[8]." : $autre_nom"; else $txt_autre_nom=""; echo "
    $nom_groupe (".display($nom_fr,$nom_en)."-".display($nom_pays_fr,$nom_pays_en).") ".$txt_autre_nom."
"; $i++; } echo '
'; } $i=0; if($nb_groupe==0) { $lettre=$nom_groupe[0]; $nom_groupeToFind=$nom_groupe; $rq="SELECT nom_groupe,id_groupe FROM `groupe` WHERE nom_groupe LIKE \"$lettre%\""; $res=mysqli_query($GLOBALS['iconnexion'],$rq); while($ligne=mysqli_fetch_array($res)) { extract($ligne); similar_text($nom_groupe, $nom_groupeToFind,$p); if($p>50) { $p=round($p,0); $tab[]="$p:$id_groupe"; } } if($tab) { rsort($tab); echo '

'.$txt_groupe[13].'

'; for($i=0;$i<10 && $tab[$i];$i++) { list($p,$id_groupe)=explode(":",$tab[$i]); $groupe=new groupe($id_groupe); $pays_groupe=new pays($groupe->id_pays); $style=new style($groupe->id_style); echo ""; } echo '
'; } } } else { // echo '
'; // include("changelanguage.php"); // echo '
'; if($groupe->id_ville) $ville=new ville($groupe->id_ville); echo ''; /////// TABELAU N°1 : LA PRESENTATION //////////////////// // CadreWide(1,"".$common['BandList']." nom))).">$style->nom $groupe->nom_groupe"); if($groupe->a_bio(LANG)) $lien="submit_bio.php?id_groupe=$id_groupe"; else $lien="bio_add.php?id_groupe=$id_groupe"; //
'.display("Ajouter/modifier un lien","Add/edit a link").'
echo '

'.$groupe->nom_groupe.'

'; if(isset($_SESSION['login'])) { echo '
'; $membre=new membre($_SESSION['login']); $rq2="SELECT pseudo,type FROM `submission_validator` WHERE pseudo='".$_SESSION['login']."' AND (type='1a' || type='1b')"; $res2=mysqli_query($GLOBALS['iconnexion'],$rq2); if(mysqli_num_rows($res2)>0) $allow_deletion=true; else $allow_deletion=false; if($allow_deletion || $membre->cercle==1) { echo '
'.display("Supprimer $groupe->nom_groupe","Delete $groupe->nom_groupe").'
'; echo '
'.display("Pénaliser","Penalize").'
'; // displayCadreMenu2("lightred",display("Supprimer le groupe","Remove the band"),,,"mes%20images/misc/icon_delete.jpg"); // displayCadreMenu2("lightred",,display("Pénaliser le membre ayant ajouté ce groupe","Penalize the membre who added this band"),","mes%20images/misc/icon_penalize.jpg"); // displayCadreMenu2("lightred",display("Copier le groupe","Copy the band"),display("Dupliquer $groupe->nom_groupe vers $AutreSite","Copy $groupe->nom_groupe to $AutreSite"),lien("team/access/copy_band.php?id_groupe=$id_groupe"),"mes%20images/misc/icon_add.jpg"); } if( ($membre->chroniqueur!=0) || $membre->cercle==1) { echo '
'.display("Ajouter une interview","Add an interview").'
'; // echo ""; // displayCadreMenu2("lightred",display("Ajouter une interview","Add an interview"),,,"mes%20images/misc/icon_itw.jpg"); // echo ""; } echo '
'; //end row } echo '
'; //end content $groupe->affiche_logo(); echo '
'; if($id_bio=$groupe->a_bio(LANG)) echo '
'.display("Lire la biographie","Read the biography").'
'; echo '
'; if($groupe->PreviousBand1 || $groupe->PreviousBand2 || $groupe->PreviousBand3) { echo '
'.display("Noms précédants","Previous Names").' '; if($groupe->PreviousBand1) { $stmt = $db_PDO->prepare("SELECT nom_groupe AS PreviousBandName1,nom_groupe_ref AS PreviousBandLink1 FROM groupe WHERE id_groupe LIKE ?"); $stmt->bindValue(1, $groupe->PreviousBand1, PDO::PARAM_INT); $stmt->execute(); if($stmt->RowCount()==1) { $rows = $stmt->fetchAll(PDO::FETCH_ASSOC); extract($rows[0]); echo "$PreviousBandName1"; } } if($groupe->PreviousBand2) { $stmt = $db_PDO->prepare("SELECT nom_groupe AS PreviousBandName2,nom_groupe_ref AS PreviousBandLink2 FROM groupe WHERE id_groupe LIKE ?"); $stmt->bindValue(1, $groupe->PreviousBand2, PDO::PARAM_INT); $stmt->execute(); if($stmt->RowCount()==1) { $rows = $stmt->fetchAll(PDO::FETCH_ASSOC); extract($rows[0]); if($groupe->PreviousBand1) echo ', '; echo "$PreviousBandName2"; } } if($groupe->PreviousBand3) { $stmt = $db_PDO->prepare("SELECT nom_groupe AS PreviousBandName3,nom_groupe_ref AS PreviousBandLink3 FROM groupe WHERE id_groupe LIKE ?"); $stmt->bindValue(1, $groupe->PreviousBand3, PDO::PARAM_INT); $stmt->execute(); if($stmt->RowCount()==1) { $rows = $stmt->fetchAll(PDO::FETCH_ASSOC); extract($rows[0]); if($groupe->PreviousBand1 || $groupe->PreviousBand2) echo ', '; echo "$PreviousBandName3"; } } echo '
'; } if($groupe->ActualBand) { $stmt = $db_PDO->prepare("SELECT nom_groupe AS ActualBandName,nom_groupe_ref AS ActualBandLink FROM groupe WHERE id_groupe LIKE ?"); $stmt->bindValue(1, $groupe->ActualBand, PDO::PARAM_INT); $stmt->execute(); if($stmt->RowCount()==1) { $rows = $stmt->fetchAll(PDO::FETCH_ASSOC); extract($rows[0]); echo "
".display("changé de nom pour ","Changed name to ")." $ActualBandName
"; } } if($groupe->autre_nom) echo "
".$txt_groupe[0]." $groupe->autre_nom
"; echo '
'.$txt_main[29].' '.$style->nom.'
'.$txt_groupe[2].' '.$tab_statut[$groupe->statut_groupe].'
'.$txt_groupe[3].' '.$groupe->affichedate('crea').'
'; if($groupe->dateSep!="0000") echo '
'.$txt_groupe[4].' '.$groupe->affichedate('Sep').'
'; echo '
'.$common['country'].''; if($pays->nom_pays=="unknown" || $pays->nom_pays=="inconnu") echo ''.$pays->nom_pays.''; else echo ''.$pays->nom_pays.''; echo '
'; if($groupe->id_ville) { list($ville,$region)=explode(",",$ville->nom_ville); echo '
'.$common['city'].' '.$ville.'
'; } echo '
'.$txt_groupe[5].' '; for($i=0;$i<$groupe->nb_etoile;$i++) echo ''; echo '
'.$common['Fans'].' '.$groupe->nb_fans.'
'; $stmt = $db_PDO->prepare("SELECT * FROM fan WHERE id_groupe=? AND pseudo=?"); $stmt->bindValue(1, $groupe->id_groupe, PDO::PARAM_INT); $stmt->bindValue(2, $_SESSION['login'], PDO::PARAM_STR); $stmt->execute(); if($stmt->RowCount()) echo ''.$txt_groupe[18].' '; //he is fan else echo ''.$txt_groupe[17].' '; //he is not fan echo '
'; if($groupe->nazi) echo ""; echo '
'; // $groupe->affiche_groupe(); // echo "

"; $groupe->affiche_lineupXML(); /* if(!$update_disco) //delete all cache files { foreach($availableLanguage as $Cachelang) @unlink(DIR_SITE."/les goupes/$groupe->lettre/$groupe->nom_groupe_dir/disco-$Cachelang.htm"); @unlink(DIR_SITE."/les goupes/$groupe->lettre/$groupe->nom_groupe_dir/disco.xml"); $rq2="UPDATE groupe SET update_disco='1' WHERE id_groupe='$id_groupe'"; $res2=mysqli_query($GLOBALS['iconnexion'],$rq2); } */ echo "

"; // if(!is_file(DIR_SITE."/les goupes/$groupe->lettre/$groupe->nom_groupe_dir/disco.xml")) // write_disco(); //write cache file in current language // $XML = simplexml_load_file(DIR_SITE."/les goupes/$groupe->lettre/$groupe->nom_groupe_dir/disco.xml"); echo '

'.$common['albums'].'

'; $tab_menu_albumLink[]="Demos"; $tab_menu_albumLink[]="Albums"; $tab_menu_albumLink[]="Live"; $tab_menu_albumLink[]="Compilations"; $tab_menu_albumLink[]="Video"; $tab_menu_albumLink[]="Single"; $tab_menu_albumLink[]="Bootlegs"; $tab_menu_albumLink[]="Box_Set"; $tab_menu_albumLink[]="Tributes"; echo ''; echo '
'; echo '
'; if(isset($_GET['p'])) $page=(int)$_GET['p']; else $page=1; $next_page=$page+1; $max_result=100; $start=($page-1)*$max_result; if(isset($_GET['type'])) { $type=$_GET['type']; if($type=='Splits') { $stmt = $db_PDO->prepare("SELECT A.* FROM albums A WHERE (A.id_groupe=:id_groupe AND A.type_album='Split') UNION SELECT A.* FROM albums_groupeSup G,albums A WHERE (G.id_album=A.id_album AND G.id_groupe=:id_groupe)"); $stmt->bindValue(':id_groupe', $id_groupe, PDO::PARAM_INT); $stmt->execute(); $nb_page=ceil($stmt->RowCount()/$max_result); echo ''; $stmt = $db_PDO->prepare("SELECT A.* FROM albums A WHERE (A.id_groupe=:id_groupe AND A.type_album='Split') UNION SELECT A.* FROM albums_groupeSup G,albums A WHERE (G.id_album=A.id_album AND G.id_groupe=:id_groupe) ORDER BY date_sortie LIMIT :start,:max"); $stmt->bindValue(':id_groupe', $id_groupe, PDO::PARAM_INT); $stmt->bindValue(':start', $start, PDO::PARAM_INT); $stmt->bindValue(':max', $max_result, PDO::PARAM_INT); } else { $stmt = $db_PDO->prepare("SELECT * FROM albums WHERE id_groupe=:id_groupe AND ($tab_menu_album_requete[$type])"); $stmt->bindValue(':id_groupe', $id_groupe, PDO::PARAM_INT); $stmt->execute(); echo ''; $stmt = $db_PDO->prepare("SELECT G.nom_groupe,G.nom_groupe_ref,A.* FROM albums A INNER JOIN groupe G ON A.id_groupe=G.id_groupe WHERE G.id_groupe=:id_groupe AND ($tab_menu_album_requete[$type]) ORDER BY date_sortie LIMIT :start,:max"); $stmt->bindValue(':id_groupe', $id_groupe, PDO::PARAM_INT); $stmt->bindValue(':start', $start, PDO::PARAM_INT); $stmt->bindValue(':max', $max_result, PDO::PARAM_INT); } } else { foreach($tab_menu_album_requete as $condition) { $stmt = $db_PDO->prepare("SELECT * FROM albums WHERE id_groupe=:id_groupe AND ($condition) ORDER BY date_sortie"); $stmt->bindValue(':id_groupe', $groupe->id_groupe, PDO::PARAM_INT); $stmt->execute(); if($stmt->RowCount()>0) { $isFound=true; break; } } if(!$isFound) ///nothing found, there might be a split { $stmt = $db_PDO->prepare("SELECT A.* FROM albums A WHERE (A.id_groupe=:id_groupe AND A.type_album='Split') UNION SELECT A.* FROM albums_groupeSup G,albums A WHERE (G.id_album=A.id_album AND G.id_groupe=:id_groupe)"); $stmt->bindValue(':id_groupe', $id_groupe, PDO::PARAM_INT); $stmt->execute(); if($stmt->RowCount()>0) $ThereIsOnlySplits=true; } $nb_page=ceil($stmt->RowCount()/$max_result); echo ''; if(!$ThereIsOnlySplits) { // if(CLEAN_SITE) // $stmt = $db_PDO->prepare("SELECT * FROM albums WHERE id_groupe=:id_groupe AND ($condition) AND nudity=0 AND obscenity=0 AND obscenity_tracklist=0 ORDER BY date_sortie LIMIT :start,:max"); // else $stmt = $db_PDO->prepare("SELECT G.nom_groupe,G.nom_groupe_ref,A.* FROM albums A INNER JOIN groupe G ON A.id_groupe=G.id_groupe WHERE A.id_groupe=:id_groupe AND ($condition) ORDER BY date_sortie LIMIT :start,:max"); $stmt->bindValue(':id_groupe', $id_groupe, PDO::PARAM_INT); $stmt->bindValue(':start', $start, PDO::PARAM_INT); $stmt->bindValue(':max', $max_result, PDO::PARAM_INT); } else { // if(CLEAN_SITE) // $stmt = $db_PDO->prepare("SELECT A.* FROM albums A WHERE (A.id_groupe=:id_groupe AND A.type_album='Split') AND nudity=0 AND obscenity=0 AND obscenity_tracklist=0 UNION // SELECT A.* FROM albums_groupeSup G,albums A WHERE (G.id_album=A.id_album AND G.id_groupe=:id_groupe) AND A.nudity=0 AND A.obscenity=0 AND A.obscenity_tracklist=0 ORDER BY date_sortie LIMIT :start,:max"); // else $stmt = $db_PDO->prepare("SELECT G.nom_groupe,G.nom_groupe_ref,A.* FROM albums A INNER JOIN groupe G ON A.id_groupe=G.id_groupe WHERE (A.id_groupe=:id_groupe AND A.type_album='Split') UNION SELECT G.nom_groupe,G.nom_groupe_ref,A.* FROM albums_groupeSup GSUP,albums A INNER JOIN groupe G ON A.id_groupe=G.id_groupe WHERE (GSUP.id_album=A.id_album AND GSUP.id_groupe=:id_groupe) ORDER BY date_sortie LIMIT :start,:max"); $stmt->bindValue(':id_groupe', $id_groupe, PDO::PARAM_INT); $stmt->bindValue(':start', $start, PDO::PARAM_INT); $stmt->bindValue(':max', $max_result, PDO::PARAM_INT); } } $stmt->execute(); $rows = $stmt->fetchAll(PDO::FETCH_ASSOC); foreach($rows as $ligne) { $album = new albumLgn($ligne); $album->get_pochette(); affiche_ligne_album($album); if($AlbumObscenity==0 && ($ligne['obscenity']==1 || $ligne['nudity']==1 || $ligne['verifcover']==0)) { // if($_SESSION['login']=='Kivan') // echo "album obscenity: ".$ligne['obscenity']." - Nudity: ".$ligne['nudity']." - verif cover: ".$ligne['verifcover']; $AlbumObscenity=1; } } if($stmt->RowCount()==$max_result) ///we assume there is more to load echo ''; // if($_SESSION['login']=='Kivan') // echo "album obscenity: $AlbumObscenity "; /* $disco=""; if($tab_disco) { $tab_disco=array_unique($tab_disco); sort($tab_disco); $i=0; while($tab_disco[$i]) { list($date_sortie,$id_groupe,$id_album)=explode(":",$tab_disco[$i]); list($anne,$mois,$jour)=explode("-",$date_sortie); $album = new album($id_album); $album->get_pochette(); affiche_ligne_album($album); $i++; } } */ if(!$stmt->RowCount()) echo "".$txt_disco[5]."
"; echo '
'; infinitescrollerstatus(); echo '
'; // nom_groupe_dir&type=Albums").'">'.$txt_main[22].''; ////////////// VIDEO //////////////////////////////// $stmt = $db_PDO->prepare("SELECT lien_video FROM `video_groupe` WHERE id_groupe=? AND deleted=0 AND type=1 ORDER BY type,date_ajout DESC LIMIT 10"); $stmt->bindValue(1, $id_groupe, PDO::PARAM_INT); $stmt->execute(); $lastCheckDateLimit=date("Y-m-d",mktime(0, 0, 0, date("m")-1, date("d"), date("Y"))); if($stmt->RowCount()) { $allow=false; if(isset($_SESSION['login'])) { if(est_cercle1($_SESSION['login'])) $allow=true; if(!$allow) { $rq2="SELECT pseudo,type FROM `submission_validator` WHERE pseudo='".$_SESSION['login']."' AND (type='13a' || type='13b')"; $res2=mysqli_query($GLOBALS['iconnexion'],$rq2); if(mysqli_num_rows($res2)>0) $allow=true; } } echo '
'; if($allow) echo '  '; echo '

'.$common['Videos'].'

'.$txt_groupe[15].''; echo '
'; } echo '
'; } include("footer.php"); ?>