So I have this structure in my app.blade.php
If statement check if user have subscription and if no shows sub page else show dashboard
I send all required variables to dashboard view like this
But when I’m trying to get variable in before-payment view I cant reach it.
I test it without If statement in Dashboard I can use all variables. So how can I use variables in this situation?
2
Answers
You’re talking about the app.blade.php file where you call up your payment file, if I understand correctly.
Is the dasboard.blade.php file also included in this app.blade.php file?
your explanation isn’t too clear.Make sure you send the variable to the right file.
Maybe this cas help you: @include(‘child’, compact(‘title’, ‘content’))
I think its better if u passing to global view via AppServiceProvider ( boot function ).
Just add :