473,372 Members | 970 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,372 software developers and data experts.

? character displays instead of pound sign

hi im outputting text from a db and where a sign has been entered a
? character appears instead which i cant seem to get rid of with a
simple str_replace. is their a way to get rid of it? and what is
causing it?

regards

marc

Sep 5 '06 #1
4 13979
My best guess (and that's all it really is - I just figured I'd have a
go at this) is that the character set is not correct for what you're
trying to do. The '?' is often used when the character set does not
support a character that is being displayed. I know that the character
set can be changed using a meta tag in simple html.

I hope that helps somewhat.
monomaniac21 wrote:
hi im outputting text from a db and where a sign has been entered a
? character appears instead which i cant seem to get rid of with a
simple str_replace. is their a way to get rid of it? and what is
causing it?

regards

marc
Sep 5 '06 #2
In message <11*********************@b28g2000cwb.googlegroups. com>
"monomaniac21" <mc******@googlemail.comwrote:
>hi im outputting text from a db and where a sign has been entered a
? character appears instead which i cant seem to get rid of with a
simple str_replace. is their a way to get rid of it? and what is
causing it?

regards

marc
Try &pound; for
--
Kev Wells http://kevsoft.topcities.com
http://kevsoft.co.uk/
ICQ 238580561
Walk upon England's mountains green?
Sep 5 '06 #3
>
Try &pound; for
--
i cant as it is the user entering the pound into textarea.

Sep 5 '06 #4
monomaniac21 wrote:
>Try &pound; for
--

i cant as it is the user entering the pound into textarea.
Excuse me.. you mean you are accepting user input with your eyes wide
shut ?!?! No validation or formatting at all ?
Bad practice to start with...

But hey.. it's your app that will get hacked, not mine.

For solving the ? puzzle, set the form encoding to the correct charset,
set the page encoding to the correct charset, send a good charset header
and use htmlentities() *with* the optional encoding parameter.

It that doesn't help you, be more specific in your question.

Sep 5 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Robert Zierhofer | last post by:
hi there, it seems as if i cant convert the euro and pound sign to their html equivalents. i tried eregi_replace("", "&euro;", $haystack); eregi_replace("", "&pound;", $haystack); as...
4
by: ben | last post by:
Hi all, I have a simple PHP page that takes values from a form and puts them in a database (MySQL). The code is in a file test.php, which I have typed in at the bottom of this post (please...
5
by: Waldy | last post by:
Hi there, I am using the .Net XML Serialization classes to create XML strings. This has been working fine up until the point that one of the strings contained a pound sterling symbol. The...
6
by: Anthony | last post by:
When using StreamReader/Writer to process an input text file to an output text file the pound signs (£) simply disappear. Sample code: StreamReader sr = new StreamReader("input.txt");...
7
by: kingski | last post by:
Any idea about this ? http://www.developerfusion.co.uk/forums/thread/114379/#114379 "Can any one help me as i am building a shopping cart and it supports multiple currencies but while sending...
2
by: Per Rasmussen | last post by:
When I use a StreamReader to read lines from a file, it seems to skip some "special" characters like ?, , and . How do I prevent it from doing this? I know it works if the text file is in...
1
by: watcher00 | last post by:
every time i try to print "" i get "" instead This print(""); produces rather than how can i change this?
5
by: ramaswamynanda | last post by:
Hello, I have a currency field on my form. The default formats for this field are dollar, euro. There is no pound symbol.....How do i put in a currency format, having the pound sign. Any help...
4
by: jaems | last post by:
my code <font size="2">Approx </font>&nbsp;&nbsp; which I intend to display as: Approx Displays as Approx £
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...

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.