How to make a subdomain like sa.domain.com and display specific data on it ? PHP
I've website ex: ( domain.com ) displays products and I wanna make subdomain like ( sa.domain.com ) to display products that in "Saudi Arabia" for example.
How to make this subdomain and make it display only specific data from the original website domain.com...
I can copy all website to the subdomain but I think there is a better idea ??? PHP Native
But,
creating a new or updating existing subdomain will involve DNS record changes and it will take from hour up to 72 hours to propagation to all the world...
i think i would prefer to use middleware to update the region/country and store it in session or somewhere to filter the data without touching the dns part...
Maybe I am missing the question, but it seems as if you could have the domains point/use the same database, each domain defining the specific qualification(s) you want.
Define the qualification's value in either the .env file OR in the config/app.php file (preferred choice) This would allow you to specify the qualification for each of your domains you currently have and may add in the future.
And, for the domains which would not have any specific qualification(s) you could have it defined as "1=1" in .env or config/app.php.