Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6596215
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T18:02:44+00:00 2026-05-25T18:02:44+00:00

I wrote a simple html parsing class in python and it seems to work

  • 0

I wrote a simple html parsing class in python and it seems to work fine and then I try to use it with django and I get this error:

'ascii' codec can't decode byte 0xc2 in position 54465: ordinal not in range(128)

which is strange because I added this: # encoding: utf-8 to the top of my class. I don’t really know much about encoding but can someone perhaps give me an idea of what’s going here? Btw, I also insured that the source html was already in utf-8. Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T18:02:45+00:00Added an answer on May 25, 2026 at 6:02 pm

    okay, I got it. All I needed to do was include # -*- coding: utf-8 -*- in the django view as well and that solved it!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to write Html format, but I can not even get a simple
I wrote simple custom validation on javascript based on this doc . I want
I wrote a simple Python script to download a web page for offline viewing.
I wrote a simple html file with just a javascript function. It worked in
I thought i had this unicode thing down. Then i realize i wasnt saving/parsing
I wrote a simple javascript function that creates a DOM object (in this case
I wrote the following simple javascript code <html xmlns=http://www.w3.org/1999/xhtml xml:lang=en lang=en> <head> <title>ajax</title> </head>
I try to use templatetags in django but I have trouble. I defined enumhelper.py
I have wrote this simple plugin which smooth scrolls the browser window and adds
I wrote a simple batch file as a PowerShell script, and I am getting

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.