Python Forum
How do I turn a directory of HTML files into one CSV?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How do I turn a directory of HTML files into one CSV?
#2
Quote:prints all four filenames in the "filename" column
You put all of the file names in the list, not just one.
    lines = [[files, html]]
I would also suggest that you print the contents of the html variable after the for has finished, and see how many (or few)files it contains.
Reply


Messages In This Thread
RE: How do I turn a directory of HTML files into one CSV? - by woooee - Sep-21-2019, 04:04 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Filer and sort files by modification time in a directory tester_V 6 150 11 hours ago
Last Post: tester_V
  Loop through all files in a directory? Winfried 10 471 Apr-23-2024, 07:38 PM
Last Post: FortuneCoins
  uploading files from a ubuntu local directory to Minio storage container dchilambo 0 484 Dec-22-2023, 07:17 AM
Last Post: dchilambo
  change directory of save of python files akbarza 3 929 Jul-23-2023, 08:30 AM
Last Post: Gribouillis
  Using pyinstaller with .ui GUI files - No such file or directory error diver999 3 3,452 Jun-27-2023, 01:17 PM
Last Post: diver999
  Monitoring a Directory for new mkv and mp4 Files lastyle 3 1,676 May-07-2023, 12:33 PM
Last Post: deanhystad
  Tkinterweb (Browser Module) Appending/Adding Additional HTML to a HTML Table Row AaronCatolico1 0 949 Dec-25-2022, 06:28 PM
Last Post: AaronCatolico1
  Read directory listing of files and parse out the highest number? cubangt 5 2,417 Sep-28-2022, 10:15 PM
Last Post: Larz60+
  How to save files in a separate directory Scordomaniac 3 1,977 Mar-16-2022, 10:17 AM
Last Post: Gribouillis
  reading html and edit chekcbox to html jacklee26 5 3,112 Jul-01-2021, 10:31 AM
Last Post: snippsat

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020