Comments (6)
Hi @jasontxf
If you are using the blade templates, then yes you need to include the host for every request as you can't store it in the same way that an SPA does. As your page loads multiple times it means you need to always pass it for every page load so you can load in appbridge every time.
from laravel-shopify.
Create a query param called host and use base64_encode(Auth::user()->name)
append it on the link. I had the same issue and this was my fix.
from laravel-shopify.
@karenirenecano Thanks for replying! Which file do I append the host exactly?
from laravel-shopify.
For my case it's on the pricing page. I append it on the url like this billing/1?host=the_base_encoded_shop_name
from laravel-shopify.
ah! I see what you are saying now! I'll give it a try! Thanks alot for the suggestion!
Will update here again after trying.
from laravel-shopify.
Hello,
Here's an updates, your suggestion works very well! Thanks alot!
I created a helper function to include host in every routes to ensure host parameter is included.
function sroute($path, $params) {
return route($path, [...$params, 'host' => base64_encode(Auth::user()->name)]);
}
That way I dont need to change my current implementation
sroute('billing', ['plan' => 2, 'shop' => Auth::user()->name]) }}"
Though @Kyon147 are we supposed to manually include host in all our links?
Thanks alot for all your time!
from laravel-shopify.
Related Issues (20)
- Form Redirect Issue HOT 2
- Not Supported in Laravel 11 HOT 1
- Usage Charges Redirecting to Blank Page HOT 1
- Installing on October or Winter CMS HOT 2
- Missing csp in scripts and styles tags HOT 1
- it requires api_key but now shopify uses oauth which is required client_id and client_secret so there us no more api_key. So how to get the access_token now? HOT 1
- issue 'Unable to verify signature.' where the HMAC signature sent by Shopify during authentication suddenly does not match HOT 3
- Show blank page after app install in my store HOT 3
- Not able to create webhooks HOT 8
- AfterAuthenticate Job and Script Tags Not Triggered Upon Reinstallation of App HOT 2
- Deprecating of billing_on field on the UsageCharge resource HOT 3
- How to get Shop detail on laravel controller to execute public app API's
- Shopify API rate limit HOT 1
- MissingAuthUrlException triggered when installing the app on a store with no theme HOT 4
- A couple weeks away. HOT 6
- Auth::user() return null in AppInstalledEvent listener HOT 3
- Potential Bug: Session token is invalid HOT 2
- Auth user returns null on Inertia HOT 6
- Problem with Calculation of Trial Days Remaining from Cancellation HOT 2
- API Requests in scheduled jobs HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laravel-shopify.