Jump to content

Primary: Sky Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Secondary: Sky Slate Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate Marble
Pattern: Blank Waves Squares Notes Sharp Wood Rockface Leather Honey Vertical Triangles
Welcome to PHPFox Camp
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. This message will be removed once you have signed in.
Login to Account Create an Account
cheap dedicated servers
Photo

PHPFox useername like Facebook

phpfox username

  • Please log in to reply
1 reply to this topic

#1
scorpiolazy

scorpiolazy

    Newbie

  • Campers
  • 9 posts
  • LocationLithuania

I was working all day last night trying to figure out how to allow . in username so it would look:

 

http://website.com/firstname.lastname

 

I managed to allow . in username by changing line 15 of PF.Base/include/setting/validator.sett.php

 

from:

 

'pattern' => '/^[a-zA-Z][a-zA-Z0-9\-_ ]{' . (Phpfox::getParam('user.min_length_for_username') - 1) . ',' . (Phpfox::getParam('user.max_length_for_username') - 1) . '}$/',

 

to:

 

'pattern' => '/^[a-zA-Z][a-zA-Z0-9\-_ . ]{' . (Phpfox::getParam('user.min_length_for_username') - 1) . ',' . (Phpfox::getParam('user.max_length_for_username') - 1) . '}$/',

 

After doing this it allows now to set username with dot, just like I want, but when you go to top menu URL is automatically changed to:

 

http://website.com/firstname/lastname

 

It gives error page not found.

 

When you enter correct URL in browser http://website.com/firstname.lastnameprofile opens just fine.

 

I do not code and that is why trying to fix this is only a guessing.

 

Does this has to do with .htaccess file or some URL validation in PHP code?

 

Can someone figure it out and give me a solution?

 

Also would be nice to change that system automatically generates firstname.lastname instead of profile-01

 

Any help would be appreciated.

 

 




#2
scorpiolazy

scorpiolazy

    Newbie

  • Campers
  • 9 posts
  • LocationLithuania

...no one knows how to fix this???






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users