Help me! I have a domain, I would like to handle subdumain with .htaccess file.

for example: or should not redirect to sub folder. URL should not change in the browser but it has to call a file php file and give result. Is there any possibilities in .htaccess or php.ini file?

Recommended Answers

All 2 Replies

Try this PHP code,

// create a new cURL resource
$ch = curl_init();

// set URL and other appropriate options
curl_setopt($ch, CURLOPT_URL, "");
curl_setopt($ch, CURLOPT_HEADER, 0);

// grab URL and pass it to the browser

// close cURL resource, and free up system resources

thanx vijykmar, but my problem is subdumain name should not change in the browser, and subdomain name has to go as internal parameter into a php file. i mean all subdomains are going to call single php file only. i'm looking for .htaccess or php.ini solution.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.