flea999
asked on
Problem with character references in HTML Language (Urgent)
Hi everyone,
I need some help to convert character references in an HTML document to the character that the character reference is refering to.
For example, < or < represents the less than sign, å or å represents the letter "a" with a small circle above it. I need some suggestion so that i can convert to these characters in the HTML document. The means that if the character reference < or < appears in the source file, i need to replace all of them with the '<' sign and if the character reference å or å appears , i need to replace all of them with 'å'. There are a whole lengthy list of these character references. At the moment, i can only think of a method of hardcoding the symbols into the java program. Is there a more effective and faster method to replace them?
I need some help to convert character references in an HTML document to the character that the character reference is refering to.
For example, < or < represents the less than sign, å or å represents the letter "a" with a small circle above it. I need some suggestion so that i can convert to these characters in the HTML document. The means that if the character reference < or < appears in the source file, i need to replace all of them with the '<' sign and if the character reference å or å appears , i need to replace all of them with 'å'. There are a whole lengthy list of these character references. At the moment, i can only think of a method of hardcoding the symbols into the java program. Is there a more effective and faster method to replace them?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
- Points to objects
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
girionis
EE Cleanup Volunteer
I will leave a recommendation in the Cleanup topic area that this question is:
- Points to objects
Please leave any comments here within the next seven days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
girionis
EE Cleanup Volunteer
girionis, I think the points should be awarded to me. At least I tried to help the guy, objects provided a simple comment.
Thanks,
\t
Thanks,
\t
Hello orangehead911, I recommended objects comment for the simple reason that the asker asked: "Is there a more *effective* and *faster* method to replace them?" (pay attention to the "effective" and "faster" words) which, I also think, there is not.
The solution you suggested, although a valid one, I believe it is not more effective or faster than the one suggested by the asker.
Anyway, I do not want to be unfair here. You did very well for leaving a comment. I am sure a moderator will consider a split.
The solution you suggested, although a valid one, I believe it is not more effective or faster than the one suggested by the asker.
Anyway, I do not want to be unfair here. You did very well for leaving a comment. I am sure a moderator will consider a split.
Fair enough! :-)
Thanks,
\t
Thanks,
\t
This old question needs to be finalized -- accept an answer, split points, or get a refund. For information on your options, please click here-> http:/help/closing.jsp#1
EXPERTS:
Post your closing recommendations! No comment means you don't care.