1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Character encoding problems

Discussion in 'HTML & Website Design' started by tdd1984, Oct 20, 2007.

  1. #1
    Any one have character encoding problems on dreamhost?

    I change my meta tag to

    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">

    from utf-8 and not my characters are displaying fine before in firefox I'd have a diamond question mark on the ' and - symbols.

    I take it this is ok since this meta tag resolved the issue
    <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">

    I'm using zend to save my html files

    Any one have feedback or suggestions?
     
    tdd1984, Oct 20, 2007 IP
  2. Dan Schulz

    Dan Schulz Peon

    Messages:
    6,032
    Likes Received:
    436
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Use a server-side programming language like PHP and over-ride the server's character encoding by setting a HTTP-HEADER string at the top of your Web pages (this does not get displayed in the browser, but gets sent to it).
     
    Dan Schulz, Oct 20, 2007 IP
  3. tdd1984

    tdd1984 Well-Known Member

    Messages:
    2,357
    Likes Received:
    42
    Best Answers:
    0
    Trophy Points:
    150
    #3
    You have an example?
     
    tdd1984, Oct 20, 2007 IP
  4. Dan Schulz

    Dan Schulz Peon

    Messages:
    6,032
    Likes Received:
    436
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Not on-hand, but if you search in your search engine of choice, I'm sure you'll find one.
     
    Dan Schulz, Oct 20, 2007 IP
    buffalo likes this.
  5. hans

    hans Well-Known Member

    Messages:
    2,923
    Likes Received:
    126
    Best Answers:
    1
    Trophy Points:
    173
    #5
    by changing char enconding in meta tags does in NO way change the originally CREATED/saved/uploaded character encodings !!

    example
    if once you created/uploaded a UTF8 file and want it now to be ISO-8859-1 - then in addition to the change of meta tag you also need to CONVERT the entire file - ALL files -
    see
    http://www.kriyayoga.com/love_blog/post.php/224

    and you also should have the correct apache charset default config OR at least in your .htaccess

    such line would look like

    AddDefaultCharset utf-8

    or

    AddDefaultCharset ISO-8859-1

    changing existing charset from utf8 to OTHERS makes no real sense unless you KNOW why and have a good reason.

    if however you have problems using utf8 after host change OR machine change - a simple correction of the apache/.htaccess may solve your problem and serve all files correctly
    provided all files are correctly marked as the charset you actually created it with or CONVERTED it into.
     
    hans, Oct 21, 2007 IP
  6. Dan Schulz

    Dan Schulz Peon

    Messages:
    6,032
    Likes Received:
    436
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Won't do him a bit of good if his server is IIS or Xitami (though the principle is still the same - the implementations are worlds apart from what I understand). ;)
     
    Dan Schulz, Oct 21, 2007 IP
  7. hans

    hans Well-Known Member

    Messages:
    2,923
    Likes Received:
    126
    Best Answers:
    1
    Trophy Points:
    173
    #7
    whatever server he has
    changing meta tags for char encoding ALWAYS also requires CONVERTING the actual content-file by whatever tool available on HIS online and/OR offline system
     
    hans, Oct 21, 2007 IP
  8. tdd1984

    tdd1984 Well-Known Member

    Messages:
    2,357
    Likes Received:
    42
    Best Answers:
    0
    Trophy Points:
    150
    #8
    yes I fixed it I had to change the meta tag over to utf8 and save the document as a utf8 zend default does not save it as a utf 8
     
    tdd1984, Oct 21, 2007 IP
  9. Dan Schulz

    Dan Schulz Peon

    Messages:
    6,032
    Likes Received:
    436
    Best Answers:
    0
    Trophy Points:
    0
    #9
    Gah, I thought I had quoted the part referencing Apache. But yeah, you are right about the file itself. I was only referring to the part of the post that was talking about the Apache Web server itself.

    Sorry for the confusion.
     
    Dan Schulz, Oct 21, 2007 IP