html-entities

Code in a RSS feed

I am using a feed creator (specifically, Kohana's feed::create()), except some of my text might be like this in the description element See code below <?php echo 'example'; ?> The feed creator is using the SimpleXML Library. Whenever the data is returned (using $xml->asXml()) the html angle brackets inside the description elem...

Why does this strange character encoding happen?

This HTML source code: <td class="result">'DIVIS&Atilde;O DE EDUCA&Ccedil;&Atilde;O PR?ESCOLAR E ENSINO PRIM&Aacute;RIOO'</td> displays as: 'DIVISÃO DE EDUCAÇÃO PR?ESCOLAR E ENSINO PRIMÁRIOO' Yeah, these are some Portuguese characters. Why does &Atilde; stand for Ã? ...

htmlentities in PHP but preserving html tags

Hi there, I want to convert all texts in a string into html entities but preserving the HTML tags, for example this: <p><font style="color:#FF0000">Camión español</font></p> should be translated into this: <p><font style="color:#FF0000">Cami&oacute;n espa&ntilde;ol</font></p> any ideas? ...

HTML Entities with jQuery

I would like to use replace the value of a submit button with "Loading& hellip;" (without spaces). The problem is that when I click the button I still see "& hellip;" instead of three dots. Here's my code: $("#myid").val("Loading"); Should I enter the ellipsis directly from keybord in the code above? Is it safe with UTF-8? ...

Replacing &nbsp; from javascript dom text node

I am processing xhtml using javascript. I am getting the text content for a div node by concatenating the nodeValue of all child nodes where nodeType == Node.TEXT_NODE. The resulting string sometimes contains a non-breaking space entity. How do I replace this with a regular space character? My div looks like this... <div><b>Expires...

What encoding is this... and how do you escape it in php?

Im working on an imdb data scraper for a site, and I they seem to encode everything in a weird encoding I never saw before. <a href="/keyword/exploding-ship/">Exploding&#xA0;Ship</a> A Bug&#x27;s Life Is there a php function that will convert these to regular characters? ...

Decode Numeric HTML Entities in ColdFusion?

I need a way to transform numeric HTML entities into their plain-text character equivalent. For example, I would like to turn the entity: &#0233; into the character: é Through some googling around I found a function called HtmlUnEditFormat, but this function only transforms named entities. Is there a way to decode numeric entities ...

Best way to find illegal characters in a bunch of ISO-889-1 web pages?

I have a bunch of html files in a site that were created in the year 2000 and have been maintained to this day. We've recently began an effort to replace illegal characters with their html entities. Going page to page looking for copyright symbols and trademark tags seems like quite a chore. Do any of you know of an app that will take a ...

How To HTML Escape Curly Quotes in a Java String

I've got a string that has curly quotes in it. I'd like to replace those with HTML entities to make sure they don't confuse other downstream systems. For my first attempt, I just added matching for the characters I wanted to replace, entering them directly in my code: public static String escapeXml(String s) { StringBuilder sb = new...

Convert special chars to HTML entities, without changing tags and parameters.

I'm using FreeTextBox editor to get some HTML created by users. The problem with this is this editor is not converting special chars in HTML entities at exception of "<>". I cannot use theHTML = Server.HtmlEncode(theHTML), because it converts all the HTML including tags and parameters, and I don't want to create an unfinishable list of ...

Encode HTML entities but ignore HTML tags - in PHP

I have a string that might look like this $str = "<p>Me & Mrs Jones <br /> live in <strong style="color:#FFF;">España</strong></p>"; htmlentities($str,ENT_COMPAT,'UTF-8',false); How can I convert the text to HTML entities without converting the HTML tags? note: I need to keep the HTML intact ...

php htmlentities to decode textarea

Hi, I have a text area and I would like to take the input of the text area and merge it all together. Everything works fine except that it's escaping the quotes. For example test's is outputted as test/'s To fix this I tried htmlenttries such as, <?php $inputtext= $_POST['textinput']; $encodetext = htmlentities($inputtext); ...

whitespace html entity?

is there a corresponding html entity that represents a whitespace and like this '|_|'?? ...

Character entity in meta description

Hey Guys, Our SEO has asked us to put the &#9992; entity (✈) into our description, to possibly assist with our clickthroughs. This works fine in FF, however in IE (surprise surprise) if the client does not have a compatible font for the entity (So far I have only found MS Sans Serif) then it only shows up as sqaures in google results. ...

How can I extract html escape chars/entities as text when scraping web? (ruby & nokogiri)

In my ruby+mechanize(nokogiri) script I use this piece of code: row.at_xpath('td[3]/div[1]/a/text()').to_s.strip on a forum where the post title html looks like: <a href="showthread.php?t=233891" >&lt;/body&gt; on Footer ?</a> and I receive from xpath this string &lt;/body&gt; on Footer ? I would like to get what I can see in ...

&amp; or &#38; what should be used for & (ampersand) if we are using utf8 in xhtml document?

What is the difference between this &amp; and this &#38; for &(ampersand)? What should be use with utf8 ? ...

How To Display HTML Entities (decimal) In PHP?

How do i display the percent sign % in PHP using unicode &#037;? Here is the code. echo $percent . "&#037;"; I have the code inside a PHP function on a separate page it is then displayed on the HTML page. ...

Should i convert every single possible charcter in my xhtml/html code? for both encoding iso-8859-1 vs utf?

Should i convert every single possible charcter in my xhtml/html code? for both encoding iso-8859-1 vs utf? If yes then is there any software to convert any needed character (which should be always in entity code) in my xhtml/html. like after complete xhtml coding in dreamweaver or in any editor i will put all code in converter and will...

Infinity symbol with html

How can I display an infinity symbol using html? ...

Python URL Characters

I really new to Python and coding in general, but I have been making some good strides. I am able to pull some data off of the web through an API, and the result should be a string. What I am seeing though, are some instances such as "& amp;"" and " &quot". (I modified the character sets so it would print properly to the screen) I fig...