ascii character - removing chars from string update

Marc 'BlackJack' Rintsch bj_666 at gmx.net
Tue Jul 4 02:54:47 EDT 2006


In <mailman.7748.1151988807.27775.python-list at python.org>, bruce wrote:

> here is a sample of the text i'm looking to do hte search/replace for...
> 
>                     <td valign="top" colspan="2" class="sectionheading"
> bgcolor="#ffffff" > ACCT 209 - SURVEY OF ACCT PRIN      </td>
> 
> i'm trying to figure out how to replace the "&nbsp" with a ''. in html, the
> ' ' char is not a valid ascii char...
> 
> in perl, i'd do 's / //' and be done with it!!!

And in Python I'd use the `replace()` method on strings and be done with
it!!!

Ciao,
	Marc 'BlackJack' Rintsch



More information about the Python-list mailing list