News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Looking for simplification in API for registration

Started by Glyph, December 06, 2015, 08:14:28 PM

Previous topic - Next topic

Glyph

What i'm looking to do is tie the registration and login functions together with my scripts.


  • My scripts only requires 4 inputs from the user in order to register
  • With SMF there's also name and some other stuff that i'm really not interested in.

e.g. I don't need this:

passwd (SHA1 hash)
passwordSalt
validation_code
personalText
ID_THEME
ID_POST_GROUP


Is there a function in the API that supports a minimalist registration feature? I would just delete these rows out of SMF's core DB if I could. I would literally need to remove features from SMF core (i think, unless theres a way to disable them)

Maybe i'm better off making a custom forum script?
Personal TODO:

Glyph

#1
A more simple SMF would be incredibly useful for others who are looking to bridge and just want a very simple forum to integrate with, with the support and security of SMF.

Since this would only remove certain parts of the forum I woudn't imagine there would be any security risks associated. Biggest issue being re-adding everything, and in the case of SMF upgrades; upgrading after applying the mod wouldn't work... you'de be stuck at whatever version you applied the mod to. Hmm... maybe a fork would be better, the downside being 2 projects and limited public interest.

Unless the mod added some "smart upgrade" options where it would restore the code and then upgrade. Also removing itself in the case that the mod hasn't been updated for the new version of SMF. (so it can handle the new changes and then re-implement them in the new way)
Personal TODO:

Glyph

#2
The only required options are:
'member_name' (unique), 'email' (unique), 'password'

Woohoo! This topic is totally unnecessary.

e.g.
smfapi_registerMember(array(
    'member_name' => 'glyph',
    'email' => '[email protected]',
    'password' => 'test1234'
        ));


I suppose i have to do some more research however, the user isn't added to latest registered users on the forum.
It's defaulting to admin approval for some reason :/

fixed with:
smfapi_registerMember(array(
    'member_name' => 'glyph',
    'email' => '[email protected]',
    'password' => 'test1234'
    'require' => 'nothing'
        ));


possible options are:
'nothing'
'activation'
and blank value for default (admin approval)
Personal TODO:

Advertisement: