I have a problem on my lawyer search page. i want http://local-lawyer-directory.com/info.php?id=12 PHP: to look more like http://local-lawyer-directory.com/country-name of law company PHP:
you need to make htaccess file to pass permalink to real php file like RewriteEngine On RewriteRule ^country-(.*)\$ info.php?id=$1 [L] for more information about htaccess file check http://httpd.apache.org/docs/1.3/howto/htaccess.html
To make it work by name of law company you will have to edit the php file to read from the DB using name not the id number.
Both solution will work, but in a different way. Changing the htaccess will allow you to have links that look like: http://local-lawyer-directory.com/country-name of law company The second solution given would look like: http://local-lawyer-directory.com/info.php?name=country-name of law company Both valid solutions, the first one's maybe a little prettier, and the second a little easier to accomplish. Hope that helps!
htaccess since i am a noob on htaccess is that correct? Should i use the one in the root folder to make this happen?
Not a real htaccess expert either.. but http://codex.wordpress.org/Using_Permalinks might shed some light on the issue. The article's about how wordpress uses this trick... but goes into pretty good detail. A google search should help you find some more info. Good luck!
Well You Can Use this .htaccess code Options +FollowSymLinks RewriteEngine on RewriteRule country-name/$ /info.php?id=12 Code (markup): Change the country-name part as per ur needs
Yes un less u have individual countries in ur databese then i think it possible to do it automatically