| 
	
 | 
 Posted by Mattia Gentilini on 05/31/07 15:05 
The.Relinator@gmail.com ha scritto: 
> I'm just wondering what the best way is to extract and display a 
> number from a html file. 
>  
> I tried the following piece of code, however it does not work. 
>  
> ereg('\d\.\d', $content, $reg); 
> echo $reg[0]; 
ereg() is a test function, it checks if a regexp matches a given string  
and returns a boolean. 
You probably need ereg_replace($regexp, $substitute, $input); see the  
doc for details. 
 
--  
|\/|55: Mattia Gentilini e 55 cappuccini per svegliarsi (by Sigfrido) 
|/_| ETICS project at CNAF, INFN, Bologna, Italy 
|\/| www.getfirefox.com  www.getthunderbird.com 
* Using Mac OS X 10.4.9 powered by Cerebros (Core 2 Duo) *
 
[Back to original message] 
 |