PHP and HTML: Style sheet does not react

0

An apology, my style sheet is not working at all. Even, I send the style very different in a php and in the html. Exactly with the same code, same sheet, but it gives it to me differently. Here I will leave images so that they can see what it does. It's all the same, just change the extension. Also, I modify something of the style sheet and this modification has no effect, especially in php.

Here is the .php

Here is the .html

* Both have the same code

    
asked by Esteban Trevino Zwingil 18.08.2018 в 07:34
source

2 answers

0
  • Use right click on the browser.
  • Select Inspecionar Elemento .
  • In this part you will see things like this:

    <div id="" select class=" form" control" element (etc...) >elemetos</div>
    

    If you are autogenerating the TEXTO with PHP if it is, it would be better to use \" or \' to delimit

    It also adds part of the code

        
    answered by 18.08.2018 в 17:29
    0

    Option 1: Change the name of the .css files (eliminating the spaces, you can put a low script in its place).

    <link rel="stylesheet" href="estilos_de_nav.css">
    <link rel="stylesheet" href="estilos_de_busqueda.css">
    <link rel="stylesheet" href="estilo_de_resultados.css">
    

    Option 2: That you are calling the files and you are on a different route. If you have the files in a folder, for example css you must put the name of the folder, diagonal and the name of the file.

    <link rel="stylesheet" href="css/estilos_de_nav.css">
    <link rel="stylesheet" href="css/estilos_de_busqueda.css">
    <link rel="stylesheet" href="css/estilo_de_resultados.css">
    

    Option 3: You make the call from a subfolder where the file is not found, in that case you must put ../ to indicate that a folder must go before and then, depending on whether the file is in that folder, place the name of the folder. file or the name of the folder and then the name of the file.

    //En caso de que se encuentre en la carpeta anterior
    <link rel="stylesheet" href="../estilos_de_nav.css">
    <link rel="stylesheet" href="../estilos_de_busqueda.css">
    <link rel="stylesheet" href="../estilo_de_resultados.css">
    
    //En caso de que se encuentre en una sub-carpeta
    <link rel="stylesheet" href="../css/estilos_de_nav.css">
    <link rel="stylesheet" href="../css/estilos_de_busqueda.css">
    <link rel="stylesheet" href="../css/estilo_de_resultados.css">
    

    In the href you must go the exact path where the file is located, to know if you are doing the right clicks ctrl+u on the page where you have the problem, look for the link of any .css and enter, if it comes out to you that does not exist is because the .css file is not well linked.

        
    answered by 18.08.2018 в 21:12