i'm new to Magento period. I'm currently on 2.1.9 and is trying to figure out how to either show login modal or redirect customer to login page when the user clicks on add to cart. So 3 things need to happen: 1 - user click on add to cart 2 - add item to cart 3 - check if user is login or not, if not show login, if logins, continue as normal.
Can someone please help me down the right path to what i need to do to make this happens? what file should i edit to achieve this? When i use fiddler it shows the link as yoursite/index.php/amasty_cart/cart/ and some other times it show yoursite/index.php/checkout/cart. I tried to modify add.php and addtocart.php in both places but it still didn't do anything. Please help.....I thank you so much for your time and your help.