I have a problem with my angular application. As it is get api call from laravel backend. I am hosting both of them on the same domain but with different subdomains.Angular project at (beta.easyschools.org) $ backend at (erp.easyschools.org) when I try to log in within the app I keep getting this error message No access origin headers.. however when I put the dist folder of the angular app in my public folder of the laravel I can access the application and log in successful. but I have another problem that any api that I try to call I receive message "unauthenticated". can't find any solution on the internet for this problem.
Important note: Everything works fine in local environment but when I try it on my apache server it is not working as metiond above. although I have configured my backend .htaccess and apache2 server to accept headers
For the second issue how are you authenticating? You need token based authentication. Try https://github.com/tymondesigns/jwt-auth where you pass a unique token in the header of every angular http request
i alreaddy have cros and i am working with access token passport not JWT. everything is working fine in local but when i put my backend on the server. it doesn't work