php2html icon indicating copy to clipboard operation
php2html copied to clipboard

Set encoding when processing HTML

Open MojtabaMontazery opened this issue 6 years ago • 1 comments

Hello,

First of all, thank you for the tool.

I encountered this issue, and I fixed it by changing the line number 304:

    else:
      if(verbose):print("*****HTML Parsing: Everythings OK..Nothing to be done!!...skipped...");
    outfile=open(outfilepath,"w");
    outfile.write(data);

to

    else:
      if(verbose):print("*****HTML Parsing: Everythings OK..Nothing to be done!!...skipped...");
    outfile=open(outfilepath,"w",encoding="utf-8");
    outfile.write(data);

I think that might be something that you wan to consider.

PS: I am using Windows 10.

Regards,

Mojtaba

MojtabaMontazery avatar Oct 15 '19 09:10 MojtabaMontazery

you can make a pull request with your changes.

neurobin avatar Oct 15 '19 10:10 neurobin