Jump to content

Creating html files from a text file with names


elitegosu

Recommended Posts

Hello everyone, I just started learning PHP and I can't figure out how to create multiple html files from a text file that has html names.

 

For example, my text file has these names:

 

Product1

Product2

Product3

Product4

 

How do I make php create Product1.html, Product2.html, Product3.html, Product4.html files?

 

I'm storing the file names in the array by using file('pagenames.txt') but I can't figure out how to create html pages from those txt file names. Can anyone please help, thanks in advance!

  • 2 weeks later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.