My site on shared hosting. I want to pass user created subdomains to controllers functions:
Example:
x.mysite.com - > mysite.com/user/x
y.mysite.com - > mysite.com/user/y
etc.
On other words, if someone visits x.mysite.com, "user" method with x variable needs to be triggered.
I searched Google, Stack Exchange sites but none of them worked for me. I already added *.mysite.com A record with same ip to my Cloudflare account. Also created *.mysite.com subdomain on cPanel and set directory root as same as my Codeigniter app resides (public_html). Now, if I enter mysite.com or *.mysite.com, same page (controller) showing.