Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

192
Vistas
How can i do that if a change DIV element in one file it changes automatically in all other html file

I have a area for recent post in my website. It is same on all webpages of my website and even on same location. I want something that if i change it in 1 file it automatically updates in all other html files. I am using github to host my website.

<div class="recent">
            <h3>Recent Post</h3>
            <div class="post1">
                <a href="sanandrease.html">
                    <img src="images/sanandrease.jpeg" id="img1">
                    <p class="text1">Grand Theft Auto : San Andrease | Free Download | Highly Compressed </p>
                </a>
            </div>
        
        <div class="post2">
                <a href="gta3.html">
                    <img src="images/gta3.jpeg" id="img2">
                    <p class="text3">Grand Theft Auto 3 | Free <br>Download | Highly Compressed </p>
                </a>
            </div>
        
            <div class="post3">
                <a href="gta4.html">
                    <img src="images/gta4.jpeg" id="img3">
                    <p class="text3">Grand Theft Auto 4 | Free <br>Download | Highly Compressed </p>
                </a>
            </div>
        </div>
about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

You could use search and replace with Notepad++ where you specifiy the workspace (the folders where this could apply to).

Python (any os) For those using Python 3.5+ you can now use a glob recursively with the use of ** and the recursive flag.

Here's an example replacing hello with world for all .txt files:

for filepath in glob.iglob('./**/*.txt', recursive=True): with open(filepath) as file: s = file.read() s = s.replace('hello', 'world') with open(filepath, "w") as file: file.write(s)

In linux you could use this: rpl

For most quick uses, you may find the command rpl is much easier to remember.

Replace foo with bar on all .txt files: rpl -v foo bar '*.txt'

Simulate replacing the regex foo.* with bar in all .txt files recursively: rpl --dry-run 'foo.*' bar '**/*.txt'

You'll probably need to install it (apt-get install rpl or similar).

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda