Jump to content

Pretty URL problem


unemployment

Recommended Posts

I'm in the process of building a network for investors and entrepreneurs. When a user logs in, they are directed to profile.php where they can have access to their profile information. If you go into the address bar and type in network.jasonbiondo.com/jasonbiondo you will not be able to view my profile, but if you type in http://network.jasonbiondo.com/profile. ... asonbiondo , you will be able to see my profile. I want to make it cleaner so that you can access profiles by going directly to network.jasonbiondo.com/jasonbiondo . I think my .htaccess file is causing the problem.

 

I have listed my code below.

 

.htaccess

 

  Options +FollowSymLinks
    RewriteEngine On
    RewriteCond %{SCRIPT_FILENAME} !-d
    RewriteCond %{SCRIPT_FILENAME} !-f
    RewriteRule ^(.*)$ ./profile.php?u=$1 [NC]

 

Link to comment
https://forums.phpfreaks.com/topic/216911-pretty-url-problem/
Share on other sites

is "profile.php" in your root directory? (or the same folder as the .htaccess file) ? 

try changing ./profile.php  to just profile.php

 

RewriteRule ^(.+)/?$ profile.php?u=$1

 

profile.php is in my sub domain directory along with my .htaccess file.  Making your change did not have an effect.

Link to comment
https://forums.phpfreaks.com/topic/216911-pretty-url-problem/#findComment-1126827
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.