User Tools

Site Tools


creating_clean_profile_url_s

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
creating_clean_profile_url_s [2015/03/09 14:38]
admin
creating_clean_profile_url_s [2015/12/06 15:13] (current)
admin
Line 1: Line 1:
-====== ​Creating Clean Profile URL's ======+====== Profile URL's ======
  
-How to create more personalized ​profile URL's so they look like this ... **yoursite.com/​username**+The .htaccess file included in the script rewrites ​profile URL's so they look like this ... **yoursite.com/​username**
 instead of looking like this ... **yoursite.com/​profile.php?​uid=1** instead of looking like this ... **yoursite.com/​profile.php?​uid=1**
  
 **Note:** This will only work if your host allows mod rewrites. **Note:** This will only work if your host allows mod rewrites.
  
-**Step 1.** Open the .htaccess file located in your main Etano directory and add the following to the bottom of the file:+ Open the .htaccess file located in your main Etano directory and the default profile rewrite code looks like this:
 \\ \\
->><​code><​IfModule mod_rewrite.c>​+>><​code>​ <​IfModule mod_rewrite.c>​
 Options FollowSymLinks Options FollowSymLinks
 RewriteEngine On RewriteEngine On
Line 22: Line 22:
 </​IfModule>​ </​code>​ </​IfModule>​ </​code>​
  
-**Step 2.** Next open your skins_site/​def/​static/​result_user.html file and replace the following:+Be sure to change the "​subdirectory_name"​ to the subdirectory name used on your server.
 \\ \\
->><​code><​a class="​link_bare"​ href="​{tplvars.baseurl}/​profile.php?​uid={profile.fk_user_id}"​ title="​{profile._user}"><​img class="​user_photo thumb1"​ src="​{tplvars.photourl}/​t1/​{profile._photo}"​ alt="​{profile._user}"​ /></​a>​ +\\ 
- <a class="content-link member_link" ​href="​{tplvars.baseurl}/​profile.php?​uid={profile.fk_user_id}"​ title="​{profile._user} profile">​{profile._user}</​a>​{profile.f1} </​code>​ +Another potential issue is if your host has "mod_deflate" ​turned off in your hosting accountin which case you can try changing the following line
-With this+\\ 
->><​code><​a class="​link_bare"​ href="​{tplvars.baseurl}/​{profile._user}"><​img class="​user_photo thumb1"​ src="​{tplvars.photourl}/​t1/​{profile._photo}"​ onerror="​this.src='​media/​pics/​no_photo.gif';"​ /></​a>​ +**Options FollowSymLinks** 
- <a class="​content-link simple"​ href="​{tplvars.baseurl}/​{profile._user}">​{profile._user}</​a>,​ {profile.f1} </​code>​ +\\ 
- +to this: 
-**Step 3.** After editing the above result_user.html file, in order for the changes ​to take effect you must regenerate your skin in the **Admin** >> **Site Setup** >> **Skin Settings** >> section and then click **regenerate** under your default skin. +\\ 
 +**Options +FollowSymLinks -MultiViews** 
 +  
 + \\ 
 +If it still doesn'​t work, you can also try removing the following lines from the htaccess file:
  
 +php_flag session.use_cookies on
 + \\
 +php_flag register_globals off
 + \\
 +php_flag session.use_trans_sid off
creating_clean_profile_url_s.txt · Last modified: 2015/12/06 15:13 by admin