Python Forum
Parsing a YAML file without changing the string content..?, Flask - solved.
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Parsing a YAML file without changing the string content..?, Flask - solved.
#2
I made some test and it the same with a simple

	
with open('test.txt', 'r') as file2:
  tyml = file2.read()

return render_template('index.html', TYML = tyml )
So either it's when I read the file with open or when I pass the variable to flask with render... humm Wall
[Image: NfRQr9R.jpg]
Reply


Messages In This Thread
RE: Parsing a YAML file without changing the string content..? - by SpongeB0B - Aug-05-2021, 07:19 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Error (Errno 2), File upload with the Flask framework and a public IP Username_Python1 0 285 Mar-28-2024, 01:46 PM
Last Post: Username_Python1
Question [SOLVED] Correct way to convert file from cp-1252 to utf-8? Winfried 8 914 Feb-29-2024, 12:30 AM
Last Post: Winfried
  [solved] list content check paul18fr 6 724 Jan-04-2024, 11:32 AM
Last Post: deanhystad
  Virtual Env changing mysql connection string in python Fredesetes 0 386 Dec-20-2023, 04:06 PM
Last Post: Fredesetes
  Need to replace a string with a file (HTML file) tester_V 1 778 Aug-30-2023, 03:42 AM
Last Post: Larz60+
Video doing data treatment on a file import-parsing a variable EmBeck87 15 2,916 Apr-17-2023, 06:54 PM
Last Post: EmBeck87
  Loop through json file and reset values [SOLVED] AlphaInc 2 2,151 Apr-06-2023, 11:15 AM
Last Post: AlphaInc
  Changing the initial worksheet name in an MS Excel file azizrasul 3 970 Oct-02-2022, 07:56 PM
Last Post: azizrasul
  Changing file location azizrasul 6 1,316 Sep-28-2022, 01:01 AM
Last Post: azizrasul
  [SOLVED] [BeautifulSoup] Why does it turn inserted string's brackets into </>? Winfried 0 1,536 Sep-03-2022, 11:21 PM
Last Post: Winfried

Forum Jump:

User Panel Messages

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