IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Mise en page CSS Discussion :

Décalage vers le haut d'un div


Sujet :

CSS

  1. #1
    Membre confirmé
    Homme Profil pro
    Développeur informatique
    Inscrit en
    Février 2008
    Messages
    757
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Haute Garonne (Midi Pyrénées)

    Informations professionnelles :
    Activité : Développeur informatique
    Secteur : High Tech - Électronique et micro-électronique

    Informations forums :
    Inscription : Février 2008
    Messages : 757
    Points : 572
    Points
    572
    Par défaut Décalage vers le haut d'un div
    Bonjour,

    Je ne comprends pas pourquoi le champs "Voie" est décalé vers le haut par rapport aux champs "Numéro" et "Nom voie" alors que tous les éléments du css sont identiques aux autres ... même dans l'inspecteur de code du navigateur je ne trouve pas de différences !

    Si quelqu'un peut m'aider, je vous en remercie !

    Voici une copie d'écran qui montre le décalage du champs "voie" ainsi que de son label :
    Nom : Capture du 2016-07-17 14:21:57.png
Affichages : 1051
Taille : 10,4 Ko

    Voici le html de cette partie :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    <div class="container" ng-controller="clientCtrl">
    	<div id="firstRow" class="row">
    		<div class="col-sm-12" style="padding-right: 30px;">
    		<div id="nouveauClient" style="text-align: center;">Créer un
    			nouveau client</div>
    		<div id="panelNouveauClient">
    			<div class="encadre" style="height: 130px; min-width: 600px;">
    				<div style="text-align: center;">
    					<label style="color: #c7b988;">Identité</label><br />
    				</div>
    				<div>
    					<div id="tablesInlineBlock" style="width: 49%;">
    						<div id="tablesBlock">
    							<label>Nom</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 270px;">
    							<input id="nouveauClientNom" type="text" class="form-control"
    								ng-model="client_nom" style="width: 200px;" />
    						</div>
    					</div>
    					<div id="tablesInlineBlock" style="width: 50%;">
    						<div id="tablesBlock">
    							<label>Prénom</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 250px;">
    							<input type="text" class="form-control"
    								ng-model="client_prenom" style="width: 200px;" />
    						</div>
    					</div>
    				</div>
    			</div>
    			<div class="encadre" style="min-width: 600px;">
    				<div style="text-align: center;">
    					<label style="color: #c7b988;">Adresse</label><br />
    				</div>
    				<div>
    					<div id="tablesInlineBlock" style="width: 24%;">
    						<div id="tablesBlock">
    							<label>Numéro</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 60px;">
    							<input id="numVoie" type="text" class="form-control"
    								ng-model="client_numVoie" maxlength="8" style="width: 110px;" />
    						</div>
    					</div>
    					<div id="tablesInlineBlock" style="width: 30%;">
    						<div id="tablesBlock">
    							<label>Voie</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 170px;">
    							<select id="typeVoie" class="form-control"
    								ng-model="client_typeVoie" style="width: 150px;">
    								<option>Impasse</option>
    								<option>Route</option>
    								<option selected="selected">Rue</option>
    								<option>Autre</option>
    							</select>
    						</div>
    					</div>
    					<div id="tablesInlineBlock" style="width: 45%;">
    						<div id="tablesBlock">
    							<label>Nom voie</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 250px;">
    							<input id="nomVoie" type="text" class="form-control"
    								ng-model="client_nomVoie" />
    						</div>
    					</div>
    				</div>
    				<div>
    					<div id="tablesInlineBlock" style="width: 49%;">
    						<div id="tablesBlock">
    							<label>Code postal</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 90px;">
    							<input id="codePostal" type="text" class="form-control"
    								ng-model="client_codePostal" maxlength="5"
    								style="width: 110px;" />
    						</div>
    					</div>
    					<div id="tablesInlineBlock" style="width: 50%;">
    						<div id="tablesBlock">
    							<label>Ville</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 290px;">
    							<input id="ville" type="text" class="form-control"
    								ng-model="client_ville" style="width: 250px;" />
    						</div>
    					</div>
    				</div>
    			</div>
     
    			<div class="encadre" style="min-width: 600px;">
    				<div style="text-align: center;">
    					<label style="color: #c7b988;">Contacts</label><br />
    				</div>
    				<div>
    					<div id="tablesInlineBlock" style="width: 49%;">
    						<div id="tablesBlock">
    							<label>Email</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 270px;">
    							<input id="nouveauClientEmail" type="text" class="form-control"
    								ng-model="client_email" style="width: 200px;" />
    						</div>
    					</div>
    					<div id="tablesInlineBlock" style="width: 50%;">
    						<div id="tablesBlock">
    							<label>Téléphone</label>
    						</div>
    						<div id="tablesBlock" style="min-width: 250px;">
    							<input type="text" class="form-control"
    								ng-model="client_telephone" maxlength="10" style="width: 200px;" />
    						</div>
    					</div>
    				</div>
    			</div>
     
    			<span class="input-group-btn">
    				<button class="btn btn-default"
    					ng-click="nouveau_client(client_nom, client_prenom, client_email, client_telephone, client_numVoie, client_typeVoie, client_nomVoie, client_codePostal, client_ville);">
    					Ajouter client</button>
    			</span>
    		</div>
    		<table id="tableClients" class="table table-striped">
    			<thead>
    				<tr>
    					<th>Nom</th>
    					<th>Prénom</th>
    					<th>Adresse</th>
    					<th>Actions</th>
    				</tr>
    			</thead>
    			<tbody>
    				<tr ng-repeat="client in clients">
    					<td style="display: none;" ng-model="idClient">{{client.idClient}}</td>
    					<td>{{erreurs.message}}{{client.nom}}</td>
    					<td>{{client.prenom}}</td>
    					<td>{{client.adresse.numeroVoie + ", " +
    						client.adresse.typeVoie + " " + client.adresse.nomVoie + " " +
    						client.adresse.codePostal + " " + client.adresse.ville}}</td>
    					<td>
    						<button class="btn btn-default"
    							ng-click="modifier_client(client.idClient)">Modifier</button>
    						<button class="btn btn-danger"
    							ng-click="supprimer_client(client.idClient);">Supprimer</button>
    					</td>
    				</tr>
    		</table>
    	</div>
    </div>
    l'entête du fichier html :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    <!DOCTYPE html>
    <html ng-app="chezYenApp">
    <head>
    <meta charset="ISO-8859-1">
    <title>Gestion des clients</title>
    <link type="text/css" rel="stylesheet" href="../css/bootstrap.css" />
    <link type="text/css" rel="stylesheet" href="../css/bootstrap-theme" />
    <link type="text/css" rel="stylesheet" href="../css/header.css" />
    <script type="text/javascript" src="../js/jquery-2.2.0.js"></script>
    <script type="text/javascript" src="../js/angular.js"></script>
    <script type="text/javascript" src="../js/angular-route.js"></script>
    <script type="text/javascript" src="../js/gestion_clients.js"></script>
    <script type="text/javascript" src="../js/chezYenDirective.js"></script>
    <script
    	src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
    <script
    	src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
     
    <link rel="stylesheet"
    	href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
    <link rel="stylesheet"
    	href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css">
    <link type="text/css" rel="stylesheet" href="../css/gestion_clients.css" />
    <script>
    	$(document).ready(function() {
    		$("#nouveauClient").on('click', function() {
    			console.log("clicked");
    			$("#panelNouveauClient").slideToggle(600);
    		});
    	});
    </script>
    </head>
    et voici le fichier gestion_clients.css :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    @CHARSET "ISO-8859-1";
     
     
    body {
    	background-color: #0a0905;
    }
     
     
     
    #panelNouveauClient{
    	display:none;
    	margin-top:10px;
    	color:#fff8d7;
    }
     
    #nouveauClient {
    	min-width:600px;
    	background-color: #c7b988;
    	color:#0a0905;
    	-webkit-border-radius:25px;
        border-radius: 25px;
        border: 2px solid #c90016; 
    }
     
    .encadre {
    	-webkit-border-radius:25px;
        border-radius: 25px;
        border: 2px solid #fff8d7;
        padding: 20px;
        margin-bottom:10px;
    }
     
    #tablesInlineBlock {
    	display:inline-block;
    }
     
    #tablesBlock {
    	display:block;
    }
     
    #firstRow {
    	margin-top:50px;
    }
     
    .table-striped>tbody>tr:nth-child(even)>td, 
    .table-striped>tbody>tr:nth-child(even)>th {
       background-color: #fff8d7;
     }
     
     #tableClients {	
     	min-width:600px;
     	-webkit-border-radius:25px;
        margin-top:10px;
     }
     
     thead {
     	color:#c7b988;
        border: 2px solid #fff8d7; 
     }
     
     /* pop up de modification des données du client*/
     #fade { /*--Masque opaque noir de fond--*/
    	display: none; /*--masqué par défaut--*/
    	background: #000;
    	position: fixed; left: 0; top: 0;
    	width: 100%; height: 100%;
    	opacity: .80;
    	z-index: 9999;
    }
    .popup_block{
    	display: none; /*--masqué par défaut--*/
    	background: #fff;
    	padding: 20px;
    	border: 20px solid #ddd;
    	float: left;
    	font-size: 1.2em;
    	position: fixed;
    	top: 50%; left: 50%;
    	z-index: 99999;
    	/*--Les différentes définitions de Box Shadow en CSS3--*/
    	-webkit-box-shadow: 0px 0px 20px #000;
    	-moz-box-shadow: 0px 0px 20px #000;
    	box-shadow: 0px 0px 20px #000;
    	/*--Coins arrondis en CSS3--*/
    	-webkit-border-radius: 10px;
    	-moz-border-radius: 10px;
    	border-radius: 10px;
    }
    img.btn_close {
    	float: right;
    	margin: -55px -55px 0 0;
    }
    /*--Gérer la position fixed pour IE6--*/
    *html #fade {
    position: absolute;
    }
    *html .popup_block {
    position: absolute;
    }
    OS : LinuxMint 20

  2. #2
    Invité
    Invité(e)
    Par défaut
    Bonjour,

    dans le forum CSS, le code dynamique n'a pas d'intérêt.

    Il faut montrer le code HTML généré, afin qu'on puisse tester.
    Ou mieux : la page en ligne.

  3. #3
    Membre confirmé
    Homme Profil pro
    Développeur informatique
    Inscrit en
    Février 2008
    Messages
    757
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Haute Garonne (Midi Pyrénées)

    Informations professionnelles :
    Activité : Développeur informatique
    Secteur : High Tech - Électronique et micro-électronique

    Informations forums :
    Inscription : Février 2008
    Messages : 757
    Points : 572
    Points
    572
    Par défaut
    Bonjour,

    Oui, c'est vrai que c'est mieux avec le code source de la page ! désolé :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
     
    <div class="encadre" style="min-width: 600px;">
    <div style="text-align: center;">
    	<label style="color: #c7b988;">Adresse</label><br />
    </div>
    <div>
    	<div id="tablesInlineBlock" style="width: 24%;">
    		<div id="tablesBlock">
    			<label>Numéro</label>
    		</div>
    		<div id="tablesBlock" style="min-width: 60px;">
    			<input id="numVoie" type="text" class="form-control"
    				ng-model="client_numVoie" maxlength="8" style="width: 110px;" />
    		</div>
    	</div>
    	<div id="tablesInlineBlock" style="width: 30%;">
    		<div id="tablesBlock">
    			<label>Voie</label>
    		</div>
    		<div id="tablesBlock" style="min-width: 170px;">
    			<select id="typeVoie" class="form-control"
    				ng-model="client_typeVoie" style="width: 150px;">
    				<option>Impasse</option>
    				<option>Route</option>
    				<option selected="selected">Rue</option>
    				<option>Autre</option>
    			</select>
    		</div>
    	</div>
    	<div id="tablesInlineBlock" style="width: 45%;">
    		<div id="tablesBlock">
    			<label>Nom voie</label>
    		</div>
    		<div id="tablesBlock" style="min-width: 250px;">
    			<input id="nomVoie" type="text" class="form-control"
    				ng-model="client_nomVoie" />
    		</div>
    	</div>
    </div>
    <div>
    	<div id="tablesInlineBlock" style="width: 49%;">
    		<div id="tablesBlock">
    			<label>Code postal</label>
    		</div>
    		<div id="tablesBlock" style="min-width: 90px;">
    			<input id="codePostal" type="text" class="form-control"
    				ng-model="client_codePostal" maxlength="5"
    				style="width: 110px;" />
    		</div>
    	</div>
    	<div id="tablesInlineBlock" style="width: 50%;">
    		<div id="tablesBlock">
    			<label>Ville</label>
    		</div>
    		<div id="tablesBlock" style="min-width: 290px;">
    			<input id="ville" type="text" class="form-control"
    				ng-model="client_ville" style="width: 250px;" />
    			</div>
    		</div>
    	</div>
    </div>

    Merci,
    OS : LinuxMint 20

  4. #4
    Modérateur

    Avatar de NoSmoking
    Homme Profil pro
    Inscrit en
    Janvier 2011
    Messages
    16 959
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Isère (Rhône Alpes)

    Informations forums :
    Inscription : Janvier 2011
    Messages : 16 959
    Points : 44 122
    Points
    44 122
    Par défaut
    Bonjour,
    trop de dépendances avec des CSS extérieurs pour bien ce rendre compte, toutefois une remarque, pourquoi cette imbrication de <div> pour des éléments dépendants, par exemple
    Code html : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    <div id="tablesInlineBlock" style="width: 24%;">
        <div id="tablesBlock">
            <label>Numéro</label>
        </div>
        <div id="tablesBlock" style="min-width: 60px;">
            <input id="numVoie" type="text" class="form-control" ng-model="client_numVoie" maxlength="8" style="width: 110px;" />
        </div>
    </div>

  5. #5
    Modérateur
    Avatar de Bisûnûrs
    Profil pro
    Développeur Web
    Inscrit en
    Janvier 2004
    Messages
    9 868
    Détails du profil
    Informations personnelles :
    Âge : 40
    Localisation : France, Rhône (Rhône Alpes)

    Informations professionnelles :
    Activité : Développeur Web

    Informations forums :
    Inscription : Janvier 2004
    Messages : 9 868
    Points : 16 258
    Points
    16 258
    Par défaut
    Tu feras gaffe aussi, dans le code mis en évidence par NoSmoking (entre autres), tu as deux id identiques. Il convient de nettoyer ton code pour avoir un rendu optimal et une base de travail sur laquelle on pourra t'aider sans faire de spéculations.

  6. #6
    Membre confirmé
    Homme Profil pro
    Développeur informatique
    Inscrit en
    Février 2008
    Messages
    757
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Haute Garonne (Midi Pyrénées)

    Informations professionnelles :
    Activité : Développeur informatique
    Secteur : High Tech - Électronique et micro-électronique

    Informations forums :
    Inscription : Février 2008
    Messages : 757
    Points : 572
    Points
    572
    Par défaut
    Bonjour,

    Je vous remercie pour vos remarques.

    C'est vrai que sans les CSS, difficile de se rendre compte donc les voici :
    Tout d'abord, le html avec les links css :

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    171
    172
    173
    174
    175
    176
    177
    178
    179
    180
    181
    182
    183
    184
    185
    186
    187
    188
    189
    190
    191
    192
    193
    194
    195
    196
    197
    198
    199
    200
    201
    202
    203
    204
    205
    206
    207
    208
    209
    210
    211
    212
    213
    214
    215
    216
    217
    218
    219
    220
    221
    222
    223
    224
    225
    226
    227
    228
    229
    230
    231
    232
    233
    234
    235
    236
    237
    238
    239
    240
    241
    242
    243
    244
    245
    246
    247
    248
    249
    250
    251
    252
    253
    254
    255
    256
    257
    258
    259
    260
    261
    262
    263
    264
    265
    266
    267
    268
    269
    270
    271
    272
    273
    274
    275
    276
    277
    278
    279
    280
    281
    282
    283
    284
    285
    286
    287
    288
    289
    290
    291
    292
    293
    294
    295
    296
    297
    298
    299
    300
    301
    302
    303
    304
    305
    306
    307
    308
    309
    310
    311
    312
    313
    314
    315
    316
    317
    318
    319
    320
    321
    322
    323
    324
    325
    326
    327
    328
    329
    330
    331
    332
    333
    334
    335
    336
    337
    338
    339
    340
    341
    342
    343
    344
    345
    346
    347
    348
    349
    350
    351
    352
    353
    354
    355
    356
    357
    358
    359
    360
    361
    362
    363
    364
    365
    366
    367
    368
    369
    370
    371
    372
    373
    374
    375
    376
    377
    378
    379
    380
    381
    382
    383
    384
    385
    386
    387
    388
    389
    390
    391
    392
    393
    394
    395
    396
    397
    398
    399
    400
    401
    402
    403
    404
    405
    406
    407
    408
    409
    410
    411
    412
    413
    414
    415
    416
    417
    418
    419
    420
    421
    422
    423
    424
    425
    426
    427
    428
    429
    <!DOCTYPE html>
    <html ng-app="chezYenApp">
    <head>
    <meta charset="ISO-8859-1">
    <title>Gestion des clients</title>
    <link type="text/css" rel="stylesheet" href="../css/bootstrap.css" />
    <link type="text/css" rel="stylesheet" href="../css/bootstrap-theme" />
    <link type="text/css" rel="stylesheet" href="../css/header.css" />
    <script type="text/javascript" src="../js/jquery-2.2.0.js"></script>
    <script type="text/javascript" src="../js/angular.js"></script>
    <script type="text/javascript" src="../js/angular-route.js"></script>
    <script type="text/javascript" src="../js/gestion_clients.js"></script>
    <script type="text/javascript" src="../js/chezYenDirective.js"></script>
    <script
    	src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
    <script
    	src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
     
    <link rel="stylesheet"
    	href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css"/>
    <link rel="stylesheet"
    	href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css"/>
    <link type="text/css" rel="stylesheet" href="../css/gestion_clients.css" />
    <script>
    	$(document).ready(function() {
    		$("#nouveauClient").on('click', function() {
    			console.log("clicked");
    			$("#panelNouveauClient").slideToggle(600);
    		});
    	});
    </script>
    </head>
    <body>
    	<div id="chezYenBar">
    		<img id="left" src="../images/logo_stylise.png"
    			class="img-responsive center-block" />
    		<div id="center">
    			<h3 style="color: #fff8d7;">
    				<a style="color: #fff8d7;" href="../index.html">ACCEUIL</a> /
    				GESTION CLIENTS
    			</h3>
    		</div>
    		<img id="right" src="../images/logo_stylise.png"
    			class="img-responsive center-block" />
    	</div>
    		<div class="container" ng-controller="clientCtrl">
    			<div id="firstRow" class="row">
    				<div class="col-sm-12" style="padding-right: 30px;">
    				<div id="nouveauClient" style="text-align: center;">Créer un nouveau client</div>
    				<div id="panelNouveauClient">
    					<div class="encadre" style="height: 130px; min-width: 600px;">
    						<div style="text-align: center;">
    							<label style="color: #c7b988;">Identité</label><br />
    						</div>
    						<div>
    							<div id="tablesInlineBlock" style="width: 49%;">
    								<div id="tablesBlock">
    									<label>Nom</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 270px;">
    									<input id="nouveauClientNom" type="text" class="form-control"
    										ng-model="client_nom" style="width: 200px;" />
    								</div>
    							</div>
    							<div id="tablesInlineBlock" style="width: 50%;">
    								<div id="tablesBlock">
    									<label>Prénom</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 250px;">
    									<input type="text" class="form-control"
    										ng-model="client_prenom" style="width: 200px;" />
    								</div>
    							</div>
    						</div>
    					</div>
    					<div class="encadre" style="min-width: 600px;">
    						<div style="text-align: center;">
    							<label style="color: #c7b988;">Adresse</label><br />
    						</div>
    						<div>
    							<div id="tablesInlineBlock" style="width: 24%;">
    								<div id="tablesBlock">
    									<label>Numéro</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 60px;">
    									<input id="numVoie" type="text" class="form-control"
    										ng-model="client_numVoie" maxlength="8" style="width: 110px;" />
    								</div>
    							</div>
    							<div id="tablesInlineBlock" style="width: 30%;">
    								<div id="tablesBlock">
    									<label>Voie</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 150px;">
    									<select id="typeVoie" class="form-control"
    										ng-model="client_typeVoie" style="width: 150px;">
    										<option>Impasse</option>
    										<option>Route</option>
    										<option selected="selected">Rue</option>
    										<option>Autre</option>
    									</select>
    								</div>
    							</div>
    							<div id="tablesInlineBlock" style="width: 45%;">
    								<div id="tablesBlock">
    									<label>Nom voie</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 250px;">
    									<input id="nomVoie" type="text" class="form-control"
    										ng-model="client_nomVoie" />
    								</div>
    							</div>
    						</div>
    						<div>
    							<div id="tablesInlineBlock" style="width: 49%;">
    								<div id="tablesBlock">
    									<label>Code postal</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 90px;">
    									<input id="codePostal" type="text" class="form-control"
    										ng-model="client_codePostal" maxlength="5"
    										style="width: 110px;" />
    								</div>
    							</div>
    							<div id="tablesInlineBlock" style="width: 50%;">
    								<div id="tablesBlock">
    									<label>Ville</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 290px;">
    									<input id="ville" type="text" class="form-control"
    										ng-model="client_ville" style="width: 250px;" />
    								</div>
    							</div>
    						</div>
    					</div>
     
    					<div class="encadre" style="min-width: 600px;">
    						<div style="text-align: center;">
    							<label style="color: #c7b988;">Contacts</label><br />
    						</div>
    						<div>
    							<div id="tablesInlineBlock" style="width: 49%;">
    								<div id="tablesBlock">
    									<label>Email</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 270px;">
    									<input id="nouveauClientEmail" type="email" class="form-control"
    										ng-model="client_email" style="width: 250px;" />
    								</div>
    							</div>
    							<div id="tablesInlineBlock" style="width: 50%;">
    								<div id="tablesBlock">
    									<label>Téléphone</label>
    								</div>
    								<div id="tablesBlock" style="min-width: 250px;">
    									<input type="text" class="form-control"
    										ng-model="client_telephone" maxlength="10" style="width: 200px;" />
    								</div>
    							</div>
    						</div>
    					</div>
     
    					<span class="input-group-btn">
    						<button class="btn btn-default"
    							ng-click="nouveau_client(client_nom, client_prenom, client_email, client_telephone, client_numVoie, client_typeVoie, client_nomVoie, client_codePostal, client_ville);">
    							Ajouter client</button>
    					</span>
    				</div>
    				<table id="tableClients" class="table table-striped">
    					<thead>
    						<tr>
    							<th>Nom</th>
    							<th>Prénom</th>
    							<th>Adresse</th>
    							<th>Actions</th>
    						</tr>
    					</thead>
    					<tbody>
    						<tr ng-repeat="client in clients">
    							<td style="display: none;" ng-model="idClient">{{client.idClient}}</td>
    							<td>{{erreurs.message}}{{client.nom}}</td>
    							<td>{{client.prenom}}</td>
    							<td>{{client.adresse.numeroVoie + ", " +
    								client.adresse.typeVoie + " " + client.adresse.nomVoie + " " +
    								client.adresse.codePostal + " " + client.adresse.ville}}</td>
    							<td>
    								<button class="btn btn-default"
    									ng-click="modifier_client(client.idClient)">Modifier</button>
    								<button class="btn btn-danger"
    									ng-click="supprimer_client(client.idClient);">Supprimer</button>
    							</td>
    						</tr>
    				</table>
    			</div>
    		</div>
     
    		<div id="popUpModif" class="popup_block" ng-model="clientModif">
    			<div style="text-align: center;">
    				<label style="color: #c7b988;">Identité</label><br />
    			</div>
    			<div>
    				<div id="tablesInlineBlock" style="width: 49%;">
    					<div id="tablesBlock" style="display: none">
    						<input type="text" class="form-control"
    							ng-model="clientModif.idClient" style="width: 200px;" />
    					</div>
    					<div id="tablesBlock">
    						<label>Nom</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 270px;">
    						<input type="text" class="form-control" ng-model="clientModif.nom"
    							style="width: 200px;" value="" />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 50%;">
    					<div id="tablesBlock">
    						<label>Prénom</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 250px;">
    						<input type="text" class="form-control"
    							ng-model="clientModif.prenom" style="width: 200px;" />
    					</div>
    				</div>
    			</div>
    			<div style="text-align: center;">
    				<label style="color: #c7b988;">Adresse</label><br />
    			</div>
    			<div>
    				<div id="tablesInlineBlock" style="width: 24%;">
    					<div id="tablesBlock">
    						<label>Numéro</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 60px;">
    						<input id="numVoie" type="text" class="form-control"
    							ng-model="clientModif.adresse.numeroVoie" maxlength="8"
    							style="width: 110px;" />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 30%;">
    					<div id="tablesBlock">
    						<label>Voie</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 170px;">
    						<select id="typeVoie" class="form-control"
    							ng-model="clientModif.adresse.typeVoie" style="width: 150px;">
    							<option>Impasse</option>
    							<option>Route</option>
    							<option selected="selected">Rue</option>
    							<option>Autre</option>
    						</select>
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 45%;">
    					<div id="tablesBlock">
    						<label>Nom voie</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 250px;">
    						<input id="nomVoie" type="text" class="form-control"
    							ng-model="clientModif.adresse.nomVoie" />
    					</div>
    				</div>
    			</div>
    			<div>
    				<div id="tablesInlineBlock" style="width: 49%;">
    					<div id="tablesBlock">
    						<label>Code postal</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 90px;">
    						<input id="codePostal" type="text" class="form-control"
    							ng-model="clientModif.adresse.codePostal" maxlength="5"
    							style="width: 110px;" />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 50%;">
    					<div id="tablesBlock">
    						<label>Ville</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 290px;">
    						<input id="ville" type="text" class="form-control"
    							ng-model="clientModif.adresse.ville" style="width: 250px;" />
    					</div>
    				</div>
    			</div>
    			<div style="text-align: center;">
    				<label style="color: #c7b988;">Contacts</label><br />
    			</div>
    			<div>
    				<div id="tablesInlineBlock" style="width: 49%;">
    					<div id="tablesBlock">
    						<label>Email</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 60px;">
    						<input id="email" type="email" class="form-control"
    							ng-model="clientModif.email"
    							style="width: 250px;" />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 50%;">
    					<div id="tablesBlock">
    						<label>Téléphone</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 60px;">
    						<input id="telephone" type="text" class="form-control"
    							ng-model="clientModif.telephone"
    							style="width: 110px;" />
    					</div>
    				</div>
    			</div>
    			<div style="margin-top: 15px">
    				<span class="input-group-btn">
    					<button id="validerModif" class="btn btn-success"
    						ng-click="valider_modification(
    					        				clientModif.idClient, 
    					        				clientModif.nom, 
    					        				clientModif.prenom,  
    					        				clientModif.email, 
    					        				clientModif.telephone,
    					        				clientModif.adresse.numeroVoie, 
    					        				clientModif.adresse.typeVoie, 
    					        				clientModif.adresse.nomVoie, 
    					        				clientModif.adresse.codePostal, 
    					        				clientModif.adresse.ville);">
    						Valider</button>
    					<button id="annulerModif" class="btn btn-warning"
    						style="margin-left: 15px">Annuler</button>
    				</span>
    			</div>
    		</div>
     
    		<div id="popUpSuppr" class="popup_block" ng-model="clientSuppr">
    			<div>
    				<H1 style="color: red; text-align: center;">Attention !
    					Suppression du client suivant :</H1>
    			</div>
    			<div style="text-align: center;">
    				<label style="color: #c7b988;">Identité</label><br />
    			</div>
    			<div>
    				<div id="tablesInlineBlock" style="width: 49%;">
    					<div id="tablesBlock" style="display: none">
    						<input type="text" class="form-control"
    							ng-model="clientSuppr.idClient" style="width: 200px;" readonly />
    					</div>
    					<div id="tablesBlock">
    						<label>Nom</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 270px;">
    						<input type="text" class="form-control" ng-model="clientSuppr.nom"
    							style="width: 200px;" readonly />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 50%;">
    					<div id="tablesBlock">
    						<label>Prénom</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 250px;">
    						<input type="text" class="form-control"
    							ng-model="clientSuppr.prenom" style="width: 200px;" readonly />
    					</div>
    				</div>
    			</div>
    			<div style="text-align: center;">
    				<label style="color: #c7b988;">Adresse</label><br />
    			</div>
    			<div>
    				<div id="tablesInlineBlock" style="width: 24%;">
    					<div id="tablesBlock">
    						<label>Numéro</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 60px;">
    						<input id="numVoie" type="text" class="form-control"
    							ng-model="clientSuppr.adresse.numeroVoie" maxlength="8"
    							style="width: 110px;" readonly />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 30%;">
    					<div id="tablesBlock">
    						<label>Voie</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 170px;">
    						<input id="numVoie" type="text" class="form-control"
    							ng-model="clientSuppr.adresse.typeVoie" style="width: 150px;"
    							readonly />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 45%;">
    					<div id="tablesBlock">
    						<label>Nom voie</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 250px;">
    						<input id="nomVoie" type="text" class="form-control"
    							ng-model="clientSuppr.adresse.nomVoie" readonly />
    					</div>
    				</div>
    			</div>
    			<div>
    				<div id="tablesInlineBlock" style="width: 49%;">
    					<div id="tablesBlock">
    						<label>Code postal</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 90px;">
    						<input id="codePostal" type="text" class="form-control"
    							ng-model="clientSuppr.adresse.codePostal" maxlength="5"
    							style="width: 110px;" readonly />
    					</div>
    				</div>
    				<div id="tablesInlineBlock" style="width: 50%;">
    					<div id="tablesBlock">
    						<label>Ville</label>
    					</div>
    					<div id="tablesBlock" style="min-width: 290px;">
    						<input id="ville" type="text" class="form-control"
    							ng-model="clientSuppr.adresse.ville" style="width: 250px;"
    							readonly />
    					</div>
    				</div>
    			</div>
    			<div style="margin-top: 15px">
    				<span class="input-group-btn">
    					<button class="btn btn-danger"
    						ng-click="valider_suppression(clientSuppr.idClient);">Supprimer</button>
    					<button id="annulerSuppr" class="btn btn-warning"
    						style="margin-left: 15px">Annuler</button>
    				</span>
    			</div>
    		</div>
    	</div>
    </body>
    </html>

    Puis les css liés :
    le header.css :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    @CHARSET "ISO-8859-1";
     
     
    #chezYenBar {
    	min-width:600px;
        width:100%;
        text-align:center;
        background-color: #0a0905;
    }
     
    #left {
        float:left;
        width:100px;
        padding-top:20px;
        padding-left:20px;
    }
     
    #center {
        display: inline-block;
        margin:0 auto;
      	vertical-align:middle;
      	margin-top:30px;
      	color:yellow;
    }
     
    #right {
        float:right;
        width:100px;
        padding-top:20px;
        padding-right:20px;
    }
    et gestionClients.css :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    @CHARSET "ISO-8859-1";
     
     
    body {
    	background-color: #0a0905;
    }
     
     
     
    #panelNouveauClient{
    	display:none;
    	margin-top:10px;
    	color:#fff8d7;
    }
     
    #nouveauClient {
    	min-width:600px;
    	background-color: #c7b988;
    	color:#0a0905;
    	-webkit-border-radius:25px;
        border-radius: 25px;
        border: 2px solid #c90016; 
    }
     
    .encadre {
    	-webkit-border-radius:25px;
        border-radius: 25px;
        border: 2px solid #fff8d7;
        padding: 20px;
        margin-bottom:10px;
    }
     
    #tablesInlineBlock {
    	display:inline-block;
    }
     
    #tablesBlock {
    	display:block;
    }
     
    #firstRow {
    	margin-top:50px;
    }
     
    .table-striped>tbody>tr:nth-child(even)>td, 
    .table-striped>tbody>tr:nth-child(even)>th {
       background-color: #fff8d7;
     }
     
     #tableClients {	
     	min-width:600px;
     	-webkit-border-radius:25px;
        margin-top:10px;
     }
     
     thead {
     	color:#c7b988;
        border: 2px solid #fff8d7; 
     }
     
     /* pop up de modification des données du client*/
     #fade { /*--Masque opaque noir de fond--*/
    	display: none; /*--masqué par défaut--*/
    	background: #000;
    	position: fixed; left: 0; top: 0;
    	width: 100%; height: 100%;
    	opacity: .80;
    	z-index: 9999;
    }
    .popup_block{
    	display: none; /*--masqué par défaut--*/
    	background: #fff;
    	padding: 20px;
    	border: 20px solid #ddd;
    	float: left;
    	font-size: 1.2em;
    	position: fixed;
    	top: 50%; left: 50%;
    	z-index: 99999;
    	/*--Les différentes définitions de Box Shadow en CSS3--*/
    	-webkit-box-shadow: 0px 0px 20px #000;
    	-moz-box-shadow: 0px 0px 20px #000;
    	box-shadow: 0px 0px 20px #000;
    	/*--Coins arrondis en CSS3--*/
    	-webkit-border-radius: 10px;
    	-moz-border-radius: 10px;
    	border-radius: 10px;
    }
    img.btn_close {
    	float: right;
    	margin: -55px -55px 0 0;
    }
    /*--Gérer la position fixed pour IE6--*/
    *html #fade {
    position: absolute;
    }
    *html .popup_block {
    position: absolute;
    }

    Au sujet des id multiples, je vais essayer d créer des classes à la place.

    Merci beaucoup !
    OS : LinuxMint 20

  7. #7
    Modérateur
    Avatar de Bisûnûrs
    Profil pro
    Développeur Web
    Inscrit en
    Janvier 2004
    Messages
    9 868
    Détails du profil
    Informations personnelles :
    Âge : 40
    Localisation : France, Rhône (Rhône Alpes)

    Informations professionnelles :
    Activité : Développeur Web

    Informations forums :
    Inscription : Janvier 2004
    Messages : 9 868
    Points : 16 258
    Points
    16 258
    Par défaut
    Bon, le code donné ne permet absolument pas de se rendre compte du problème, le résultat étant totalement différent de ce qui est présenté dans le premier post.

    S'il te plait, fais-nous un codepen qui représente ton problème :
    http://codepen.io/pen/

    (et tu verras, c'est souvent en mettant un code sur ce genre de site, morceau par morceau, qu'on se rend compte d'où vient le problème)

  8. #8
    Modérateur

    Avatar de NoSmoking
    Homme Profil pro
    Inscrit en
    Janvier 2011
    Messages
    16 959
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Isère (Rhône Alpes)

    Informations forums :
    Inscription : Janvier 2011
    Messages : 16 959
    Points : 44 122
    Points
    44 122
    Par défaut
    Je tenterais quand même une approche sur les éléments en id=tablesInlineBlock (à modifier bien sûr) en ajoutant la propriété vertical-align :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    .tablesInlineBlock {
        display:inline-block;
        vertical-align:top;
    }

  9. #9
    Membre confirmé
    Homme Profil pro
    Développeur informatique
    Inscrit en
    Février 2008
    Messages
    757
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Haute Garonne (Midi Pyrénées)

    Informations professionnelles :
    Activité : Développeur informatique
    Secteur : High Tech - Électronique et micro-électronique

    Informations forums :
    Inscription : Février 2008
    Messages : 757
    Points : 572
    Points
    572
    Par défaut
    Bonjour !

    UN grand merci pour vos aides.

    Le vertical-align n'a pas fonctionné.

    Et voici le codepen :
    http://codepen.io/francky74/pen/YWLAJz

    J'essaie encore mais franchement je suis à cours d'idées ....
    OS : LinuxMint 20

  10. #10
    Modérateur
    Avatar de Bisûnûrs
    Profil pro
    Développeur Web
    Inscrit en
    Janvier 2004
    Messages
    9 868
    Détails du profil
    Informations personnelles :
    Âge : 40
    Localisation : France, Rhône (Rhône Alpes)

    Informations professionnelles :
    Activité : Développeur Web

    Informations forums :
    Inscription : Janvier 2004
    Messages : 9 868
    Points : 16 258
    Points
    16 258
    Par défaut
    Visiblement ça vient d'un problème du display:block; sur le .form-control.

  11. #11
    Invité
    Invité(e)
    Par défaut
    Bonjour,

    il faudrait quand même que tu prennes en compte les CORRECTIONS qu'on te donne...

    Un ID doit être UNIQUE !

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    id="tablesInlineBlock"
    id="tablesBlock"
    ...
    Quand il y en a PLUSIEURS, on utilise des CLASS.
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    class="tablesInlineBlock"
    class="tablesBlock"
    ...
    Ensuite... beaucoup trop de <div> inutiles...


    Dernière modification par Invité ; 25/07/2016 à 09h22.

  12. #12
    Modérateur

    Avatar de NoSmoking
    Homme Profil pro
    Inscrit en
    Janvier 2011
    Messages
    16 959
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Isère (Rhône Alpes)

    Informations forums :
    Inscription : Janvier 2011
    Messages : 16 959
    Points : 44 122
    Points
    44 122
    Par défaut
    Le vertical-align n'a pas fonctionné.
    Je suis un peu surpris car si je remplace dans ton codePen les id="tablesInlineBlock" par des class="tablesInlineBlock" et les id="tablesBlock" par des class="tablesBlock" puis en modifiant le CSS comme suit
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    .tablesInlineBlock {
    	display:inline-block;
    	vertical-align:top;
    }
     
    .tablesBlock {
    	display:block;
    }
    je n'observe pas de « décalage » sur la ligne !

  13. #13
    Membre confirmé
    Homme Profil pro
    Développeur informatique
    Inscrit en
    Février 2008
    Messages
    757
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Haute Garonne (Midi Pyrénées)

    Informations professionnelles :
    Activité : Développeur informatique
    Secteur : High Tech - Électronique et micro-électronique

    Informations forums :
    Inscription : Février 2008
    Messages : 757
    Points : 572
    Points
    572
    Par défaut
    Bonjour,

    il faudrait quand même que tu prennes en compte les CORRECTIONS qu'on te donne...
    Oui, c'est vrai, je m'en excuse !

    Et en fait, en y réfléchissant bien c'est sûrement parce que je n'avais pas encore remplacé les identifiants par des class que le vertical-align que vous m'aviez proposé ne fonctionnait pas ....


    Bref, avec les classes et le verttical-align, ça fonctionne bien !


    J'ai même enlevé quelques <div> :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    171
    172
    173
    174
    175
    176
    177
    178
    179
    180
    181
    182
    183
    184
    185
    186
    187
    188
    189
    190
    191
    192
    193
    194
    195
    196
    197
    198
    199
    200
    201
    202
    203
    204
    205
    206
    207
    208
    209
    210
    211
    212
    213
    214
    215
    216
    217
    218
    219
    220
    221
    222
    223
    224
    225
    226
    227
    228
    229
    230
    231
    232
    233
    234
    235
    236
    237
    238
    239
    240
    241
    242
    243
    244
    245
    246
    247
    248
    249
    250
    251
    252
    253
    254
    255
    256
    257
    258
    259
    260
    261
    262
    263
    264
    265
    266
    267
    268
    269
    270
    271
    272
    273
    274
    275
    276
    277
    278
    279
    280
    281
    282
    283
    284
    285
    286
    287
    288
    289
    290
    291
    292
    293
    294
    295
    296
    297
    298
    299
    300
    301
    302
    303
    304
    305
    306
    307
    308
    309
    310
    311
    312
    313
    314
    315
    316
    317
    318
    319
    320
    321
    322
    323
    324
    325
    326
    327
    328
    329
    330
    331
    332
    333
    334
    335
    336
    337
    338
    339
    340
    341
    342
    343
    344
    345
    346
    347
    348
    349
    350
    351
    352
    353
    354
    355
    356
    357
    358
    359
    360
    361
    362
    363
    364
    365
    366
    367
    368
    369
    370
    371
    372
    373
    374
    375
    376
    377
    378
    379
    380
    381
    382
    383
    384
    385
    386
    387
    388
    389
    390
    391
    392
    393
    394
    395
    396
    397
    398
    399
    400
    401
    402
    403
    404
    405
    406
    407
    408
    409
    410
    411
    412
    413
    414
    415
    416
    417
    418
    419
    420
    421
    <!DOCTYPE html>
    <html ng-app="chezYenApp">
    <head>
    <meta charset="ISO-8859-1">
    <title>Gestion des clients</title>
    <link type="text/css" rel="stylesheet" href="../css/bootstrap.css" />
    <link type="text/css" rel="stylesheet" href="../css/bootstrap-theme" />
    <link type="text/css" rel="stylesheet" href="../css/header.css" />
    <script type="text/javascript" src="../js/jquery-2.2.0.js"></script>
    <script type="text/javascript" src="../js/angular.js"></script>
    <script type="text/javascript" src="../js/angular-route.js"></script>
    <script type="text/javascript" src="../js/gestion_clients.js"></script>
    <script type="text/javascript" src="../js/chezYenDirective.js"></script>
    <script
    	src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
    <script
    	src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
     
    <link rel="stylesheet"
    	href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css"/>
    <link rel="stylesheet"
    	href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css"/>
    <link type="text/css" rel="stylesheet" href="../css/gestion_clients.css" />
    <script>
    	$(document).ready(function() {
    		$("#nouveauClient").on('click', function() {
    			console.log("clicked");
    			$("#panelNouveauClient").slideToggle(600);
    		});
    	});
    </script>
    </head>
    <body>
    	<div id="chezYenBar">
    		<img id="left" src="../images/logo_stylise.png"
    			class="img-responsive center-block" />
    		<div id="center">
    			<h3 style="color: #fff8d7;">
    				<a style="color: #fff8d7;" href="../index.html">ACCEUIL</a> /
    				GESTION CLIENTS
    			</h3>
    		</div>
    		<img id="right" src="../images/logo_stylise.png"
    			class="img-responsive center-block" />
    	</div>
    	<div class="container" ng-controller="clientCtrl">
    		<div id="firstRow" class="row">
    			<div class="col-sm-12" style="padding-right: 30px;">
    			<div id="nouveauClient" style="text-align: center;">Créer un nouveau client</div>
    			<div id="panelNouveauClient">
    				<div class="encadre" style="height: 130px; min-width: 600px;">
    					<div style="text-align: center;">
    						<label style="color: #c7b988;">Identité</label><br />
    					</div>
    					<div>
    						<div class="tablesInlineBlock" style="width: 49%;">
    							<div class="tablesBlock">
    								<label>Nom</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 270px;">
    								<input id="nouveauClientNom" type="text" class="form-control"
    									ng-model="client_nom" style="width: 200px;" />
    							</div>
    						</div>
    						<div class="tablesInlineBlock" style="width: 50%;">
    							<div class="tablesBlock">
    								<label>Prénom</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 250px;">
    								<input type="text" class="form-control"
    									ng-model="client_prenom" style="width: 200px;" />
    							</div>
    						</div>
    					</div>
    				</div>
    				<div class="encadre" style="min-width: 600px;">
    					<div style="text-align: center;">
    						<label style="color: #c7b988;">Adresse</label><br />
    					</div>
    					<div>
    						<div class="tablesInlineBlock" style="width: 20%;">
    							<div class="tablesBlock">
    								<label>Numéro</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 60px;">
    								<input id="numVoie" type="text" class="form-control"
    									ng-model="client_numVoie" maxlength="8" style="width: 110px;" />
    							</div>
    						</div>
    						<div class="tablesInlineBlock" style="width: 44%;">
    							<div class="tablesBlock">
    								<label>Voie</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 150px;">
    								<select id="typeVoie" class="form-control"
    									ng-model="client_typeVoie" style="width: 150px;">
    									<option>Impasse</option>
    									<option>Route</option>
    									<option selected="selected">Rue</option>
    									<option>Autre</option>
    								</select>
    							</div>
    						</div>
    						<div class="tablesInlineBlock" style="width: 35%;">
    							<div class="tablesBlock">
    								<label>Nom voie</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 200px;">
    								<input id="nomVoie" type="text" class="form-control"
    									ng-model="client_nomVoie" style="width:100px;"/>
    							</div>
    						</div>
    					</div>
    					<div>
    						<div class="tablesInlineBlock" style="width: 49%;">
    							<div class="tablesBlock">
    								<label>Code postal</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 90px;">
    								<input id="codePostal" type="text" class="form-control"
    									ng-model="client_codePostal" maxlength="5"
    									style="width: 110px;" />
    							</div>
    						</div>
    						<div class="tablesInlineBlock" style="width: 50%;">
    							<div class="tablesBlock">
    								<label>Ville</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 290px;">
    								<input id="ville" type="text" class="form-control"
    									ng-model="client_ville" style="width: 250px;" />
    							</div>
    						</div>
    					</div>
    				</div>
     
    				<div class="encadre" style="min-width: 600px;">
    					<div style="text-align: center;">
    						<label style="color: #c7b988;">Contacts</label><br />
    					</div>
    					<div>
    						<div class="tablesInlineBlock" style="width: 49%;">
    							<div class="tablesBlock">
    								<label>Email</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 270px;">
    								<input id="nouveauClientEmail" type="email" class="form-control"
    									ng-model="client_email" style="width: 250px;" />
    							</div>
    						</div>
    						<div class="tablesInlineBlock" style="width: 50%;">
    							<div class="tablesBlock">
    								<label>Téléphone</label>
    							</div>
    							<div class="tablesBlock" style="min-width: 250px;">
    								<input type="text" class="form-control"
    									ng-model="client_telephone" maxlength="10" style="width: 200px;" />
    							</div>
    						</div>
    					</div>
    				</div>
     
    				<span class="input-group-btn">
    					<button class="btn btn-default"
    						ng-click="nouveau_client(client_nom, client_prenom, client_email, client_telephone, client_numVoie, client_typeVoie, client_nomVoie, client_codePostal, client_ville);">
    						Ajouter client</button>
    				</span>
    			</div>
    			<table id="tableClients" class="table table-striped">
    				<thead>
    					<tr>
    						<th>Nom</th>
    						<th>Prénom</th>
    						<th>Adresse</th>
    						<th>Actions</th>
    					</tr>
    				</thead>
    				<tbody>
    					<tr ng-repeat="client in clients">
    						<td style="display: none;" ng-model="idClient">{{client.idClient}}</td>
    						<td>{{erreurs.message}}{{client.nom}}</td>
    						<td>{{client.prenom}}</td>
    						<td>{{client.adresse.numeroVoie + ", " +
    							client.adresse.typeVoie + " " + client.adresse.nomVoie + " " +
    							client.adresse.codePostal + " " + client.adresse.ville}}</td>
    						<td>
    							<button class="btn btn-default"
    								ng-click="modifier_client(client.idClient)">Modifier</button>
    							<button class="btn btn-danger"
    								ng-click="supprimer_client(client.idClient);">Supprimer</button>
    						</td>
    					</tr>
    			</table>
    		</div>
    	</div>
     
    	<div id="popUpModif" class="popup_block" ng-model="clientModif">
    		<div style="text-align: center;">
    			<label style="color: #c7b988;">Identité</label><br />
    		</div>
    		<div>
    			<div class="tablesInlineBlock" style="width: 49%;">
    				<div class="tablesBlock" style="display: none">
    					<input type="text" class="form-control"
    						ng-model="clientModif.idClient" style="width: 200px;" />
    				</div>
    				<div class="tablesBlock">
    					<label>Nom</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 270px;">
    					<input type="text" class="form-control" ng-model="clientModif.nom"
    						style="width: 200px;" value="" />
    				</div>
    			</div>
    			<div class="tablesInlineBlock" style="width: 50%;">
    				<div class="tablesBlock">
    					<label>Prénom</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 250px;">
    					<input type="text" class="form-control"
    						ng-model="clientModif.prenom" style="width: 200px;" />
    				</div>
    			</div>
    		</div>
    		<div style="text-align: center;">
    			<label style="color: #c7b988;">Adresse</label><br />
    		</div>
    		<div>
    			<div class="tablesInlineBlock" style="width: 24%;">
    				<div class="tablesBlock">
    					<label>Numéro</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 60px;">
    					<input id="numVoie" type="text" class="form-control"
    						ng-model="clientModif.adresse.numeroVoie" maxlength="8"
    						style="width: 110px;" />
    				</div>
    			</div>
    			<div class="tablesInlineBlock" style="width: 30%;">
    				<div class="tablesBlock">
    					<label>Voie</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 170px;">
    					<select id="typeVoie" class="form-control"
    						ng-model="clientModif.adresse.typeVoie" style="width: 150px;">
    						<option>Impasse</option>
    						<option>Route</option>
    						<option selected="selected">Rue</option>
    						<option>Autre</option>
    					</select>
    				</div>
    			</div>
    			<div class="tablesInlineBlock" style="width: 45%;">
    				<div class="tablesBlock">
    					<label>Nom voie</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 250px;">
    					<input id="nomVoie" type="text" class="form-control"
    						ng-model="clientModif.adresse.nomVoie" />
    				</div>
    			</div>
    		</div>
    		<div>
    			<div class="tablesInlineBlock" style="width: 49%;">
    				<div class="tablesBlock">
    					<label>Code postal</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 90px;">
    					<input id="codePostal" type="text" class="form-control"
    						ng-model="clientModif.adresse.codePostal" maxlength="5"
    						style="width: 110px;" />
    				</div>
    			</div>
    			<div class="tablesInlineBlock" style="width: 50%;">
    				<div class="tablesBlock">
    					<label>Ville</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 290px;">
    					<input id="ville" type="text" class="form-control"
    						ng-model="clientModif.adresse.ville" style="width: 250px;" />
    				</div>
    			</div>
    		</div>
    		<div style="text-align: center;">
    			<label style="color: #c7b988;">Contacts</label><br />
    		</div>
    		<div>
    			<div class="tablesInlineBlock" style="width: 49%;">
    				<div class="tablesBlock">
    					<label>Email</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 60px;">
    					<input id="email" type="email" class="form-control"
    						ng-model="clientModif.email"
    						style="width: 250px;" />
    				</div>
    			</div>
    			<div class="tablesInlineBlock" style="width: 50%;">
    				<div class="tablesBlock">
    					<label>Téléphone</label>
    				</div>
    				<div class="tablesBlock" style="min-width: 60px;">
    					<input id="telephone" type="text" class="form-control"
    						ng-model="clientModif.telephone"
    						style="width: 110px;" />
    				</div>
    			</div>
    		</div>
    		<div style="margin-top: 15px">
    			<span class="input-group-btn">
    				<button id="validerModif" class="btn btn-success"
    					ng-click="valider_modification(
    				        				clientModif.idClient, 
    				        				clientModif.nom, 
    				        				clientModif.prenom,  
    				        				clientModif.email, 
    				        				clientModif.telephone,
    				        				clientModif.adresse.numeroVoie, 
    				        				clientModif.adresse.typeVoie, 
    				        				clientModif.adresse.nomVoie, 
    				        				clientModif.adresse.codePostal, 
    				        				clientModif.adresse.ville);">
    					Valider</button>
    				<button id="annulerModif" class="btn btn-warning"
    					style="margin-left: 15px">Annuler</button>
    			</span>
    		</div>
    	</div>
     
    	<div id="popUpSuppr" class="popup_block" ng-model="clientSuppr">
    		<H1 style="color: red; text-align: center;">Attention !
    			Suppression du client suivant :</H1>
    		<div style="text-align: center;">
    			<label style="color: #c7b988;">Identité</label><br />
    		</div>
    		<div class="tablesInlineBlock" style="width: 49%;">
    			<div class="tablesBlock" style="display: none">
    				<input type="text" class="form-control"
    					ng-model="clientSuppr.idClient" style="width: 200px;" readonly />
    			</div>
    			<div class="tablesBlock">
    				<label>Nom</label>
    			</div>
    			<div class="tablesBlock" style="min-width: 270px;">
    				<input type="text" class="form-control" ng-model="clientSuppr.nom"
    					style="width: 200px;" readonly />
    			</div>
    		</div>
    		<div class="tablesInlineBlock" style="width: 50%;">
    			<div class="tablesBlock">
    				<label>Prénom</label>
    			</div>
    			<div class="tablesBlock" style="min-width: 250px;">
    				<input type="text" class="form-control"
    					ng-model="clientSuppr.prenom" style="width: 200px;" readonly />
    			</div>
    		</div>
    		<div style="text-align: center;">
    			<label style="color: #c7b988;">Adresse</label><br />
    		</div>
    		<div class="tablesInlineBlock" style="width: 24%;">
    			<div class="tablesBlock">
    				<label>Numéro</label>
    			</div>
    			<div class="tablesBlock" style="min-width: 60px;">
    				<input id="numVoie" type="text" class="form-control"
    					ng-model="clientSuppr.adresse.numeroVoie" maxlength="8"
    					style="width: 110px;" readonly />
    			</div>
    		</div>
    		<div class="tablesInlineBlock" style="width: 30%;">
    			<div class="tablesBlock">
    				<label>Voie</label>
    			</div>
    			<div class="tablesBlock" style="min-width: 170px;">
    				<input id="numVoie" type="text" class="form-control"
    					ng-model="clientSuppr.adresse.typeVoie" style="width: 150px;"
    					readonly />
    			</div>
    		</div>
    		<div class="tablesInlineBlock" style="width: 45%;">
    			<div class="tablesBlock">
    				<label>Nom voie</label>
    			</div>
    			<div class="tablesBlock" style="min-width: 250px;">
    				<input id="nomVoie" type="text" class="form-control"
    					ng-model="clientSuppr.adresse.nomVoie" readonly />
    			</div>
    		</div>
    		<div class="tablesInlineBlock" style="width: 49%;">
    			<div class="tablesBlock">
    				<label>Code postal</label>
    			</div>
    			<div class="tablesBlock" style="min-width: 90px;">
    				<input id="codePostal" type="text" class="form-control"
    					ng-model="clientSuppr.adresse.codePostal" maxlength="5"
    					style="width: 110px;" readonly />
    			</div>
    		</div>
    		<div class="tablesInlineBlock" style="width: 50%;">
    			<div class="tablesBlock">
    				<label>Ville</label>
    			</div>
    			<div class="tablesBlock" style="min-width: 290px;">
    				<input id="ville" type="text" class="form-control"
    					ng-model="clientSuppr.adresse.ville" style="width: 250px;"
    					readonly />
    			</div>
    		</div>
    		<div style="margin-top: 15px">
    			<span class="input-group-btn">
    				<button class="btn btn-danger"
    					ng-click="valider_suppression(clientSuppr.idClient);">Supprimer</button>
    				<button id="annulerSuppr" class="btn btn-warning"
    					style="margin-left: 15px">Annuler</button>
    			</span>
    		</div>
    	</div>
    </div>
    </body>
    </html>
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    @CHARSET "ISO-8859-1";
     
    body {
    	background-color: #0a0905;
    }
     
    #panelNouveauClient{
    	display:none;
    	margin-top:10px;
    	color:#fff8d7;
    }
     
    #nouveauClient {
    	min-width:600px;
    	background-color: #c7b988;
    	color:#0a0905;
    	-webkit-border-radius:25px;
        border-radius: 25px;
        border: 2px solid #c90016; 
    }
     
    .encadre {
    	-webkit-border-radius:25px;
        border-radius: 25px;
        border: 2px solid #fff8d7;
        padding: 20px;
        margin-bottom:10px;
    }
     
    .tablesInlineBlock {
    	display:inline-block;
    	vertical-align:top;
    }
     
    .tablesBlock {
    	display:block;
    }
     
    #firstRow {
    	margin-top:50px;
    }
     
    .table-striped>tbody>tr:nth-child(even)>td, 
    .table-striped>tbody>tr:nth-child(even)>th {
       background-color: #fff8d7;
     }
     
     #tableClients {	
     	min-width:600px;
     	-webkit-border-radius:25px;
        margin-top:10px;
     }
     
     thead {
     	color:#c7b988;
        border: 2px solid #fff8d7; 
     }
     
     /* pop up de modification des données du client*/
     #fade { /*--Masque opaque noir de fond--*/
    	display: none; /*--masqué par défaut--*/
    	background: #000;
    	position: fixed; left: 0; top: 0;
    	width: 100%; height: 100%;
    	opacity: .80;
    	z-index: 9999;
    }
    .popup_block{
    	display: none; /*--masqué par défaut--*/
    	background: #fff;
    	padding: 20px;
    	border: 20px solid #ddd;
    	float: left;
    	font-size: 1.2em;
    	position: fixed;
    	top: 50%; left: 50%;
    	z-index: 99999;
    	/*--Les différentes définitions de Box Shadow en CSS3--*/
    	-webkit-box-shadow: 0px 0px 20px #000;
    	-moz-box-shadow: 0px 0px 20px #000;
    	box-shadow: 0px 0px 20px #000;
    	/*--Coins arrondis en CSS3--*/
    	-webkit-border-radius: 10px;
    	-moz-border-radius: 10px;
    	border-radius: 10px;
    }
    img.btn_close {
    	float: right;
    	margin: -55px -55px 0 0;
    }
    /*--Gérer la position fixed pour IE6--*/
    *html #fade {
    position: absolute;
    }
    *html .popup_block {
    position: absolute;
    }
    Je vous remercie de vos aides !
    OS : LinuxMint 20

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. Aligner vers le haut des div
    Par Lunassien dans le forum Mise en page CSS
    Réponses: 7
    Dernier message: 02/09/2015, 20h02
  2. [CSS 3] Transition d'un div du bas vers le haut de px à %
    Par Invité dans le forum Mise en page CSS
    Réponses: 1
    Dernier message: 28/09/2014, 12h14
  3. Problème de DIV et CSS, décalage vers la droite et en haut
    Par alexis1975 dans le forum Mise en page CSS
    Réponses: 1
    Dernier message: 06/05/2009, 18h58
  4. Décalage vers le haut :fonction Lag
    Par Niazov dans le forum SAS Base
    Réponses: 4
    Dernier message: 06/08/2008, 15h42
  5. scrollbar en haut de ma DIV
    Par kamalkam dans le forum Balisage (X)HTML et validation W3C
    Réponses: 3
    Dernier message: 31/05/2006, 16h44

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo