php - Access a remote Laravel 5 web app using ajax through a Hybrid App -


i'm developing hybrid app use ajax requests connect remote database. database accessed through laravel(5) framework. when send requests remote laravel web app, following case.

error message, no access control allow origin header present.

to solve problem added access control headers index.php @ public/ directory. above error no longer occurs(yes, know can same using middleware , recommended way). internal server error occurs saying csrf token mismatch exception. know if web appilication, have added csrf_token. since hybrid app, cant set token since can't run php here , can't obtain token ajax request.

up now, have read every thread related in laravel forums. there no feasible answer. have idea how solve issue?

thanks in advance!


Comments

Popular posts from this blog

powershell Start-Process exit code -1073741502 when used with Credential from a windows service environment -

twig - Using Twigbridge in a Laravel 5.1 Package -

c# - LINQ join Entities from HashSet's, Join vs Dictionary vs HashSet performance -