473,396 Members | 2,108 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Character encoding in PHP & GD2?

118 100+
Hi all,

MyChatBox

I have been working on a dynamic image in GD2 which acts as a chatbox in a forum signature.

It all seems to be working pretty well, but I have come across a bug (of sorts): if the user were to enter characters such as '¬_¬' the result in the image is shown as 'ˇ_ˇ'.

Is there any way that, using PHP, I can change this so that is actually understands the characters and would print '¬_¬'.?

Hope that makes sense.

Sam
Oct 28 '07 #1
2 1255
pbmods
5,821 Expert 4TB
Heya, Sam.

Make sure you include the character encoding of your file in your HTML:

Expand|Select|Wrap|Line Numbers
  1. <meta http-equiv="Content-type" content="text/html; charset=ISO-8859-1">
  2.  
Oct 28 '07 #2
helraizer1
118 100+
Heya, Sam.

Make sure you include the character encoding of your file in your HTML:

Expand|Select|Wrap|Line Numbers
  1. <meta http-equiv="Content-type" content="text/html; charset=ISO-8859-1">
  2.  
I have that in my HTML code, so the characters '¬_¬' are visible on the main page. But it's when said characters are put in the actual dynamic image that the problem occurrs.

Any ideas?

Sam
Oct 29 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

12
by: frizzle | last post by:
Hi there! I have (for sofar) a small problem: I have a site, with mySQL-backend, and an online admin system. The site is in three languages: 1 of them is German. My poblem concerns the 'ß'...
2
by: ahsan Imam | last post by:
Hello All, I have this file and when I import the file in the python interpretor I get the following error: "__main__:1: DeprecationWarning: Non-ASCII character '\xc0' in file trans.py on...
4
by: Krishna A.M | last post by:
Hi, How do i add a hyperlink to a email id having special characters? I tried the same , say mailto: test_&_send@hoohoo.com IN the to box i can see only till test_ and the rest is omitted. ...
19
by: Ian | last post by:
I'm using the following meta tag with my documents: <meta http-equiv="Content-Type" content= "text/html; charset=us-ascii" /> and yet using character entities like &rsquo; and &mdash; It...
8
by: Colin Peters | last post by:
Hi, I'm reading a file and writing it to the html output for a page. I've come across two difficulties which I would like to solve. The files contain special characters from European...
6
by: snt | last post by:
I have a C# asp.net project in which I create meta keywords dynamically. I have a problem with "&" character. When the page is rendered, the "&" character is converted into "&amp;". Is there any...
5
by: Dadi | last post by:
Hi, My native language is Icelandic and IĀ´m making a web service that returns results that contain many Icelandic characters. This works fine, however, when I return a soap:Fault, the string in...
11
by: BenI | last post by:
Hello, I have a XML file using Iso 8859-1 encoding. Every time when I try to put & character as Tag's value like <tag>This is & character</tag> Exception is shown in my application. I use...
3
by: bsagert | last post by:
Some web feeds use decimal character entities that seem to confuse Python (or me). For example, the string "doesn't" may be coded as "doesn’t" which should produce a right leaning apostrophe....
7
by: tempest | last post by:
Hi all. This is a rather long posting but I have some questions concerning the usage of character entities in XML documents and PCI security compliance. The company I work for is using a...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.