Separate registration from ucp.php

Note: We are moving the topics of this forum and it will be deleted at some point

Publish your own request for comments/change or patches for the next version of phpBB. Discuss the contributions and proposals of others. Upcoming releases are 3.2/Rhea and 3.3.
Smellybeard
Registered User
Posts: 2
Joined: Sat Mar 30, 2013 1:33 pm

Separate registration from ucp.php

Post by Smellybeard »

Currently, user registration is implemented via ucp.php, which is also used for login and most other user control functions. I would like to see registration handled by a completely different page so as to allow Apache to restrict access to it using the Files directive.

This would simplify anti-spambot measures for many boards.

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 1905
Joined: Thu Mar 02, 2006 4:29 pm
Location: Earth
Contact:

Re: Separate registration from ucp.php

Post by DavidIQ »

How does blocking access to a file help with SPAM? Just trying to understand as I would assume you would be restricting access to the file for everyone.
Image

Smellybeard
Registered User
Posts: 2
Joined: Sat Mar 30, 2013 1:33 pm

Re: Separate registration from ucp.php

Post by Smellybeard »

I'd like to restrict registration geographically but allow full access, globally, to those who are already registered.

User avatar
bantu
3.0 Release Manager
3.0 Release Manager
Posts: 557
Joined: Thu Sep 07, 2006 11:22 am
Location: Karlsruhe, Germany
Contact:

Re: Separate registration from ucp.php

Post by bantu »

Smellybeard wrote:I'd like to restrict registration geographically but allow full access, globally, to those who are already registered.
Well, then all you probably have to do is also take the query string into account. There probably is no need to have separate files for this.

User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Re: Separate registration from ucp.php

Post by Dragosvr92 »

As bantu said. ucp.php?mode=register will be as good as a simple php page like register.php if you want to block it.
But having it named register.php would be prettier. Maybe an idea for 3.1.
Previous user: TheKiller
Avatar on Memberlist 1.0.3

User avatar
EXreaction
Registered User
Posts: 1555
Joined: Sat Sep 10, 2005 2:15 am

Re: Separate registration from ucp.php

Post by EXreaction »

More front facing scripts generally makes development and maintenance more difficult and time consuming. phpBB is (slowly) moving more towards an MVC architecture, where a single front facing file is used for all requests. This would generally mean URLs will be /index.php?page=register, but with URL rewriting it could be whatever we want, like /register

User avatar
brunoais
Registered User
Posts: 964
Joined: Fri Dec 18, 2009 3:55 pm

Re: Separate registration from ucp.php

Post by brunoais »

I never liked that MVC... That's one of the things I hate most in SMF.
I prefer having multiple generalist points-of-entry to the system and then each one of them takes care of its dependencies... But sounds like, for most people, that that is not the easiest way of dealing with it...

User avatar
Pony99CA
Registered User
Posts: 986
Joined: Sun Feb 08, 2009 2:35 am
Location: Hollister, CA
Contact:

Re: Separate registration from ucp.php

Post by Pony99CA »

brunoais wrote:I never liked that MVC...
MVC is basically just separating "business logic" from your input and output pieces. This allows you to support different output methods (video, voice, etc.) and input methods (keyboard, mouse, touch, speech, etc.) without having to mess around with your core code. It doesn't imply that you only have to have one file for display.

So what's not to like?

Steve
Silicon Valley Pocket PC (http://www.svpocketpc.com)
Creator of manage_bots and spoof_user (ask me)
Need hosting for a small forum with full cPanel & MySQL access? Contact me or PM me.

sajaki
Registered User
Posts: 86
Joined: Mon Jun 21, 2010 8:28 pm

Re: Separate registration from ucp.php

Post by sajaki »

In MVC, you can/will have multiple views by default. the controller decides which view to render, and the views have no knowledge about the controller(s).

So i agree that having just one index.php entrypoint looks a bit narrow.

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 1905
Joined: Thu Mar 02, 2006 4:29 pm
Location: Earth
Contact:

Re: Separate registration from ucp.php

Post by DavidIQ »

https://area51.phpbb.com/phpBB/viewtopi ... 08&t=44179
That looks to be the direction we are going towards though.
Image

Post Reply