Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Nov 2012
    Posts
    33
    Thanks
    23
    Thanked 0 Times in 0 Posts

    Smile inserting special characters in MySQL database

    how to insert alpha,beta,delta to mysql database through php script?????
    I want save my subject codes to my db table using these special characters..
    example subject code "CSC113α"


    can any one plzz help to do this....thanks in advanced....

  • #2
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,853
    Thanks
    160
    Thanked 2,223 Times in 2,210 Posts
    Blog Entries
    1
    You'd need to change the collation of that filed to utf8_general_ci. Then add the following line to your PHP code before all insert/fetch operation to the DB - better to be used under mysql_select_db() statement.

    PHP Code:
    mysql_query("set names 'utf8'"); 
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

  • Users who have thanked abduraooft for this post:

    ebookz (11-16-2012)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •