SlideShare a Scribd company logo
1 of 33
Download to read offline
Schei�
     encoding
Codierungen und ähnliches
Schei�
                     encoding
                Codierungen und ähnliches



Andreas Heigl
@heiglandreas
Historisches


Anfänge

ASCII

ISO

Unicode
Anfänge



Lochkarten

Kein Bedarf für „Schrift“
ASCII


American Standard Code for Information
Interchange

1963 entstanden

7-Bit Zeichensatz (128 Zeichen)
ASCII

 0 1 2 3 4 5 6 7 8 9 A B C D E F
0
1
2
3
4   A B C D E F G H I J K L M N O
5 P Q R S T U VWX Y Z
6
7
ASCII

 0 1 2 3 4 5 6 7 8 9 A B C D E F
0
1
2
3
4   A B   C   D   E   F   G   H   I   J K L M N O
5 P Q R   S   T   U   V   W   X   Y   Z
6   a b   c   d   e   f   g   h   i   j k l m n o
7 p q r   s   t   u   v   w   x   y   z
ASCII

 0 1 2 3 4 5 6 7 8 9 A B C D E F
0
1
2
3 0 1 2 3 4   5   6   7   8   9
4   A B C D   E   F   G   H   I   J K L M N O
5 P Q R S T   U   V   W   X   Y   Z
6   a b c d   e   f   g   h   i   j k l m n o
7 p q r s t   u   v   w   x   y   z
ASCII

    0 1 2 3 4 5 6 7 8 9 A B C D E F
0
1
2       !   ”   #   $   %   &   ’   (   )   *   +   ,   -    .   /
3   0   1   2   3   4   5   6   7   8   9   :   ;   <   =   >    ?
4       A   B   C   D   E   F   G   H   I   J   K   L   M   N    O
5   P   Q   R   S   T   U   V   W   X   Y   Z   [      ]   ^    _
6   `   a   b   c   d   e   f   g   h   i   j   k   l   m   n    o
7   p   q   r   s   t   u   v   w   x   y   z   {   |   }   ~    .
ASCII

    0 1 2 3 4 5 6 7 8 9 A B C D E F
0
1
2       !   ”   #   $   %   &   ’   (   )   *   +   ,   -    .   /
3   0   1   2   3   4   5   6   7   8   9   :   ;   <   =   >    ?
4   @   A   B   C   D   E   F   G   H   I   J   K   L   M   N    O
5   P   Q   R   S   T   U   V   W   X   Y   Z   [      ]   ^    _
6   `   a   b   c   d   e   f   g   h   i   j   k   l   m   n    o
7   p   q   r   s   t   u   v   w   x   y   z   {   |   }   ~    .
ISO


International Standardisation Organisation

ASCII-Kompatibel

8-Bit Zeichensatz (256 Zeichen)
-1 Latin-1, Westeuropa     -9 Latin-5, Türkisch

-2 Latin-2, Mitteleuropa   -10 Latin-6, Nordisch

-3 Latin-3, Südeuropa      -11 Thai

-4 Latin-4, Nordeuropa     -12 - nicht existent

-5 Kyrillisch              -13 Latin-7, Baltisch

-6 Arabisch                -14 Latin-8, Keltisch

-7 Griechisch              -15 Latin-9, Westeuropäisch

-8 Hebräisch               -16 Latin-10, Südosteuropäisch
ISO-8859
-1 Latin-1, Westeuropa       -9 Latin-5, Türkisch

-2 Latin-2, Mitteleuropa     -10 Latin-6, Nordisch

-3 Latin-3, Südeuropa        -11 Thai

-4 Latin-4, Nordeuropa       -12 - nicht existent

-5 Kyrillisch                -13 Latin-7, Baltisch

-6 Arabisch                  -14 Latin-8, Keltisch

-7 Griechisch                -15 Latin-9, Westeuropäisch

-8 Hebräisch                 -16 Latin-10, Südosteuropäisch
ASCII

    0 1 2 3 4 5 6 7 8 9 A B C D E F
