I wanted to place in the center of the screen (horizontally) the text "hello!". I remember that before justify-content-center
it worked for me but now I can't position it. But the condition is that the column is 12, that could not be modified.
<html>
<head>
<meta charset="UTF-8">
<title></title>
<!--<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css" integrity="sha384-Vkoo8x4CGsO3+Hhxv8T/Q5PaXtkKtu6ug5TOeNV6gBiFeWPGFN9MuhOf23Q9Ifjh" crossorigin="anonymous">-->
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
<link rel="stylesheet" href="estilos.css?<?php echo date('l jS \of F Y h:i:s A'); ?>" />
</head>
<body>
<div class="container-fluid ">
<div class="row d-flex">
<div class="col-12 justify-content-center bg-danger">
<h3>hola!</h3>
</div>
</div>
</div>
</body>
</html>
I add this answer as a correction to @masterguru's answer
The correction should be to
div
and not toh3
as suggested, because when you have more elements inside, things change. And I suppose that what the OP indicated, is the style to the div, not to the h3.CENTER DIV
CENTER H3