How to require_once an external php lib to intercept registration?

Started by sci0n, October 28, 2020, 04:26:38 AM

Previous topic - Next topic

sci0n

Hello.

I need to add a custom register condition to my SMF.

I found a place in function Register2 to intercept with the additional verification check.

I made the function that checks if the condition (via custom profile fields value) and tested it outside of SMF. The function uses a library.

Whenever I try to require_once that file, the Register2 function stops there (I am checking with var_dumps afterwards, nothing after the require_once executes). The path to the extra file is correct. I put the file into the Sources dir, did not help.

I saw there are other files require_once'd so I thought it's something that is possible to do, but apparently it isnt.

How can I require_once an extra file?

Arantor

Check the error log... either your path is actually wrong or there is something wrong with the file, but either way the error log will tell you what.

sci0n


Advertisement: