i'm using WampServer 2.2a-x32 and i'm attempting to use .htaccess file during my webroot folder.

i've rewrite.php file here is its code

<h2 align=center> 
<?php 
// mod_rewrite Test Page 
if($_GET['link']==1){echo"You are not using mod_rewrite";} 
elseif($_GET['link']==2){echo"Congratulations!! You are using Apache mod_rewrite";} 
else{echo" mod_rewrte Test ";} 
?> 
</h2> 

<hr> 

<head>    
</head> 

<body> 
<p><a href="rewrite.php?link=1">LINK1</a> = rewrite.php?link=1</p>
<p><a href="link2.html">LINK2</a> = link2.html</p>     
</body> 
</html> 

i've .htaccess file here is its code

RewriteEngine On 
RewriteRule ^link([^/]*).html$ rewrite.php?link=$1 [L]

during my http.conf file i've

LoadModule rewrite_module modules/mod_rewrite.so uncommented (without #)

and my Apache is set up to hear 8080 port unsure if it is the problem.

Therefore if i hit the hyperlink http://localhost:8080/test/rewrite.php i see the page however when i hit link2 mod_rewrite does not appear to operate. i recieve Not Found The asked for URL /test/link2.html wasn't available on this server.

My product is home windows 7 x32 any suggestions ?

I want to include a RewriteBase, since the htaccess in not situated within the document-root.

RewriteEngine On 
RewriteBase /test
RewriteRule ^link([^/]*).html$ rewrite.php?link=$1 [L]

thanks i actualy handled to repair it. The issue could be that the file wasn't named corectly, rather than .htaccess it had been htaccess.