kai Taylor
kai Taylor

Reputation: 795

Is it possible to have 2 vue js apps installed on the same URL?

I have a client project with the requirement that a user visits a single URL. Then using PHP detect what device they are on and provide them with a different Vue js app dependant on device.

The issue is that the client is adamant that regardless of the app/device that the user is on, they must have the same URLs. Otherwise it would be easier to host each app on separate subdirectories.

Is there a way to have more than one Vue js app live on the same URL such as www.example.com?

Upvotes: 0

Views: 78

Answers (1)

Alan Birtles
Alan Birtles

Reputation: 36389

Could be as simple as this, in index.php

<?php

if (isMobile())
{
  require("mobile.php");
}
else
{
  require("desktop.php");
}

Upvotes: 1

Related Questions