1

when try to install sentry 2 with composer it will installed very well. but how can use in existing PHP project thanks in advance.

1 Answers1

1
  • First of all I would advise you to switch to Sentinel 2 from Sentry as Sentry is deprecated now.
  • Now for using it in your existing project you need to replace the existing Authentication system with that of Senty's. For that you will have to replace all the -
    • Sign Up
    • Sign In
    • Sign Out and
    • Authentication middleware

methods with that of sentry's.

It would be good if you follow the Sentinel documentaion. It's a good one for beginners. Sentinel 2.0

Also a lot depends on the PHP framework you are using for your backend. If you are using something big like zend, yii etc. they already have a pretty good authentication system of their own.

If you are using a light weight framework suppose Slim then there the documentation will guide you pretty well to set it up. Also there are various blogs online explaining the same.

Ashish
  • 679
  • 7
  • 19