Here is my php code(qs.php). This file contain pretty url links.
<html>
<head></head>
<body>
<?php
$file = 'qs1'; //this is a php file qs1.php
$id = '12345678'; //testing ID
$complete_url = $file."/".$id;
?>
<a href ="<?php echo $complete_url;?>"> This is a test link </a>
</body></html>
This link appear link this - http://localhost/qs1/12345678
QS1 is a php file (qs1.php).
QS1.php
<html>
<head>
<title>QS1 file</title>
</head>
<body>
<a href="#"><img src="images/blog/girl.png" class="img-circle" alt="" /></a>
<a href="#"><img src="images/blog/girl2.png" class="img-circle" alt="" /></a>
<a href="#"><img src="images/blog/girl3.png" class="img-circle" alt="" /></a>
</body></html>
Below is the htaccess code.
Options -MultiViews
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} -d [OR]
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^ - [L]
RewriteRule ^([^/]+)/(\d+)/$ $1/$2 [R=301,L]
Everything is working fine. My link is working properly. http://localhost/qs1/12345678 link is accessible by this. I am able to access the page. In my current page wherever i use this code(#). I can say other links on that page.
<a href="#"><img src="images/blog/girl.png" class="img-circle" alt="" /></a>
It is redirecting to localhost only instead of passing the same to current page.
Not sure what i am missing.