0
1
2       !   ”   #   $   %   &   ’   (   )   *   +   ,   -    .   /
3   0   1   2   3   4   5   6   7   8   9   :   ;   <   =   >    ?
4   @   A   B   C   D   E   F   G   H   I   J   K   L   M   N    O
5   P   Q   R   S   T   U   V   W   X   Y   Z   [      ]   ^    _
6   `   a   b   c   d   e   f   g   h   i   j   k   l   m   n    o
7   p   q   r   s   t   u   v   w   x   y   z   {   |   }   ~    .
ISO-8859-1

    0 1 2 3 4 5 6 7 8 9 A B C D E F
8
9
A   nbsp
           ¡   ¢   £   ¤   ¥   ¦   §   ¨   ©   ª   «   ¬   shy
                                                                 ®    ¯
B   °      ±   ²   ³   ´   µ   ¶   ·   ¸   ¹   º   »   ¼   ½     ¾    ¿
C   À      Á   Â   Ã   Ä   Å   Æ   Ç   È   É   Ê   Ë   Ì   Í     Î    Ï
D   Ð      Ñ   Ò   Ó   Ô   Õ   Ö   ×   Ø   Ù   Ú   Û   Ü   Ý     Þ    ß
E   à      á   â   ã   ä   å   æ   ç   è   é   ê   ë   ì   í      î   ï
F   ð      ñ   ò   ó   ô   õ   ö   ÷   ø   ù   ú   û   ü   ý     þ    ÿ
Andere Codierungen


MacRoman

WindowsLatin

...
Unicode

1991 (1988) entstanden

Multibyte Zeichensatz (z.Zt. 1.114.112
Zeichen)

ASCII/ISO-8859-1 Kompatibel

Unterschiedliche Codierungen (UTF-8,
UTF-16, UTF-32, EBCDIC, .... )
Unicode


U+0000 - U+10FFFF

U+0000 - U+007F -> ASCII

U+0080 - U+00FF -> ISO-8859-1

Verschiedene Codierungen möglich
UTF-32


jedes Zeichen 4 Byte lang

Einfach

Speicherintensiv
UTF-16
jedes Zeichen 2 Byte lang

Einfach

Codiert nur die meistgenutzten Zeichen aus
Unicode

Nur Zeichen von U+0000 bis U+FFFF möglich.

Big- oder LittleEndian?

MacOS-X, Windows, Java, .Net
UTF-8
jedes Zeichen zwischen 1 und 4 Byte lang

Streamsicher, da Start- und Folgezeichen
unterschieden werden

Alle Unicode-Zeichen codierbar und noch viel mehr
(bis zu 2^42 - 4.398.046.511.104)

Platzsparend, da oft nur 1 Byte gespeichert
werden muss (Lateinische Schriften)

Linux, IETF
UTF-8

Startbyte 0xxxxxxx oder 11xxxxxx

Folgebyte 10xxxxxx

0xxxxxxx für 1-Byte-Zeichen

1xxxxxxx für Mehr-Byte-Zeichen.

Die Anzahl der 1 zeigt die Anzahl der
Gesamt-Byte an
UTF-8

00-7F ein Byte langes Zeichen (ASCII)

80-BF 2., 3. oder 4. Byte einer mehrbyte-
Sequenz

C2-DF Start einer 2 Byte langen Sequenz

E0-EF Start einer 3 Byte langen Sequenz

F0-F4 Start einer 4 Byte langen Sequenz
UTF-8

     UTF-8       Binär   Unicode    Fehler

                         U+0079
y     0x79      01111001
                         01111001

    0xC3 0xA4   11000011 U+00E4
ä                                    ä
                10100100 11100100
Codierung und PHP



PHP ist NICHT Unicode-sicher

Warum ist das ein Problem?
Warum ist das ein
     Problem?
Kein Problem wenn NUR EINE ISO-8859-Variante
zum Einsatz kommt.

Internationale Seiten

Mehrsprachige Texte (da langt schon ein
griechisches Wort ...)

Mehrbyte-Zeichen und strlen?

Darstellung von einzelnen Zeichen eines MehrByte-
Zeichens (z.B. ä statt ä)
Codierung und PHP

mb_internal_encoding('UTF-8'); mb_http_input ('UTF-8'); mb_http_output ('UTF-8');
Content-type: text/html; charset=utf-8
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> und <form accept-
charset = "utf-8">
CREATE DATABASE ... DEFAULT CHARACTER SET utf8 COLLATE utf8 ... ENGINE ...
CHARSET=utf8 COLLATE=utf8_unicode_ci
SET NAMES 'utf8' COLLATE 'utf8_unicode_ci'
default_charset = UTF-8
mb_string Funktionen
mb-Reguläre Ausdrücke
u-Modifikator für preg-RegEx
mb_string

    MultiByte-Funktionen

    Ersetzen „normale“ String-Funktionen

    Ermöglichen den Umgang mit UTF-8


Überladen von Standard-Funktionen für Mail (1),
String (2) und RegEx-Funktionen (4) mittles
mbstring.overload = n
iconv
    Konvertierung aus beliebigem Zeichensatz
    nach z.B. UTF-8

<?php
$sourceEnc = mb_detect_encoding($string);
$targetEnc = ‘UTF8//TRANSLIT/ /IGNORE‘;
echo iconv($sourceEnc,$targetEnc,$string);
MySQL

Server        [mysqld]
              default-collation=utf8_bin
Client        character-set-server=utf8
              collation-server=utf8_bin
Verbindung    default-character-set=utf8
Datenbank
              [client]
Tabelle       default-character-set=utf8
Client   MySQL
(UTF-8)
   Ü
 C3 9C
           Verbindung
          (ISO-8859-1)
              Ü
             C3 9C        Server
                          (UTF-8)
                             Ü
                         C3 83 C2 9C
Resourcen

http://php.net/manual/de/
mbstring.overload.php

http://www.ibm.com/developerworks/library/
os-php-unicode/index.html

http://unicode.org

Google, Bing, Yahoo, .....
Fragen?

More Related Content

Featured

How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...DevGAMM Conference
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationErica Santiago
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellSaba Software
 
Introduction to C Programming Language
Introduction to C Programming LanguageIntroduction to C Programming Language
Introduction to C Programming LanguageSimplilearn
 

Featured (20)

How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 
ChatGPT webinar slides
ChatGPT webinar slidesChatGPT webinar slides
ChatGPT webinar slides
 
More than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike RoutesMore than Just Lines on a Map: Best Practices for U.S Bike Routes
More than Just Lines on a Map: Best Practices for U.S Bike Routes
 
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
Ride the Storm: Navigating Through Unstable Periods / Katerina Rudko (Belka G...
 
Barbie - Brand Strategy Presentation
Barbie - Brand Strategy PresentationBarbie - Brand Strategy Presentation
Barbie - Brand Strategy Presentation
 
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them wellGood Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
Good Stuff Happens in 1:1 Meetings: Why you need them and how to do them well
 
Introduction to C Programming Language
Introduction to C Programming LanguageIntroduction to C Programming Language
Introduction to C Programming Language
 

Schei. encoding

  • 1. Schei� encoding Codierungen und ähnliches
  • 2. Schei� encoding Codierungen und ähnliches Andreas Heigl @heiglandreas
  • 5. ASCII American Standard Code for Information Interchange 1963 entstanden 7-Bit Zeichensatz (128 Zeichen)
  • 6. ASCII 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 3 4 A B C D E F G H I J K L M N O 5 P Q R S T U VWX Y Z 6 7
  • 7. ASCII 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 3 4 A B C D E F G H I J K L M N O 5 P Q R S T U V W X Y Z 6 a b c d e f g h i j k l m n o 7 p q r s t u v w x y z
  • 8. ASCII 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 3 0 1 2 3 4 5 6 7 8 9 4 A B C D E F G H I J K L M N O 5 P Q R S T U V W X Y Z 6 a b c d e f g h i j k l m n o 7 p q r s t u v w x y z
  • 9. ASCII 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 ! ” # $ % & ’ ( ) * + , - . / 3 0 1 2 3 4 5 6 7 8 9 : ; < = > ? 4 A B C D E F G H I J K L M N O 5 P Q R S T U V W X Y Z [ ] ^ _ 6 ` a b c d e f g h i j k l m n o 7 p q r s t u v w x y z { | } ~ .
  • 10. ASCII 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 ! ” # $ % & ’ ( ) * + , - . / 3 0 1 2 3 4 5 6 7 8 9 : ; < = > ? 4 @ A B C D E F G H I J K L M N O 5 P Q R S T U V W X Y Z [ ] ^ _ 6 ` a b c d e f g h i j k l m n o 7 p q r s t u v w x y z { | } ~ .
  • 12. -1 Latin-1, Westeuropa -9 Latin-5, Türkisch -2 Latin-2, Mitteleuropa -10 Latin-6, Nordisch -3 Latin-3, Südeuropa -11 Thai -4 Latin-4, Nordeuropa -12 - nicht existent -5 Kyrillisch -13 Latin-7, Baltisch -6 Arabisch -14 Latin-8, Keltisch -7 Griechisch -15 Latin-9, Westeuropäisch -8 Hebräisch -16 Latin-10, Südosteuropäisch
  • 13. ISO-8859 -1 Latin-1, Westeuropa -9 Latin-5, Türkisch -2 Latin-2, Mitteleuropa -10 Latin-6, Nordisch -3 Latin-3, Südeuropa -11 Thai -4 Latin-4, Nordeuropa -12 - nicht existent -5 Kyrillisch -13 Latin-7, Baltisch -6 Arabisch -14 Latin-8, Keltisch -7 Griechisch -15 Latin-9, Westeuropäisch -8 Hebräisch -16 Latin-10, Südosteuropäisch
  • 14. ASCII 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 ! ” # $ % & ’ ( ) * + , - . / 3 0 1 2 3 4 5 6 7 8 9 : ; < = > ? 4 @ A B C D E F G H I J K L M N O 5 P Q R S T U V W X Y Z [ ] ^ _ 6 ` a b c d e f g h i j k l m n o 7 p q r s t u v w x y z { | } ~ .
  • 15. ISO-8859-1 0 1 2 3 4 5 6 7 8 9 A B C D E F 8 9 A nbsp ¡ ¢ £ ¤ ¥ ¦ § ¨ © ª « ¬ shy ® ¯ B ° ± ² ³ ´ µ ¶ · ¸ ¹ º » ¼ ½ ¾ ¿ C À Á Â Ã Ä Å Æ Ç È É Ê Ë Ì Í Î Ï D Ð Ñ Ò Ó Ô Õ Ö × Ø Ù Ú Û Ü Ý Þ ß E à á â ã ä å æ ç è é ê ë ì í î ï F ð ñ ò ó ô õ ö ÷ ø ù ú û ü ý þ ÿ
  • 17. Unicode 1991 (1988) entstanden Multibyte Zeichensatz (z.Zt. 1.114.112 Zeichen) ASCII/ISO-8859-1 Kompatibel Unterschiedliche Codierungen (UTF-8, UTF-16, UTF-32, EBCDIC, .... )
  • 18. Unicode U+0000 - U+10FFFF U+0000 - U+007F -> ASCII U+0080 - U+00FF -> ISO-8859-1 Verschiedene Codierungen möglich
  • 19. UTF-32 jedes Zeichen 4 Byte lang Einfach Speicherintensiv
  • 20. UTF-16 jedes Zeichen 2 Byte lang Einfach Codiert nur die meistgenutzten Zeichen aus Unicode Nur Zeichen von U+0000 bis U+FFFF möglich. Big- oder LittleEndian? MacOS-X, Windows, Java, .Net
  • 21. UTF-8 jedes Zeichen zwischen 1 und 4 Byte lang Streamsicher, da Start- und Folgezeichen unterschieden werden Alle Unicode-Zeichen codierbar und noch viel mehr (bis zu 2^42 - 4.398.046.511.104) Platzsparend, da oft nur 1 Byte gespeichert werden muss (Lateinische Schriften) Linux, IETF
  • 22. UTF-8 Startbyte 0xxxxxxx oder 11xxxxxx Folgebyte 10xxxxxx 0xxxxxxx für 1-Byte-Zeichen 1xxxxxxx für Mehr-Byte-Zeichen. Die Anzahl der 1 zeigt die Anzahl der Gesamt-Byte an
  • 23. UTF-8 00-7F ein Byte langes Zeichen (ASCII) 80-BF 2., 3. oder 4. Byte einer mehrbyte- Sequenz C2-DF Start einer 2 Byte langen Sequenz E0-EF Start einer 3 Byte langen Sequenz F0-F4 Start einer 4 Byte langen Sequenz
  • 24. UTF-8 UTF-8 Binär Unicode Fehler U+0079 y 0x79 01111001 01111001 0xC3 0xA4 11000011 U+00E4 ä ä 10100100 11100100
  • 25. Codierung und PHP PHP ist NICHT Unicode-sicher Warum ist das ein Problem?
  • 26. Warum ist das ein Problem? Kein Problem wenn NUR EINE ISO-8859-Variante zum Einsatz kommt. Internationale Seiten Mehrsprachige Texte (da langt schon ein griechisches Wort ...) Mehrbyte-Zeichen und strlen? Darstellung von einzelnen Zeichen eines MehrByte- Zeichens (z.B. ä statt ä)
  • 27. Codierung und PHP mb_internal_encoding('UTF-8'); mb_http_input ('UTF-8'); mb_http_output ('UTF-8'); Content-type: text/html; charset=utf-8 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> und <form accept- charset = "utf-8"> CREATE DATABASE ... DEFAULT CHARACTER SET utf8 COLLATE utf8 ... ENGINE ... CHARSET=utf8 COLLATE=utf8_unicode_ci SET NAMES 'utf8' COLLATE 'utf8_unicode_ci' default_charset = UTF-8 mb_string Funktionen mb-Reguläre Ausdrücke u-Modifikator für preg-RegEx
  • 28. mb_string MultiByte-Funktionen Ersetzen „normale“ String-Funktionen Ermöglichen den Umgang mit UTF-8 Überladen von Standard-Funktionen für Mail (1), String (2) und RegEx-Funktionen (4) mittles mbstring.overload = n
  • 29. iconv Konvertierung aus beliebigem Zeichensatz nach z.B. UTF-8 <?php $sourceEnc = mb_detect_encoding($string); $targetEnc = ‘UTF8//TRANSLIT/ /IGNORE‘; echo iconv($sourceEnc,$targetEnc,$string);
  • 30. MySQL Server [mysqld] default-collation=utf8_bin Client character-set-server=utf8 collation-server=utf8_bin Verbindung default-character-set=utf8 Datenbank [client] Tabelle default-character-set=utf8
  • 31. Client MySQL (UTF-8) Ü C3 9C Verbindung (ISO-8859-1) Ãœ C3 9C Server (UTF-8) Ãœ C3 83 C2 9C

