I am using laravel 5.4 and have a script which i to run on multiple views.
When load the script i want to know in which view was loaded?
example: If i open page one the script will load test.js with the id="one" <script src"test.js" id="one">
If load page two: <script src="test.js" id="two"> the same script with another id="two".
How can i get the current script id? In test.js i want to know which view(page) was calling test.js script to run (page one or page two) I have a custom function for each page). Is this possible?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire