| 
   
   | 
    | 
  
   
    
mysqli_character_set_name    (PHP 5) mysqli_character_set_name     (no version information, might be only in CVS) mysqli->character_set_name -- Returns the default character set for the database connection DescriptionProcedural style: string  mysqli_character_set_name ( mysqli link ) Object oriented style (method): class  mysqli {  string  character_set_name ( void  ) } 
   Returns the current character set for the database connection specified by the
   link parameter.
   Возвращаемые значенияThe default character set for the current connection ПримерыПример 1. Object oriented style | 
 
<?php 
$mysqli = new mysqli("localhost", "my_user", "my_password", "world"); 
                                                                               
if (mysqli_connect_errno()) { 
    printf("Connect failed: %s\n", mysqli_connect_error()); 
    exit(); 
} 
 
$charset = $mysqli->character_set_name(); 
printf ("Current character set is %s\n", $charset); 
 
$mysqli->close(); 
?>
  |  
  |  
 Пример 2. Procedural style | 
 
<?php 
$link = mysqli_connect("localhost", "my_user", "my_password", "world"); 
                                                                               
if (!$link) { 
    printf("Connect failed: %s\n", mysqli_connect_error()); 
    exit(); 
} 
 
$charset = mysqli_character_set_name($link); 
printf ("Current character set is %s\n",$charset); 
 
mysqli_close($link); 
?>
  |  
  |  
 Результат выполнения данного примера: Current character set is latin1_swedish_ci  |  
 
  
 
  mysqli_character_set_name
  
 There are no user contributed notes for this page.   
 |    |