Editor's Notes

  1. \n
  2. \n
  3. \n
  4. \n
  5. ABC hat 26 Zeichen, sollte langen!\n
  6. Kleinbuchstaben auch noch\n
  7. Zahlen!\n
  8. Satzzeichen auch noch?\n
  9. Steuerzeichen f&amp;#xFC;r Drucker etc.\n\nSch.... ganz sch&amp;#xF6;n voll.\n\nUnd die Briten nerven weil es zwar ein Dollar-Zeichen, aber kein Pfund zeichen gibt. Und platzist auch nicht mehr.....\n
  10. \n
  11. Steuerzeichen f&amp;#xFC;r Drucker etc.\n\nSch.... ganz sch&amp;#xF6;n voll.\n\nUnd die Briten nerven weil es zwar ein Dollar-Zeichen, aber kein Pfund zeichen gibt. Und platzist auch nicht mehr.....\n
  12. Steuerzeichen f&amp;#xFC;r Drucker etc.\n\nSch.... ganz sch&amp;#xF6;n voll.\n\nUnd die Briten nerven weil es zwar ein Dollar-Zeichen, aber kein Pfund zeichen gibt. Und platzist auch nicht mehr.....\n
  13. Steuerzeichen f&amp;#xFC;r Drucker etc.\n\nSch.... ganz sch&amp;#xF6;n voll.\n\nUnd die Briten nerven weil es zwar ein Dollar-Zeichen, aber kein Pfund zeichen gibt. Und platzist auch nicht mehr.....\n
  14. Steuerzeichen f&amp;#xFC;r Drucker etc.\n\nSch.... ganz sch&amp;#xF6;n voll.\n\nUnd die Briten nerven weil es zwar ein Dollar-Zeichen, aber kein Pfund zeichen gibt. Und platzist auch nicht mehr.....\n
  15. Steuerzeichen f&amp;#xFC;r Drucker etc.\n\nSch.... ganz sch&amp;#xF6;n voll.\n\nUnd die Briten nerven weil es zwar ein Dollar-Zeichen, aber kein Pfund zeichen gibt. Und platzist auch nicht mehr.....\n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. \n
  27. \n
  28. \n
  29. \n
  30. \n
  31. \n
  32. \n
  33. \n