Jay_Menna
(Jay Menna)
February 16, 2016, 3:12pm
1
On xojo cloud if you run just one app and you want a “Neat” URL you can simply use jabvascript on the index.html page
I currently use something like:
<SCRIPT language="JavaScript">
window.location="http://app1.mydomain.com/red";
</SCRIPT>
How can I write javascipt to go to one of multiple apps?
red.mydomain.com --> http://app1.mydomain.com/red
blue.mydomain.com --> http://app1.mydomain.com/blue
Further complicating matters I need the parameters to remain in tact.
blue.mydomain.com/?parameter1=abc?paramteter2=123 -->http://app1.mydomain.com/blue/?parameter1=abc?paramteter2=123
I am not a Xojo Cloud user. But I know there are ways of doing URLrewriting on webservers by modifying a text document called .htaccess
Some info can be found HERE .
But, I have no clue if that works on the Xojo Cloud servers though
Jay_Menna
(Jay Menna)
February 16, 2016, 6:44pm
3
XC does not give you access to .htaccess
Oh, too bad. In that case I don’t know. @Paul Lefebvre or @Norman Palardy … Any tips?
I haven’t tried this, but would document.referrer work?
Here is what we use for our index.html. We use the subdomain to identify different sites. In this case I reroute to https, or if the subdomain is browsertest then I run an app we specifically wrote to test some features of the users browser. Otherwise it would just run a “App-Name” application.
So url http://client.website.com would become https://client.website.com/App-Name/
or
http://browsertest.website.com would become https://browsertest.website.com/browsertest/
This seems to work very well
[code]
[/code]