2009-07-09 12:21:23 +00:00
< ? php
if ( ! $_SESSION [ 'connected' ]) die ();
if ( $_SESSION [ 'tabInfo' ][ 'idClient' ] == 34 ){ $_SESSION [ 'nowAuthorized' ] = TRUE ; }
2009-02-19 16:28:12 +00:00
2009-05-27 15:56:34 +00:00
require_once 'utils.php' ;
require_once 'common/dates.php' ;
2009-08-27 07:39:27 +00:00
require_once 'cache/cache.php' ;
require_once 'user/user.php' ;
2009-02-19 16:28:12 +00:00
2009-08-27 07:39:27 +00:00
//Traitement des param<61> tres
2009-02-19 16:28:12 +00:00
$siret = trim ( preg_replace ( '/[^0-9]/' , '' , $_REQUEST [ 'siret' ]));
if ( strlen ( $siret ) <> 0 && strlen ( $siret ) <> 9 && strlen ( $siret ) <> 14 ) die ( 'Param<61> tres incorrects !' );
2009-03-11 07:51:18 +00:00
$idEntreprise = trim ( preg_replace ( '/[^0-9]/' , '' , $_REQUEST [ 'idEntreprise' ])) * 1 ; // Si id=0 alors non communiqu<71>
2009-06-17 12:13:33 +00:00
if (( $siret * 1 ) == 0 && $idEntreprise == 0 ) die ( 'Param<61> tres incorrects !' );
2009-02-19 16:28:12 +00:00
$siren = substr ( $siret , 0 , 9 );
2009-09-15 08:47:55 +00:00
//Enregistrement pour liste derni<6E> re recherche
require_once 'recherche/session.php' ;
$parametres = recherche_element ( 0 );
if ( isset ( $parametres ) && $parametres [ 'info' ][ 'page' ] == 'recherche' )
{
recherche_saveinfo ( array ( 'page' => $page ) );
recherche_saveinfo ( array ( 'siret' => $siret ) );
}
2009-08-27 07:39:27 +00:00
//G<> n<EFBFBD> rer un nom de fichier pour le cache et l'export des fichiers
if (( $siret * 1 ) == 0 || ( $siren * 1 ) < 100 ){ $fileName = $page2 . '-' . $idEntreprise ;
} else { $fileName = $page2 . '-' . $siret ; }
cache_filename ( $fileName );
if ( cache_exist () && ! ( preg_match ( '/saisie/i' , $_SESSION [ 'tabInfo' ][ 'droits' ]) || $_SESSION [ 'tabInfo' ][ 'mode_edition' ] == 1 ) ){
$etab = cache_get ( 'etab' );
//Affichage d'un message d'erreur
if ( $etab === FALSE ) exit ;
$firephp -> info ( 'CACHE' );
} else {
$firephp -> info ( 'WS : getIdentite' );
2009-03-10 15:07:24 +00:00
try {
2009-03-11 07:51:18 +00:00
$O = $client -> getIdentite ( $siret , $idEntreprise );
2009-08-27 07:39:27 +00:00
$etab = $O [ 'result' ];
2009-03-10 15:07:24 +00:00
$firephp -> log ( $etab , 'etab' );
2009-08-27 07:39:27 +00:00
cache_delete ();
cache_add ( 'etab' , $etab );
2009-03-10 15:07:24 +00:00
} catch ( SoapFault $fault ) {
2009-07-21 07:17:54 +00:00
require_once 'soaperror.php' ;
2009-08-27 07:39:27 +00:00
processSoapFault ( $client , $fault , $_SESSION [ 'tabInfo' ]);
2009-03-10 15:07:24 +00:00
die ();
}
2009-08-27 07:39:27 +00:00
}
2009-03-10 15:07:24 +00:00
2009-08-27 07:39:27 +00:00
$tabEntrep = array ();
$tabEntrep [ 'raisonSociale' ] = $etab [ 'Nom' ];
$tabEntrep [ 'siren' ] = $etab [ 'Siren' ];
$tabEntrep [ 'siret' ] = $etab [ 'Siret' ];
$tabEntrep [ 'tva' ] = $etab [ 'TvaNumero' ];
$tabEntrep [ 'isin' ] = $etab [ 'Isin' ];
$tabEntrep [ 'AutreId' ] = $etab [ 'AutreId' ];
$tabEntrep [ 'active' ] = $etab [ 'Statut' ];
$tabEntrep [ 'Source' ] = $etab [ 'Source' ];
$tabEntrep [ 'SourceId' ] = $etab [ 'SourceId' ];
$tabEntrep [ 'codeCommune' ] = $etab [ 'Dept' ] . $etab [ 'codeCommune' ]; //Utilise pour les comp<6D> tences territoriales
$tabEntrep [ 'nafEn' ] = $etab [ 'NafEnt' ];
$tabEntrep [ 'nafEnLib' ] = $etab [ 'NafEntLib' ];
$tabEntrep [ 'nafEt' ] = $etab [ 'NafEtab' ];
$tabEntrep [ 'nafEtLib' ] = $etab [ 'NafEtabLib' ];
$tabEntrep [ 'fj' ] = $etab [ 'FJ' ];
$_SESSION [ 'tabInfo' ][ 'entrep' ] = $tabEntrep ;
?>
< style type = " text/css " >
. txtAdresse p { clear : both ; float : left ; margin : 0 ;}
. search { float : right ; width : 150 px ;}
. search p { margin : 0 0 0 20 px ;}
p . adresse { margin : 0 ; padding : 0 ; width : auto ;}
</ style >
< div id = " center " >
< h1 class = " titre " > IDENTIT & Eacute ; DE L ' ENTREPRISE </ h1 >
< table >
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Num & eacute ; ro identifiant Siret </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = substr ( $etab [ 'Siren' ], 0 , 3 ) . ' ' . substr ( $etab [ 'Siren' ], 3 , 3 ) . ' ' . substr ( $etab [ 'Siren' ], 6 , 3 ) . ' <i>' . substr ( $etab [ 'Siret' ], 9 , 5 ) . '</i>' ?> </td>
</ tr >
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Num & eacute ; ro identifiant Siret du si & egrave ; ge </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = substr ( $etab [ 'SiretSiege' ], 0 , 3 ) . ' ' . substr ( $etab [ 'SiretSiege' ], 3 , 3 ) . ' ' . substr ( $etab [ 'SiretSiege' ], 6 , 3 ) . ' <i>' . substr ( $etab [ 'SiretSiege' ], 9 , 5 ) . '</i>' ?> </td>
</ tr >
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Num & eacute ; ro de TVA Intracom .</ td >
< td width = " 350 " class = " StyleInfoData " valign = " middle " >< ?
if ( $etab [ 'Dept' ] * 1 == 97 ) {
echo '<a href="http://eur-lex.europa.eu/LexUriServ/LexUriServ.do?uri=CELEX:31991L0680:FR:HTML" target="_blank">Non attribué dans les D.O.M.</a>' ;
} else {
echo substr ( $etab [ 'TvaNumero' ], 0 , 2 ) . ' ' . substr ( $etab [ 'TvaNumero' ], 2 , 2 ) . ' ' . substr ( $etab [ 'TvaNumero' ], - 9 );
if ( ! $etab [ 'TvaAttribue' ])
echo ' <img src="./img/exclamation.png" title="Non valid<69> . Obligatoire sur factures, d<> clarations d\'<27> change de biens et de TVA !">' ;
}
?>
</ td >
</ tr >
< ? php
/* On recherche un logo */
$urlImg = '' ;
$siteWeb = '' ;
$locImg = PATH_LOGOS . $etab [ 'Siren' ];
if ( file_exists ( $locImg . '.gif' )) { $urlImg = './logos/' . $etab [ 'Siren' ] . '.gif' ; $ext = '.gif' ; }
elseif ( file_exists ( $locImg . '.png' )) { $urlImg = './logos/' . $etab [ 'Siren' ] . '.png' ; $ext = '.png' ; }
elseif ( file_exists ( $locImg . '.jpg' )) { $urlImg = './logos/' . $etab [ 'Siren' ] . '.jpg' ; $ext = '.jpg' ; }
elseif ( file_exists ( $locImg . '.jpeg' )) { $urlImg = './logos/' . $etab [ 'Siren' ] . '.jpeg' ; $ext = '.jpeg' ; }
print '<!-- ' . $locImg . ' ' . $urlImg . '-->' ;
if ( $urlImg == '' && $etab [ 'Isin' ] <> '' ) {
$locImg = PATH_LOGOS . $etab [ 'Isin' ];
if ( file_exists ( $locImg . '.gif' )) { $urlImg = './logos/' . $etab [ 'Isin' ] . '.gif' ; $ext = '.gif' ; }
elseif ( file_exists ( $locImg . '.png' )) { $urlImg = './logos/' . $etab [ 'Isin' ] . '.png' ; $ext = '.png' ; }
elseif ( file_exists ( $locImg . '.jpg' )) { $urlImg = './logos/' . $etab [ 'Isin' ] . '.jpg' ; $ext = '.jpg' ; }
elseif ( file_exists ( $locImg . '.jpeg' )) { $urlImg = './logos/' . $etab [ 'Isin' ] . '.jpeg' ; $ext = '.jpeg' ; }
2009-03-10 09:13:05 +00:00
}
2009-06-17 12:13:33 +00:00
2009-08-27 07:39:27 +00:00
if ( trim ( $etab [ 'Web' ]) <> '' ) {
if ( substr ( $etab [ 'Web' ], 0 , 7 ) <> 'http://' )
$siteWeb = 'http://' . $etab [ 'Web' ];
else
$siteWeb = $etab [ 'Web' ];
if ( $urlImg == '' && ( $_SESSION [ 'tabInfo' ][ 'login' ] == 'ylenaour' ||
$_SESSION [ 'tabInfo' ][ 'login' ] == 'mpurcarin' ||
$_SESSION [ 'tabInfo' ][ 'login' ] == 'mcochet' ||
$_SESSION [ 'tabInfo' ][ 'login' ] == 'aegasse' ||
$_SESSION [ 'tabInfo' ][ 'login' ] == 'jmartory' ) )
$urlImg = getLogo ( $siteWeb , $etab [ 'Siren' ]);
}
2009-06-17 12:13:33 +00:00
2009-08-27 07:39:27 +00:00
if ( $etab [ 'Isin' ] <> '' ) {
$bourse = $etab [ 'Bourse' ];
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Code ISIN </ td >
< td width = " 350 " class = " StyleInfoData " >< a href = " ./?page=bourse&siret=<?= $etab['Siret'] ?> " title = " Voir les informations boursiéres " >< ? = $etab [ 'Isin' ] ?> </a></td>
</ tr >
< ? php
if ( $bourse [ 'capitalisation' ] <> 0 ) {
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Capitalisation </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = number_format ( $bourse [ 'capitalisation' ], 0 , '' , ' ' ) ?> € au <?=WDate::dateT('Y-m-d','d/m/Y',$bourse['derCoursDate'])?></td>
</ tr >
< ? php
2009-08-05 09:14:20 +00:00
}
2009-08-27 07:39:27 +00:00
}
//Ne pas afficher le logo si il n'existe pas OU si le siren est <20> 0 OU si le siren est inf<6E> rieur a 100
if (( $siren * 1 != 0 ) || ( $siren * 1 > 100 ))
{
if ( $urlImg <> '' )
{
$tabTmp =@ getimagesize ( $locImg . $ext );
$w = $tabTmp [ 0 ];
$h = $tabTmp [ 1 ];
if ( $w > 350 ) $strSize =@ redimage ( $locImg . $ext , 350 , 150 );
else $strSize = '' ;
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Logo </ td >
< td width = " 350 " class = " StyleInfoData " >< img src = " <?= $urlImg ?> " < ? = $strSize ?> /></td>
</ tr >
< ?
}
}
?>
< ? php
//Num<75> ro RC
$flagNewRC = FALSE ;
if ( isset ( $etab [ 'numRC' ]) && $etab [ 'numRC' ] != '' ) {
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Num<EFBFBD> ro R . C .</ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $etab [ 'numRC' ] ?> </td>
</ tr >
< ? php
$flagNewRC = TRUE ;
}
?>
< ? php
//Autre identifiant : Num<75> ro WALDEC ou ancien num<75> ro RC si le nouveau n'est pas disponible
if ( isset ( $etab [ 'AutreId' ]) && $etab [ 'AutreId' ] != '' && ( ! $flafNewRC || substr ( $etab [ 'AutreId' ], 0 , 1 ) == 'W' ))
{
$libTrib = '' ;
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " >
2009-08-05 09:14:20 +00:00
< ? php
2009-08-27 07:39:27 +00:00
if ( substr ( $etab [ 'AutreId' ], 0 , 1 ) == 'W' ) print 'Identifiant Association WALDEC' ;
elseif ( preg_match ( '/(A|B|C|D)/i' , $etab [ 'AutreId' ]))
2009-08-05 09:58:18 +00:00
{
2009-08-27 07:39:27 +00:00
print 'Numéro R.C.' ;
$libTrib = ' RCS ' . preg_replace ( '/(^TC |^TI |^TGIcc |^TMX )/i' , '' , $etab [ 'TribunalLib' ]);
2009-08-05 09:14:20 +00:00
}
2009-09-03 09:18:09 +00:00
elseif ( preg_match ( '/(P)/i' , $etab [ 'AutreId' ]))
{
print 'Numéro R.S.A.C.' ;
$libTrib = ' RSAC ' . preg_replace ( '/(^TC |^TI |^TGIcc |^TMX )/i' , '' , $etab [ 'TribunalLib' ]);
}
2009-08-05 09:14:20 +00:00
?>
2009-08-27 07:39:27 +00:00
</ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $etab [ 'AutreId' ] . $libTrib ?> </td>
</ tr >
< ?
}
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Etablissement actif
< ? php
if ( $etab [ 'Siege' ] == 0 )
echo '<br/><a title="Voir la fiche d\'identit<69> du si<73> ge de l\'entreprise" href="/?page=identite&siret=' . $etab [ 'Siren' ] . '&idEntreprise=' . $idEntreprise . '">Accès <20> la fiche du siège</a>' ;
?>
</ td >
< td width = " 350 " class = " StyleInfoData " >
< ? php
if ( $etab [ 'Actif' ] == 1 )
echo 'Oui' ;
else {
echo '<b>NON</b>' ;
$dateCloture = str_replace ( '-' , '' , $etab [ 'DateClotEt' ]);
if ( $etab [ 'DateClotEt' ] <> '' )
echo " <i> (Fin d'activit<69> en " . WDate :: dateT ( 'Ymd' , 'm/Y' , $dateCloture ) . ')</i>' ;
}
if ( $etab [ 'Siren' ] * 1 <> 0 && preg_match ( '/AVISINSEE/i' , $_SESSION [ 'tabInfo' ][ 'droits' ]))
echo ' <a title="Voir l\'avis de situation correspondant de l\'INSEE" target="_blank" href="/?page=avis&siret=' . $siret . '">(Situation au répertoire SIRENE)</a>' ;
?>
</ td >
</ tr >
2009-08-05 09:14:20 +00:00
2009-08-05 13:58:55 +00:00
< ? php
//Situation Jurique + affichage date de radiation
$dateRadiation = '' ;
if ( isset ( $etab [ 'DateRadiation' ]) && $etab [ 'DateRadiation' ] != '' && $etab [ 'DateRadiation' ] != '0000-00-00' ){
$dateRadiation = WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'DateRadiation' ]));
}
2009-08-24 07:10:55 +00:00
$firephp -> log ( $etab [ 'SituationJuridique' ], 'SituationJuridique' );
2009-08-18 07:40:28 +00:00
2009-08-24 07:10:55 +00:00
if ( $etab [ 'SituationJuridique' ] == 'P' || $etab [ 'SituationJuridique' ][ 0 ] == 'R' || $_SESSION [ 'tabInfo' ][ 'mode_edition' ] == 1 )
2009-08-05 09:14:20 +00:00
{
?>
2009-08-05 14:56:53 +00:00
< tr >
2009-03-04 16:46:29 +00:00
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Situation juridique </ td >
2009-08-05 09:14:20 +00:00
< td width = " 350 " class = " StyleInfoData " >
2009-08-24 07:10:55 +00:00
< ? php
}
//Proc<6F> dure collective
if ( $etab [ 'SituationJuridique' ] == 'P' )
{
?>
2009-08-06 08:42:18 +00:00
< a href = " ./?page=annonces&siret=<?= $etab['Siret'] ?>&idEntreprise=<?= $idEntreprise ?> " >
2009-08-05 14:56:53 +00:00
< font color = " red " >< b > En proc & eacute ; dure collective </ b ></ font >
</ a >
< ? php if ( $dateRadiation != '' ){ ?> <br/>Radi<64> du RCS le <?php print $dateRadiation; } ?>
2009-08-05 09:14:20 +00:00
< ? php
2009-08-24 07:10:55 +00:00
} /* else {
if ( $dateRadiation != '' ){ ?> Radi<EFBFBD> du RCS le <?php print $dateRadiation; }
} */
//Radiation
if ( $etab [ 'SituationJuridique' ] == 'RR' )
{
?> Radi<64> du RCS <?php if($dateRadiation!=''){ ?> le <?php print $dateRadiation; }
} elseif ( $etab [ 'SituationJuridique' ] == 'RP' ){
?> Radiation publi<6C> e <?php if($dateRadiation!=''){ ?> le <?php print $dateRadiation; }
}
if ( $_SESSION [ 'tabInfo' ][ 'mode_edition' ] == 1 )
{
?>
2009-08-18 07:40:28 +00:00
< a href = " ./?page=saisie&siret=<?= $etab['Siret'] ?>&idEntreprise=<?= $idEntreprise ?> " > ( Edition ) </ a >
2009-08-05 09:14:20 +00:00
< ? php
2009-08-18 07:40:28 +00:00
}
2009-08-24 07:10:55 +00:00
if ( $etab [ 'SituationJuridique' ] == 'P' || $etab [ 'SituationJuridique' ][ 0 ] != 'R' || $_SESSION [ 'tabInfo' ][ 'mode_edition' ] == 1 )
2009-08-18 07:40:28 +00:00
{
2009-08-05 14:27:49 +00:00
?>
2009-08-05 09:14:20 +00:00
</ td >
2009-08-05 14:56:53 +00:00
</ tr >
2009-08-24 07:10:55 +00:00
< ? php
} // Fin Situation juridique
2009-08-05 09:14:20 +00:00
?>
2009-08-18 07:40:28 +00:00
2009-08-27 07:39:27 +00:00
</ table >
< h2 > Raison sociale & Coordonn<EFBFBD> es </ h2 >
< table >
< ? php
//Nom
$title = '' ;
if ( isset ( $etab [ 'NomLong' ]) && $etab [ 'NomLong' ] != '' && $etab [ 'NomLong' ] != $etab [ 'Nom' ] )
$title = $etab [ 'NomLong' ];
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Raison Sociale </ td >
< td width = " 350 " class = " StyleInfoData " title = " <?= $title ?> " >
< ? = $etab [ 'Nom' ]; if ( $etab [ 'Nom2' ] <> '' ) echo '<br/>' . $etab [ 'Nom2' ]; ?>
</ td >
</ tr >
< ? php
//Enseigne / Sigle
$titre = '' ;
if ( $etab [ 'Enseigne' ] != '' && $etab [ 'Sigle' ] != '' ){
$titre = 'Enseigne / Sigle' ;
$lib = $etab [ 'Enseigne' ] . ' / ' . $etab [ 'Sigle' ];
} elseif ( $etab [ 'Enseigne' ] != '' && $etab [ 'Sigle' ] == '' && $etab [ 'SigleLong' ] != '' ){
$titre = 'Enseigne / Sigle' ;
$lib = $etab [ 'Enseigne' ] . ' / ' . $etab [ 'SigleLong' ];
} elseif ( $etab [ 'Enseigne' ] != '' && $etab [ 'Sigle' ] == '' ){
$titre = 'Enseigne' ;
$lib = $etab [ 'Enseigne' ];
} elseif ( $etab [ 'Enseigne' ] == '' && $etab [ 'Sigle' ] != '' ){
$titre = 'Sigle' ;
$lib = $etab [ 'Sigle' ];
} elseif ( $etab [ 'Enseigne' ] == '' && $etab [ 'Sigle' ] == '' && $etab [ 'SigleLong' ] != '' ){
$titre = 'Sigle' ;
$lib = $etab [ 'SigleLong' ];
}
2009-08-05 13:58:55 +00:00
2009-08-27 07:39:27 +00:00
$title = '' ;
if ( isset ( $etab [ 'SigleLong' ]) && $etab [ 'SigleLong' ] != '' && $etab [ 'SigleLong' ] != $etab [ 'Sigle' ])
$title = $etab [ 'SigleLong' ];
2009-08-05 13:58:55 +00:00
2009-08-27 07:39:27 +00:00
if ( $titre != '' ) {
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " >
< ? = $titre ?>
</ td >
< td width = " 350 " class = " StyleInfoData " title = " <?= $title ?> " >< ? = $lib ?> </td>
</ tr >
< ? php
}
?>
< ? php
//Forme juridique
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Forme juridique </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $etab [ 'FJ' ] . ' : ' . strWsToHtml ( $etab [ 'FJ_lib' ]); ?>
< ? php
if ( isset ( $etab [ 'FJ2' ]) && $etab [ 'FJ2' ] != '' && isset ( $etab [ 'FJ2_Lib' ]) && $etab [ 'FJ2_Lib' ] != '' )
{
2009-08-05 13:58:55 +00:00
?>
2009-08-27 07:39:27 +00:00
< img src = " ./img/exclamation.png " title = " Forme jurique au RCS : <?= $etab['FJ2_Lib'] ?> (<?= $etab['FJ2'] ?>) " />
2009-08-05 13:58:55 +00:00
< ? php
}
?>
2009-08-27 07:39:27 +00:00
</ td >
</ tr >
< ? php
//Date d'immatriculation
$dateImmat = '' ;
if ( isset ( $etab [ 'DateImmat' ]) && $etab [ 'DateImmat' ] != '' && $etab [ 'DateImmat' ] != '0000-00-00' ){
$dateImmat = WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'DateImmat' ]));
}
if ( $dateImmat != '' ){
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Date d ' immatriculation </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $dateImmat ?> </td>
</ tr >
< ? php
}
?>
< ? php
//Date de cr<63> ation de l'entreprise
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Date de cr & eacute ; ation de l ' entreprise </ td >
< td width = " 350 " class = " StyleInfoData " >
2009-08-05 13:58:55 +00:00
< ? php
2009-08-27 07:39:27 +00:00
$dateCreationEn = str_replace ( '-' , '' , $etab [ 'DateCreaEn' ]);
if ( substr ( $dateCreationEn , - 2 ) * 1 == 0 )
echo WDate :: dateT ( 'Ymd' , 'm/Y' , $dateCreationEn );
else
echo WDate :: dateT ( 'Ymd' , 'd/m/Y' , $dateCreationEn );
2009-08-05 13:58:55 +00:00
?>
2009-08-27 07:39:27 +00:00
</ td >
</ tr >
< ? php
//Date de cr<63> ation de l'<27> tablissement
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Date de cr & eacute ; ation de l ' & eacute ; tablissement </ td >
< td width = " 350 " class = " StyleInfoData " >
2009-08-05 13:58:55 +00:00
< ? php
2009-08-27 07:39:27 +00:00
$dateCreationEt = str_replace ( '-' , '' , $etab [ 'DateCreaEt' ]);
if ( $dateCreationEt * 1 <> 0 ) {
if ( substr ( $dateCreationEt , - 2 ) * 1 == 0 )
echo WDate :: dateT ( 'Ymd' , 'm/Y' , $dateCreationEt );
else
echo WDate :: dateT ( 'Ymd' , 'd/m/Y' , $dateCreationEt );
} else echo 'N/C' ;
2009-08-05 13:58:55 +00:00
?>
2009-02-19 16:28:12 +00:00
</ td >
2009-08-27 07:39:27 +00:00
</ tr >
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Adresse </ td >
< td width = " 350 " class = " StyleInfoData " >
2009-03-04 16:46:29 +00:00
< ? php
2009-08-27 07:39:27 +00:00
if ( $etab [ 'AdresseRue' ] == '' ){ $voie = $etab [ 'Adresse2' ]; } else { $voie = $etab [ 'AdresseRue' ]; }
?>
< a href = " /?page=recherche&vue=list&formR[type]=ent&formR[numVoie]=<?=urlencode( $etab['AdresseNum'] )?>&formR[voie]=<?=urlencode( $voie )?>&formR[cpVille]=<?=urlencode( $etab['CP'] )?> " title = " Rechercher <20> partir de cette adresse " >
< p class = " adresse " >< ? php print $etab [ 'Adresse' ]; ?> </p>
2009-03-04 16:46:29 +00:00
< ? php
2009-08-27 07:39:27 +00:00
if ( preg_match ( '/CHEZ SOFRADOM/i' , $etab [ 'Adresse2' ]))
$etab [ 'Adresse2' ] = '<a title="Voir la fiche d\'identit<69> du domiciliataire de cette entreprise" href="/?page=identite&siret=42495045900018&idEntreprise=6720043">CHEZ SOFRADOM</a>' ;
//http://extranet.devlocal.com/?page=identite&siret=42495045900018&idEntreprise=6720043
if ( $etab [ 'Adresse2' ] <> '' )
print '<p class="adresse">' . $etab [ 'Adresse2' ] . '</p>' ;
?>
< ? php
$cp = $etab [ 'CP' ] * 1 ;
if ( $cp <> 0 )
print '<p class="adresse">' . $etab [ 'CP' ] . ' ' . strWsToHtml ( $etab [ 'Ville' ]) . '</p>' ;
if ( $etab [ 'Pays' ] <> '' && strtoupper ( substr ( $etab [ 'Pays' ], 0 , 3 )) <> 'FRA' )
print '<p class="adresse">' . strWsToHtml ( $etab [ 'Pays' ]) . '</p>' ;
?>
</ a >
</ td >
</ tr >
< ? php
//Zones prioritaires
//if (@$etab['GeoInfos']['ZUS']<>'NON' || @$etab['GeoInfos']['ZFU']<>'NON' || @$etab['GeoInfos']['ZRU']<>'NON' || @$etab['GeoInfos']['CUCS']<>'NON') {/* && trim(@$etab['GeoInfos']['NCUCS'])<>'')) {*/
2009-08-28 18:01:21 +00:00
if ( @ $etab [ 'GeoInfos' ][ 'ZUS' ] == 'OUI' || @ $etab [ 'GeoInfos' ][ 'ZFU' ] == 'OUI' || @ $etab [ 'GeoInfos' ][ 'ZRU' ] == 'OUI' || @ $etab [ 'GeoInfos' ][ 'CUCS' ] == 'OUI' || @ $etab [ 'GeoInfos' ][ 'ZRR' ] == 'OUI' || @ $etab [ 'GeoInfos' ][ 'AFR' ] == 'OUI' )
2009-08-27 07:39:27 +00:00
{
/* [ GeoInfos ] => Array
(
[ ZUS ] => OUI
[ NZUS ] => 1127020
[ ZFU ] => OUI
[ NZFU ] => 11270 ZF
[ CUCS ] => OUI
[ NCUCS ] => 1127020
) */
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Zones prioritaires </ td >
< td width = " 350 " class = " StyleInfoData " >
< ? php
if ( $etab [ 'GeoInfos' ][ 'ZUS' ] == 'OUI' ) echo '<a href="http://sig.ville.gouv.fr/Territoire/' . $etab [ 'GeoInfos' ][ 'NZUS' ] . '" target="_blank">ZUS n<> ' . $etab [ 'GeoInfos' ][ 'NZUS' ] . '</a><br/>' ;
//elseif ($etab['GeoInfos']['ZUS']=='NSP') echo 'Implantation en ZUS à vérifier<br/>';
if ( $etab [ 'GeoInfos' ][ 'ZFU' ] == 'OUI' ) echo '<a href="http://sig.ville.gouv.fr/Territoire/' . $etab [ 'GeoInfos' ][ 'NZFU' ] . '" target="_blank">ZFU n<> ' . $etab [ 'GeoInfos' ][ 'NZFU' ] . '</a><br/>' ;
//elseif ($etab['GeoInfos']['ZFU']=='NSP') echo 'Implantation en ZFU à vérifier<br/>';
if ( $etab [ 'GeoInfos' ][ 'ZRU' ] == 'OUI' ) echo '<a href="http://sig.ville.gouv.fr/Territoire/' . $etab [ 'GeoInfos' ][ 'NZRU' ] . '" target="_blank">ZRU n<> ' . $etab [ 'GeoInfos' ][ 'NZRU' ] . '</a><br/>' ;
2009-08-31 17:19:43 +00:00
2009-08-28 17:59:36 +00:00
if ( $etab [ 'GeoInfos' ][ 'ZRR' ] == 'OUI' ) echo '<a href="http://www.diact.gouv.fr/IMG/Fichiers/Rural%20/ZRR/carte_zrr_20090409.pdf" target="_blank">ZRR n<> ' . $etab [ 'GeoInfos' ][ 'NZRR' ] . '</a><br/>' ;
2009-09-11 07:31:40 +00:00
if ( $etab [ 'GeoInfos' ][ 'AFR' ] == 'OUI' ) echo '<a href="http://www.diact.gouv.fr/IMG/Fichiers/AFR/com_fr_AFR0907.pdf" target="_blank">AFR n<> ' . $etab [ 'GeoInfos' ][ 'NAFR' ] . '</a><br/>' ;
2009-08-27 07:39:27 +00:00
//elseif ($etab['GeoInfos']['ZRU']=='NSP') echo 'Implantation en ZRU à vérifier<br/>';
if ( $etab [ 'GeoInfos' ][ 'CUCS' ] == 'OUI' ) echo '<a href="http://sig.ville.gouv.fr/Territoire/' . $etab [ 'GeoInfos' ][ 'NCUCS' ] . '" target="_blank">CUCS n<> ' . $etab [ 'GeoInfos' ][ 'NCUCS' ];
//elseif ($etab['GeoInfos']['CUCS']=='NSP') echo 'Implantation en CUCS à vérifier';
?>
</ td >
</ tr >
< ?
}
?>
< ? php
//T<> l<EFBFBD> phone
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > T & eacute ; l & eacute ; phone </ td >
< td width = " 350 " class = " StyleInfoData " >
< div class = " txtAdresse " >
< p >
< ? php
if ( trim ( $etab [ 'Tel' ]) == '' ) echo 'N/C' ;
else echo $etab [ 'Tel' ];
if ( $etab [ 'Enseigne' ] <> '' ) $libNom = urlencode ( $etab [ 'Enseigne' ]);
else $libNom = urlencode ( $etab [ 'Nom' ]);
$adresse = $etab [ 'Adresse' ];
$i_adr = 0 ;
while ( substr ( $adresse , 0 , 1 ) == '0' ) {
$i_adr ++ ;
$adresse = substr ( $adresse , 1 , strlen ( $adresse ) - 1 );
if ( $i_adr > 4 ) break ;
2009-02-19 16:28:12 +00:00
}
2009-08-27 07:39:27 +00:00
?>
< a title = " Rechercher le numéro de téléphone dans l'annuaire " target = " _blank " href = " http://local.search.ke.voila.fr/S/searchproxi?act=&nom=<?= $libNom ?>&adr=<?=urlencode(utf8_decode( $adresse ))?>&loc=<?=urlencode(utf8_decode( $etab['CP'] .' '. $etab['Ville'] ))?>&x=0&y=0&bhv=searchproxi&profil=enville&guidelocid=&guideregid=&guidedepid=&actid=&ke=&locid= " >
( Recherche annuaire ) </ a ></ p >
</ td >
</ tr >
< ?
//Fax
if ( $etab [ 'Fax' ] * 1 > 0 )
{
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Fax </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $etab [ 'Fax' ] ?> </td>
</ tr >
< ?
}
2009-06-17 12:13:33 +00:00
2009-08-27 07:39:27 +00:00
//Site web
if ( $siteWeb <> '' ) {
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Site Internet </ td >
< td width = " 350 " class = " StyleInfoData " >< a href = " <?= $siteWeb ?> " target = " _blank " >< ? = $siteWeb ?> </a></td>
</ tr >
< ?
}
2009-06-17 12:13:33 +00:00
2009-08-27 07:39:27 +00:00
//Email
if ( trim ( $etab [ 'Mail' ]) <> '' ) { ?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Courriel </ td >
< td width = " 350 " class = " StyleInfoData " >< a href = " mailto:<?= $etab['Mail'] ;?> " target = " _blank " >< ? = $etab [ 'Mail' ] ?> </a></td>
</ tr >
< ?
}
?>
</ table >
< h2 > Activit<EFBFBD> ( s ) & Chiffre d ' affaire </ h2 >
< ? php
//Activit<69> de l'entreprise
?>
< table >
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Activit & eacute ; de l ' entreprise </ td >
< td width = " 350 " class = " StyleInfoData " >
< ? php
if ( $etab [ 'Activite' ] <> '' && ! preg_match ( '/non pr(e|<7C> )cis(e|<7C> )/i' , utf8_decode ( $etab [ 'Activite' ]))) {
$texte = preg_replace_callback ( " /((?:[0-9] { 9,9})|(?:[0-9] { 3,3} [0-9] { 3,3} [0-9] { 3,3})|(?:[0-9] { 3,3} \ .[0-9] { 3,3} \ .[0-9] { 3,3})|(?:[0-9] { 3,3}-[0-9] { 3,3}-[0-9] { 3,3}))/ " , replace_siren , strWsToHtml ( $etab [ 'Activite' ]));
echo $texte . ' (' . $etab [ 'NafEnt' ] . ' : ' . strWsToHtml ( $etab [ 'NafEntLib' ]) . ')' ;
} else
echo $etab [ 'NafEnt' ] . ' : ' . strWsToHtml ( $etab [ 'NafEntLib' ]);
2009-08-05 09:14:20 +00:00
?>
2009-08-27 07:39:27 +00:00
</ td >
</ tr >
< ? php
//Activit<69> de l'<27> tablissement
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Activit & eacute ; de l ' & eacute ; tablissement </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $etab [ 'NafEtab' ] . ' : ' . strWsToHtml ( $etab [ 'NafEtabLib' ]); ?> </td>
</ tr >
< ? php
//NAF4
if ( preg_match ( '/NAF4/i' , $_SESSION [ 'tabInfo' ][ 'pref' ]) && trim ( @ $etab [ 'Naf4Ent' ]) <> '' ) {
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Anciens codes NAF </ td >
< td width = " 350 " class = " StyleInfoData " >< b > Entr . :& nbsp ; & nbsp ; </ b >< ? = $etab [ 'Naf4Ent' ] . ' - ' . strWsToHtml ( $etab [ 'Naf4EntLib' ]); ?> <br/><b>Étab. :</b> <?=$etab['Naf4Etab'].' - '. strWsToHtml($etab['Naf4EtabLib']);?></td>
</ tr >
< ? php
}
//Nature de l'activit<69>
$strActivite = '' ;
/* if ( $etab [ 'NatureActivite' ] * 1 > 0 && $etab [ 'NatureActivite' ] * 1 < 99 ) {
$tabNatureActivite = array ( 3 => 'Extraction' ,
4 => 'Fabrication, production' ,
5 => 'Montage, installation' ,
6 => 'R<> paration' ,
7 => 'Transport' ,
8 => 'Import, export' ,
9 => 'Commerce de gros ou interm<72> diaire du commerce' ,
10 => 'Commerce de d<> tail' ,
11 => 'Profession lib<69> rale' ,
12 => 'Services' ,
13 => 'Location de meubl<62> s' ,
14 => 'B<> timents, travaux publics' ,
15 => 'Services aux entreprises' ,
20 => 'Donneur d\'ordre' ,
);
$strActivite .= $tabNatureActivite [ $etab [ 'NatureActivite' ] * 1 ] . ' ' ;
} */
if ( /*trim($strActivite)<>''*/ $etab [ 'NatureActivite' ] == 1 && $etab [ 'Actif' ] == 1 )
{
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Nature de l ' activit<EFBFBD> </ td >
< td width = " 350 " class = " StyleInfoData " > Saisonni & egrave ; re </ td >
</ tr >
< ?
}
//Origine du fond
if ( ( $etab [ 'OrigineCreation' ] * 1 > 0 && $etab [ 'OrigineCreation' ] * 1 < 9 ) ||
$etab [ 'OrigineCreation' ] == 'A' || $etab [ 'OrigineCreation' ] == 'B' || $etab [ 'OrigineCreation' ] == 'C' ||
$etab [ 'OrigineCreation' ] == 'D' || $etab [ 'OrigineCreation' ] == 'E' )
{
$tabCreation = array ( 'a1' => 'Cr<43> ation' ,
'a3' => 'Achat' ,
'a4' => 'Apport' ,
'a6' => 'Prise en location g<> rance' ,
'a7' => 'Partage' ,
'a8' => 'Reprise' ,
'aA' => 'Reprise globale de l\'exploitation agricole' ,
'aB' => 'Poursuite de l\'exploitation agricole par le conjoint' ,
'aC' => 'Transfert de propri<72> t<EFBFBD> de l\'exploitation agricole' ,
'aD' => 'Apport d\'exploitation(s) agricole(s) individuelle(s)' ,
'aE' => 'Reprise d\'exploitation agricole individuelle' ,
);
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Origine du fonds </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $tabCreation [ 'a' . $etab [ 'OrigineCreation' ]] ?> </td>
</ tr >
< ? php
}
//Nombre d'<27> tablissements actif
if ( $etab [ 'NbEtab' ] <> 'N/C' )
{
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Nombre d ' & eacute ; tablissements actifs </ td >
< td width = " 350 " class = " StyleInfoData " >
< a title = " Voir la liste des établissements " href = " /?page=etablissements&siret=<?= $etab['Siret'] ?>&idEntreprise=<?= $idEntreprise ?> " >< ? = number_format ( $etab [ 'NbEtab' ] * 1 , null , null , ' ' ) ?> </a>
2009-08-05 09:14:20 +00:00
< ? php
2009-08-27 07:39:27 +00:00
if ( $etab [ 'NbEtab' ] * 1 > 1 )
2009-08-05 09:14:20 +00:00
{
2009-08-27 07:39:27 +00:00
?> <a title="Voir la liste des établissements" href="/?page=etablissements&siret=<?=$etab['Siret']?>&idEntreprise=<?=$idEntreprise?>">(Liste)</a>
2009-08-05 13:58:55 +00:00
< ? php
}
?>
2009-08-27 07:39:27 +00:00
</ td >
</ tr >
< ?
}
?>
< ? php
//Capital
if ( isset ( $etab [ 'Capital' ]) && $etab [ 'Capital' ] * 1 > 0 )
{
2009-08-05 13:58:55 +00:00
$title = '' ;
2009-08-27 07:39:27 +00:00
if ( isset ( $etab [ 'Bilan' ][ 'Capital' ])) $title .= 'Capital de ' . moneyKM ( $etab [ 'Bilan' ][ 'Capital' ]) . deviseText ( $etab [ 'Bilan' ][ 'Devise' ]);
2009-08-05 13:58:55 +00:00
if ( isset ( $etab [ 'Bilan' ][ 'Cloture' ])) $title .= ' au ' . WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'Bilan' ][ 'Cloture' ]));
2009-08-27 07:39:27 +00:00
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Capital < ? php if ( isset ( $etab [ 'CapitalType' ]) && $etab [ 'CapitalType' ] == 'V' ){ print 'variable' ;} ?> </td>
< td width = " 350 " class = " StyleInfoData " title = " <?= $title ?> " >< ? = number_format ( $etab [ 'Capital' ], 0 , ',' , ' ' ) ?>
< ? php
if ( $etab [ 'CapitalDev' ] == 'EUR' ) echo '€' ;
else {
echo $etab [ 'CapitalDev' ] . ' (' . strWsToHtml ( $etab [ 'CapitalLib' ]) . ')' ;
}
2009-08-05 13:58:55 +00:00
?>
2009-08-27 07:39:27 +00:00
</ td >
</ tr >
< ? php
}
?>
2009-08-05 13:58:55 +00:00
2009-08-27 07:39:27 +00:00
< ? php
//Chiffre d'affaire
$title = '' ;
if ( isset ( $etab [ 'Bilan' ][ 'CA' ])) $title .= 'Chiffre d\'affaire de ' . moneyKM ( $etab [ 'Bilan' ][ 'CA' ]) . deviseText ( $etab [ 'Bilan' ][ 'Devise' ]);
if ( isset ( $etab [ 'Bilan' ][ 'Resultat' ])) $title .= ' et R<> sultat de ' . moneyKM ( $etab [ 'Bilan' ][ 'Resultat' ]) . deviseText ( $etab [ 'Bilan' ][ 'Devise' ]);
if ( isset ( $etab [ 'Bilan' ][ 'Cloture' ])) $title .= ' au ' . WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'Bilan' ][ 'Cloture' ]));
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Chiffre d ' affaire </ td >
< td width = " 350 " class = " StyleInfoData " title = " <?= $title ?> " >
2009-08-05 13:58:55 +00:00
< ? php
2009-08-27 07:39:27 +00:00
if ( isset ( $etab [ 'Bilan' ][ 'CA' ]) && ( ! isset ( $etab [ 'TrancheCALib' ]) || $etab [ 'TrancheCALib' ] == 'N/C' ))
{
print moneyKM ( $etab [ 'Bilan' ][ 'CA' ]) . deviseText ( $etab [ 'Bilan' ][ 'Devise' ]) . ' au ' . WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'Bilan' ][ 'Cloture' ]));
} elseif ( isset ( $etab [ 'TrancheCALib' ]) && $etab [ 'TrancheCALib' ] != 'N/C' ){
print strWsToHtml ( $etab [ 'TrancheCALib' ]);
} else {
print 'N/C' ;
2009-08-05 13:58:55 +00:00
}
?>
2009-08-27 07:39:27 +00:00
</ td >
</ tr >
< ? php
//Principaux dirigeants
$dir1DateNaiss = '' ;
if ( isset ( $etab [ 'dir1DateNaiss' ]) && $etab [ 'dir1DateNaiss' ] != '' && $etab [ 'dir1DateNaiss' ] != '0000-00-00' ){
$dir1DateNaiss = WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'dir1DateNaiss' ]));
}
$dir1LieuNaiss = '' ;
if ( isset ( $etab [ 'dir1LieuNaiss' ]) && $etab [ 'dir1LieuNaiss' ] != '' ){
$dir1LieuNaiss = $etab [ 'dir1LieuNaiss' ];
}
$dir2DateNaiss = '' ;
if ( isset ( $etab [ 'dir2DateNaiss' ]) && $etab [ 'dir2DateNaiss' ] != '' && $etab [ 'dir2DateNaiss' ] != '0000-00-00' ){
$dir2DateNaiss = WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'dir2DateNaiss' ]));
}
$dir2LieuNaiss = '' ;
if ( isset ( $etab [ 'dir2LieuNaiss' ]) && $etab [ 'dir2LieuNaiss' ] != '' ){
$dir2LieuNaiss = $etab [ 'dir2LieuNaiss' ];
}
$dir1NaissText = '' ;
if ( $dir1DateNaiss != '' ) $dir1NaissText .= 'n<> (e) le ' . $dir1DateNaiss ;
if ( $dir1LieuNaiss != '' && $dir1NaissText != '' ) $dir1NaissText .= ' <20> ' . $dir1LieuNaiss ;
elseif ( $dir1LieuNaiss != '' && $dir1NaissText == '' ) $dir1NaissText .= 'n<> (e) <20> ' . $dir1LieuNaiss ;
$dir2NaissText = '' ;
if ( $dir2DateNaiss != '' ) $dir2NaissText .= 'n<> (e) le ' . $dir2DateNaiss ;
if ( $dir2LieuNaiss != '' && $dir2NaissText != '' ) $dir2NaissText .= ' <20> ' . $dir2LieuNaiss ;
elseif ( $dir2LieuNaiss != '' && $dir2NaissText == '' ) $dir2NaissText .= 'n<> (e) <20> ' . $dir2LieuNaiss ;
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Principaux Dirigeants </ td >
< td width = " 350 " class = " StyleInfoData " >
< div class = " txtAdresse " >
< p >< u >< b >< ? php print strWsToHtml ( ucfirst ( $etab [ 'dir1Titre' ])); ?> </b></u></p>
< p >
< ? php print strWsToHtml ( $etab [ 'dir1NomPrenom' ]); ?>
< ? php if ( $dir1NaissText != '' ){ ?> , <?php print $dir1NaissText; }?>
</ div >
< ? php
if ( $etab [ 'dir2Titre' ] <> '' ) {
?>
< br />
2009-05-27 15:56:34 +00:00
< div class = " txtAdresse " >
2009-08-27 07:39:27 +00:00
< p >< u >< b >< ? php print strWsToHtml ( ucfirst ( $etab [ 'dir2Titre' ])); ?> </b>:</u></p>
< p >< ? php print strWsToHtml ( $etab [ 'dir2NomPrenom' ]); ?>
< ? php if ( $dir2NaissText != '' ){ ?> , <?php print $dir2NaissText; }?>
2009-05-27 15:56:34 +00:00
</ div >
2009-03-04 16:46:29 +00:00
< ? php
2009-02-19 16:28:12 +00:00
}
2009-08-27 07:39:27 +00:00
?>
</ td >
</ tr >
< ? php
//Effectif
$title = '' ;
if ( isset ( $etab [ 'Bilan' ][ 'Effectif' ])) $title .= $etab [ 'Bilan' ][ 'Effectif' ] . ' salari<72> (s)' ;
if ( isset ( $etab [ 'Bilan' ][ 'Cloture' ])) $title .= ' au ' . WDate :: dateT ( 'Ymd' , 'd/m/Y' , str_replace ( '-' , '' , $etab [ 'Bilan' ][ 'Cloture' ]));
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Effectif de l ' entreprise </ td >
< td width = " 350 " class = " StyleInfoData " title = " <?= $title ?> " >
2009-03-04 16:46:29 +00:00
< ? php
2009-08-27 07:39:27 +00:00
if ( ( ! isset ( $etab [ 'Effectif' ]) || $etab [ 'Effectif' ] == 'N/C' || $etab [ 'Effectif' ] == 0 ) && isset ( $etab [ 'Bilan' ][ 'Effectif' ]))
{
print $title ;
} elseif ( isset ( $etab [ 'Effectif' ]) && $etab [ 'Effectif' ] != 'N/C' && $etab [ 'Effectif' ] != 0 ){
print number_format ( $etab [ 'Effectif' ] * 1 , null , null , ' ' ) . ' salari<72> (s)' ;
} else {
print 'N/C' ;
}
2009-03-04 16:46:29 +00:00
?>
2009-08-27 07:39:27 +00:00
</ td >
</ tr >
</ table >
< h2 > Localisation g<EFBFBD> ographique & Recherche presse </ h2 >
< table >
< ? php
//Information g<> ographique
function normaliseVoie ( $voie ) {
switch ( strtoupper ( $voie )) {
case 'BD' : case 'BVD' : return 'BOULEVARD' ; break ;
case 'AV' : case 'AVE' : return 'AVENUE' ; break ;
case 'PL' : case 'PLA' : return 'PLACE' ; break ;
case 'ESP' : return 'ESPLANADE' ; break ;
//- 8E__ARRONDISSEMENT
default ; return strtoupper ( $voie ); break ;
}
}
$ville = ' ' . trim ( preg_replace ( '/([0-9]|BILLANCOURT|SUR.SEINE| PERRET|ARRONDISSEMENT|_)/i' , ' ' , $etab [ 'Ville' ])) . ' ' ;
$ville = trim ( strtr ( $ville , array ( ' EME ' => '' , ' ER ' => '' )));
if ( preg_match ( '/MAPPY/i' , $_SESSION [ 'tabInfo' ][ 'pref' ]) &&
preg_match ( '/(LILLE|CAEN|RENNES|BAULE|NANTES|NANCY|STRASBOURG|LYON|BORDEAUX|GRENOBLE|MONTPELLIER|TOULOUSE|MARSEILLE|CANNES|NICE|PARIS|NEUILLY|LEVALLOIS|ASNIERES|COURBEVOIE|NANTERRE|REUIL|BOULOGNE|SEVRES|VERSAILLES|MONTROUGE|MOULINEAUX)/' , $ville ))
{
?>
< tr >
< td width = " 580 " colspan = " 3 " class = " StyleInfoData " >
< table >< tr >
< td width = " 340 " height = " 420 " >
< IFRAME src = " http://pro.mappy.com/BtoB/scoresdecisions/photo?photo.town=<?= $ville ?>;photo.way=<?=trim(strtr(normaliseVoie( $etab['AdresseVoie'] ).' '. $etab['AdresseRue'] , array( ' ST '=>' SAINT ',' STE '=>' SAINTE ', )))?>;photo.num=<?= $etab['AdresseNum'] *1?>;photo.postal_code=<?= $etab['CP'] ?> " width = " 340 " height = " 420 " scrolling = " no " frameborder = " 0 " ></ IFRAME >
</ td >
< td width = " 240 " >< b > Information g & eacute ; ographique :</ b >< br />
2009-03-05 11:24:33 +00:00
< ? if ( $etab [ 'GeoPrecis' ] > 0 ) { ?>
Latitude : < ? = htmlentities ( dec2dms ( $etab [ 'GeoLat' ]), null , 'ISO-8859-1' ) ?> (<?=$etab['GeoLat']?>)<br/>
Longitude : < ? = htmlentities ( dec2dms ( $etab [ 'GeoLon' ]), null , 'ISO-8859-1' ) ?> (<?=$etab['GeoLon']?>)<br/><? } ?>
2009-08-27 07:39:27 +00:00
< a href = " ./?page=referer&part=gmap&siret=<?= $siret ?>&url=http://maps.google.com/maps?f=q%26hl=fr%26geocode=%26q=<?= $etab['AdresseNum'] ?>,+<?=urlencode( $etab['AdresseVoie'] )?>+<?=urlencode( $etab['AdresseRue'] )?>,+<?= $etab['CP'] ?>+<?=urlencode( $etab['Ville'] )?> " target = " _blank " > Afficher l ' adresse sur Google Map & copy ; </ a >< br />
< br />
< b > Code commune / Rivoli :</ b >< br />
< ? = $etab [ 'Dept' ] . ' ' . $etab [ 'codeCommune' ] ?> / <?=$etab['Rivoli']?>
</ td >
</ tr ></ table >
</ td >
</ tr >
< ? php
} else {
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Information g & eacute ; ographique </ td >
< td width = " 350 " class = " StyleInfoData " >
< ? if ( $etab [ 'GeoPrecis' ] > 0 ) { ?>
Latitude : < ? = htmlentities ( dec2dms ( $etab [ 'GeoLat' ]), null , 'ISO-8859-1' ) ?> (<?=$etab['GeoLat']?>)<br/>
Longitude : < ? = htmlentities ( dec2dms ( $etab [ 'GeoLon' ]), null , 'ISO-8859-1' ) ?> (<?=$etab['GeoLon']?>)<br/><? } ?>
< a href = " ./?page=referer&part=gmap&siret=<?= $siret ?>&url=http://maps.google.com/maps?f=q%26hl=fr%26geocode=%26q=<?= $etab['AdresseNum'] ?>,+<?=urlencode( $etab['AdresseVoie'] )?>+<?=urlencode( $etab['AdresseRue'] )?>,+<?= $etab['CP'] ?>+<?=urlencode( $etab['Ville'] )?> " target = " _blank " > Afficher l ' adresse sur Google Map & copy ; </ a ></ td >
</ tr >
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 200 " class = " StyleInfoLib " > Code commune / Rivoli </ td >
< td width = " 350 " class = " StyleInfoData " >< ? = $etab [ 'Dept' ] . ' ' . $etab [ 'codeCommune' ] ?> / <?=$etab['Rivoli']?></td>
</ tr >
< ? php
}
?>
< tr >< td colspan = " 3 " >& nbsp ; </ td ></ tr >
< ?
//News
if ( preg_match ( '/NEWS/i' , $_SESSION [ 'tabInfo' ][ 'pref' ]))
{
/* Information presse 15 Aug 2007 09:21:49 GMT - */
require_once ( 'XML/RSS.php' );
$rss =& new XML_RSS ( 'http://news.google.fr/news?hl=fr&ned=fr&ie=ISO-8859-1&q=' . urlencode ( '"' . $etab [ 'Nom' ] . '"' ) . '&output=rss' );
$rss -> parse ();
$tabMonth = array ( 'Jan' => 1 , 'Feb' => 2 , 'Mar' => 3 , 'Apr' => 4 , 'May' => 5 , 'Jun' => 6 , 'Jul' => 7 , 'Aug' => 8 , 'Sep' => 9 , 'Oct' => 10 , 'Nov' => 11 , 'Dec' => 12 );
foreach ( $rss -> getItems () as $i => $item )
{
if ( $i == 0 )
{
?>
< tr >
< td width = " 30 " >& nbsp ; </ td >
< td width = " 550 " class = " StyleInfoLib " colspan = " 2 " > Information presse ( Source Google News & copy ;) < br />
< ul >
2009-03-04 16:46:29 +00:00
< ? php
}
2009-08-27 07:39:27 +00:00
$tmp = explode ( ', ' , $item [ 'pubdate' ]);
$tabDate = explode ( ' ' , $tmp [ 1 ]);
$tabTime = explode ( ':' , $tabDate [ 3 ]);
$pubDate = date ( 'd/m/Y <20> H:i' , gmmktime ( $tabTime [ 0 ] - 1 , $tabTime [ 1 ], $tabTime [ 2 ], $tabMonth [ $tabDate [ 1 ]], $tabDate [ 0 ], $tabDate [ 2 ]));
$titre = utf8_decode ( $item [ 'title' ]);
echo '<li><a href="' . $item [ 'link' ] . '" target="_blank">Le ' . $pubDate . " - $titre </a></li> " ;
$i ++ ; if ( $i == 15 ) break ;
}
if ( $i > 0 )
{
2009-03-04 16:46:29 +00:00
?>
2009-08-27 07:39:27 +00:00
</ ul ></ td ></ tr >
2009-05-27 15:56:34 +00:00
< ? php
2009-03-05 08:31:21 +00:00
}
2009-08-27 07:39:27 +00:00
}
?>
</ table >
< ? php
//Exportation des donn<6E> es sous forme de fichier
function htmldecode ( $value ){
$value = is_array ( $value ) ? array_map ( 'htmldecode' , $value ) : html_entity_decode ( $value , ENT_QUOTES , 'UTF-8' );
return $value ;
}
$tabTemp = htmldecode ( $etab );
$tabForExport [ 0 ] = $tabTemp ;
require_once 'export.php' ;
$array2csv = new ExportCSV ();
$array2csv -> records = $tabForExport ;
$array2csv -> writeCSV ( $fileName );
$array2xml = new ExportXML ();
$array2xml -> rootName = $page . 's' ;
$array2xml -> defaultTagName = $page ;
$array2xml -> records = $tabForExport ;
$array2xml -> writeXML ( $fileName );
?>
</ div >