I would like my Meteor application to ‘skin’ differently depending on which URL the client used to connect… e.g. https://iHeartCats.com vs https://iHeartDogs.com - so I’d like to be able to the connection string (from t
What is the most robust way to do this with Meteor on the Server side, and that will work for example with Galaxy?
Of course if the client just connects via the server’s IP address I can’t tell anything, but I can handle that case with a default (dogs of course ). Also, For the client side I realize I can just use window.location etc
My questions is about server side. I did mention in my question when I posted it that I know I can do that on client side… Of course I could just send that up in a Meteor.call etc, but that seemed ugly
You can probably leverage connection.httpHeaders.host on the server side. You can access this in methods and publish functions server side (via this.connection). As a quick test, try adding the following to your /server/main.js: