{"id":18346,"date":"2025-09-16T10:55:41","date_gmt":"2025-09-16T08:55:41","guid":{"rendered":"https:\/\/helloweb-hosting.com\/?p=18346"},"modified":"2025-09-16T10:55:41","modified_gmt":"2025-09-16T08:55:41","slug":"creer-un-sous-domaine-dans-cpanel-avec-php","status":"publish","type":"post","link":"https:\/\/helloweb-hosting.com\/en\/creer-un-sous-domaine-dans-cpanel-avec-php\/","title":{"rendered":"cr\u00e9er un sous-domaine dans cPanel avec PHP"},"content":{"rendered":"<h2><strong>Comment cr\u00e9er un sous-domaine dans cPanel avec PHP ?<\/strong><\/h2>\n<p>Les sous-domaines dans cPanel repr\u00e9sentent des sections suppl\u00e9mentaires et ind\u00e9pendantes d\u2019un site Web, rattach\u00e9es \u00e0 un domaine principal. Ils sont utilis\u00e9s pour organiser le contenu en segments distincts, h\u00e9berger divers services ou cr\u00e9er des environnements de d\u00e9veloppement.Pour un ou deux sous-domaines, il est possible de cr\u00e9er un sous-domaine dans cPanel avec PHP en saisissant simplement le nom du sous-domaine et le domaine principal. Cependant, cette m\u00e9thode devient totalement inadapt\u00e9e lorsqu\u2019un grand nombre de sous-domaines doit \u00eatre g\u00e9n\u00e9r\u00e9 dynamiquement, notamment \u00e0 partir des actions des utilisateurs.<\/p>\n<p>\ud83d\udc49\u00a0<strong>Exemple :<\/strong>\u00a0si un site web exige l\u2019inscription des utilisateurs avant l\u2019acc\u00e8s \u00e0 ses services, un nouveau sous-domaine peut \u00eatre attribu\u00e9 \u00e0 chaque utilisateur apr\u00e8s l\u2019inscription. Effectuer cette op\u00e9ration manuellement serait \u00e0 la fois difficile \u00e0 g\u00e9rer et inefficace.<\/p>\n<hr \/>\n<h3><strong>Quelle est la solution ?<\/strong><\/h3>\n<p>Dans ce type de sc\u00e9nario, il est pr\u00e9f\u00e9rable d&rsquo;utiliser du\u00a0<strong>code PHP<\/strong>\u00a0pour cr\u00e9er automatiquement les sous-domaines. Pour cela, il suffit d\u2019ajouter un extrait de code PHP dans votre base de code existante.<\/p>\n<h4>\ud83d\udd27\u00a0<strong>Pr\u00e9-requis avant d\u2019utiliser PHP pour cr\u00e9er des sous-domaines<\/strong>\u00a0:<\/h4>\n<ol>\n<li>Assurez-vous que le\u00a0<strong>port 2082<\/strong>\u00a0est ouvert pour permettre \u00e0 PHP d\u2019interagir avec cPanel.<\/li>\n<li>Identifiez le\u00a0<strong>style d\u2019interface de votre cPanel<\/strong>\u00a0en vous rendant sur :<br \/>\n<code class=\"rounded px-1.5 py-0.5 bg-surface-tertiary font-mono text-[0.9em] text-text-primary font-medium\">cPanel &gt; Pr\u00e9f\u00e9rences &gt; Modifier le style (Change Style)<\/code><br \/>\nCela est important pour construire correctement l\u2019URL d\u2019appel dans le code PHP.<\/li>\n<\/ol>\n<hr \/>\n<h3><strong>Le code PHP pour cr\u00e9er un sous-domaine dans cPanel<\/strong><\/h3>\n<h4>\ud83d\udcc1 \u00c9tape 1 : Trouver le chemin du r\u00e9pertoire cPanel<\/h4>\n<p>Pour g\u00e9rer les fichiers du nouveau sous-domaine, nous devons d\u2019abord localiser le\u00a0<strong>chemin du r\u00e9pertoire utilisateur de cPanel<\/strong>. Ensuite, nous allons cr\u00e9er un fichier\u00a0<code class=\"rounded px-1.5 py-0.5 bg-surface-tertiary font-mono text-[0.9em] text-text-primary font-medium\">index.php<\/code>\u00a0dans le sous-domaine contenant le code suivant :<\/p>\n<p>\u2b07\ufe0f<strong> Ajoutez ici le code PHP de cr\u00e9ation initiale<\/strong><\/p>\n<div class=\"not-prose my-0 flex w-full flex-col overflow-clip border border-border text-text-primary rounded-lg not-prose relative\" data-code-block=\"true\" data-sentry-element=\"CodeBlock\" data-sentry-component=\"CodeBlock\" data-sentry-source-file=\"code-block.tsx\">\n<div class=\"code-block_container__lbMX4\" data-sentry-element=\"CodeBlockCode\" data-sentry-source-file=\"code-block.tsx\">\n<pre>if(!$sock) {\r\n    print('Socket error');\r\n    exit();\r\n}\r\n\r\n\/\/ Authenticate username and password for cPanel\r\n$pass = base64_encode(\"$cpanel_user:$cpanel_pass\");\r\n$in = \"GET \/frontend\/$cpanel_skin\/subdomain\/doaddomain.html?\r\nrootdomain=$cpanel_host&amp;domain=$subdomain\\r\\n\";\r\n$in .= \"HTTP\/1.0\\r\\n\";\r\n$in .= \"Host:$cpanel_host\\r\\n\";\r\n$in .= \"Authorization: Basic $pass\\r\\n\";\r\n$in .= \"\\r\\n\";\r\n\/\/ Create a subdomain\r\nfputs($sock, $in);\r\nwhile (!feof($sock)) {\r\n    $result .= fgets($sock, 128);\r\n}\r\nfclose($sock);\r\necho $result;\r\n?&gt;<\/pre>\n<\/div>\n<\/div>\n<hr \/>\n<h4>\u2699\ufe0f \u00c9tape 2 : Ex\u00e9cuter le code pour obtenir le chemin du r\u00e9pertoire cible<\/h4>\n<p>Ensuite, ex\u00e9cutez ce fichier PHP pour r\u00e9cup\u00e9rer dynamiquement le chemin du dossier. Gr\u00e2ce \u00e0 cela, nous pourrons g\u00e9rer les fichiers \u00e0 l\u2019int\u00e9rieur du nouveau sous-domaine de mani\u00e8re automatis\u00e9e \u00e0 l\u2019aide du script suivant :<\/p>\n<p>\u2b07\ufe0f<strong>extrait de code PHP<\/strong><\/p>\n<div class=\"not-prose my-0 flex w-full flex-col overflow-clip border border-border text-text-primary rounded-lg not-prose relative\" data-code-block=\"true\" data-sentry-element=\"CodeBlock\" data-sentry-component=\"CodeBlock\" data-sentry-source-file=\"code-block.tsx\">\n<div class=\"code-block_container__lbMX4\" data-sentry-element=\"CodeBlockCode\" data-sentry-source-file=\"code-block.tsx\">\n<pre>$myfile\r\nfile!\")\r\n$txt = \"Write file contents to store a file...\\n\";\r\nfwrite($myfile, $txt);\r\n\r\nfclose($myfile);<\/pre>\n<\/div>\n<\/div>\n<hr \/>\n<h2><strong>Conclusion<\/strong><\/h2>\n<p>En r\u00e9sum\u00e9, notre \u00e9quipe technique a explor\u00e9 en d\u00e9tail les m\u00e9thodes permettant de <strong>cr\u00e9er un sous-domaine dans cPanel avec PHP<\/strong>. Cette technique facilite grandement la gestion de sous-domaines dynamiques, notamment dans des syst\u00e8mes complexes comme les plateformes utilisateurs, les SaaS ou les environnements de test.<\/p>\n<p>Vous rencontrez des difficult\u00e9s techniques ou souhaitez automatiser davantage votre infrastructure ?<br \/>\n\ud83d\udca1\u00a0<strong>Contactez notre \u00e9quipe d\u2019experts 24\/7<\/strong>\u00a0ou\u00a0<strong>demandez un audit gratuit<\/strong>\u00a0de votre configuration cPanel + PHP pour booster vos performances web !<\/p>\n<p><a href=\"https:\/\/helloweb-hosting.com\/contactez-nous\/\">\ud83d\udc49 Contactez-nous maintenant<\/a> |<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Comment cr\u00e9er un sous-domaine dans cPanel avec PHP ? Les sous-domaines dans cPanel repr\u00e9sentent des sections suppl\u00e9mentaires et ind\u00e9pendantes d\u2019un site Web, rattach\u00e9es \u00e0 un domaine principal. Ils sont utilis\u00e9s pour organiser le contenu en segments distincts, h\u00e9berger divers services ou cr\u00e9er des environnements de d\u00e9veloppement.Pour un ou deux sous-domaines, il est possible de cr\u00e9er [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":18347,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"content-type":"","_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[52],"tags":[113,57,130,119],"class_list":["post-18346","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-nom-de-domain","tag-cpanel","tag-nom-de-domain","tag-php","tag-sous-domaine"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.6 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>cr\u00e9er un sous-domaine dans cPanel avec PHP - helloweb<\/title>\n<meta name=\"description\" content=\"pprenez \u00e0 cr\u00e9er automatiquement cr\u00e9er un sous-domaine dans cPanel avec PHP. Un guide complet pour automatiser la gestion des sous-domaines\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/helloweb-hosting.com\/en\/creer-un-sous-domaine-dans-cpanel-avec-php\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"cr\u00e9er un sous-domaine dans cPanel avec PHP - helloweb\" \/>\n<meta property=\"og:description\" content=\"pprenez \u00e0 cr\u00e9er automatiquement cr\u00e9er un sous-domaine dans cPanel avec PHP. Un guide complet pour automatiser la gestion des sous-domaines\" \/>\n<meta property=\"og:url\" content=\"https:\/\/helloweb-hosting.com\/en\/creer-un-sous-domaine-dans-cpanel-avec-php\/\" \/>\n<meta property=\"og:site_name\" content=\"helloweb\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/helloweb.tn\/?locale=fr_FR\" \/>\n<meta property=\"article:published_time\" content=\"2025-09-16T08:55:41+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2025\/09\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"768\" \/>\n\t<meta property=\"og:image:height\" content=\"398\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"webhelloweb\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@hellowebHosting\" \/>\n<meta name=\"twitter:site\" content=\"@hellowebHosting\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"webhelloweb\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/\"},\"author\":{\"name\":\"webhelloweb\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#\\\/schema\\\/person\\\/ec251bc44668ce0202a162506f90c189\"},\"headline\":\"cr\u00e9er un sous-domaine dans cPanel avec PHP\",\"datePublished\":\"2025-09-16T08:55:41+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/\"},\"wordCount\":453,\"publisher\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/helloweb-hosting.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg\",\"keywords\":[\"cPanel\",\"nom de domain\",\"php\",\"sous-domaine\"],\"articleSection\":[\"Nom de domain\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/\",\"url\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/\",\"name\":\"cr\u00e9er un sous-domaine dans cPanel avec PHP - helloweb\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/helloweb-hosting.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg\",\"datePublished\":\"2025-09-16T08:55:41+00:00\",\"description\":\"pprenez \u00e0 cr\u00e9er automatiquement cr\u00e9er un sous-domaine dans cPanel avec PHP. Un guide complet pour automatiser la gestion des sous-domaines\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/#primaryimage\",\"url\":\"https:\\\/\\\/helloweb-hosting.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg\",\"contentUrl\":\"https:\\\/\\\/helloweb-hosting.com\\\/wp-content\\\/uploads\\\/2025\\\/09\\\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg\",\"width\":768,\"height\":398,\"caption\":\"cr\u00e9er un sous-domaine dans cPanel avec PHP\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/creer-un-sous-domaine-dans-cpanel-avec-php\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\\\/\\\/helloweb-hosting.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"cr\u00e9er un sous-domaine dans cPanel avec PHP\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#website\",\"url\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/\",\"name\":\"helloweb\",\"description\":\"H\u00e9bergement web\",\"publisher\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#organization\",\"name\":\"helloweb\",\"url\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/helloweb-hosting.com\\\/wp-content\\\/uploads\\\/2024\\\/02\\\/cropped-logo-helloweb-2-2.png\",\"contentUrl\":\"https:\\\/\\\/helloweb-hosting.com\\\/wp-content\\\/uploads\\\/2024\\\/02\\\/cropped-logo-helloweb-2-2.png\",\"width\":250,\"height\":114,\"caption\":\"helloweb\"},\"image\":{\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/helloweb.tn\\\/?locale=fr_FR\",\"https:\\\/\\\/x.com\\\/hellowebHosting\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/#\\\/schema\\\/person\\\/ec251bc44668ce0202a162506f90c189\",\"name\":\"webhelloweb\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/8231c936e165997c584dcd851a1312190bf023ef22fc0fe388423abfa5bb526f?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/8231c936e165997c584dcd851a1312190bf023ef22fc0fe388423abfa5bb526f?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/8231c936e165997c584dcd851a1312190bf023ef22fc0fe388423abfa5bb526f?s=96&d=mm&r=g\",\"caption\":\"webhelloweb\"},\"url\":\"https:\\\/\\\/helloweb-hosting.com\\\/en\\\/author\\\/webhelloweb\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"cr\u00e9er un sous-domaine dans cPanel avec PHP - helloweb","description":"pprenez \u00e0 cr\u00e9er automatiquement cr\u00e9er un sous-domaine dans cPanel avec PHP. Un guide complet pour automatiser la gestion des sous-domaines","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/helloweb-hosting.com\/en\/creer-un-sous-domaine-dans-cpanel-avec-php\/","og_locale":"en_US","og_type":"article","og_title":"cr\u00e9er un sous-domaine dans cPanel avec PHP - helloweb","og_description":"pprenez \u00e0 cr\u00e9er automatiquement cr\u00e9er un sous-domaine dans cPanel avec PHP. Un guide complet pour automatiser la gestion des sous-domaines","og_url":"https:\/\/helloweb-hosting.com\/en\/creer-un-sous-domaine-dans-cpanel-avec-php\/","og_site_name":"helloweb","article_publisher":"https:\/\/www.facebook.com\/helloweb.tn\/?locale=fr_FR","article_published_time":"2025-09-16T08:55:41+00:00","og_image":[{"width":768,"height":398,"url":"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2025\/09\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg","type":"image\/jpeg"}],"author":"webhelloweb","twitter_card":"summary_large_image","twitter_creator":"@hellowebHosting","twitter_site":"@hellowebHosting","twitter_misc":{"Written by":"webhelloweb","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/#article","isPartOf":{"@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/"},"author":{"name":"webhelloweb","@id":"https:\/\/helloweb-hosting.com\/en\/#\/schema\/person\/ec251bc44668ce0202a162506f90c189"},"headline":"cr\u00e9er un sous-domaine dans cPanel avec PHP","datePublished":"2025-09-16T08:55:41+00:00","mainEntityOfPage":{"@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/"},"wordCount":453,"publisher":{"@id":"https:\/\/helloweb-hosting.com\/en\/#organization"},"image":{"@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/#primaryimage"},"thumbnailUrl":"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2025\/09\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg","keywords":["cPanel","nom de domain","php","sous-domaine"],"articleSection":["Nom de domain"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/","url":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/","name":"cr\u00e9er un sous-domaine dans cPanel avec PHP - helloweb","isPartOf":{"@id":"https:\/\/helloweb-hosting.com\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/#primaryimage"},"image":{"@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/#primaryimage"},"thumbnailUrl":"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2025\/09\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg","datePublished":"2025-09-16T08:55:41+00:00","description":"pprenez \u00e0 cr\u00e9er automatiquement cr\u00e9er un sous-domaine dans cPanel avec PHP. Un guide complet pour automatiser la gestion des sous-domaines","breadcrumb":{"@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/#primaryimage","url":"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2025\/09\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg","contentUrl":"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2025\/09\/creer-un-sous-domaine-dans-cPanel-avec-PHP.jpg","width":768,"height":398,"caption":"cr\u00e9er un sous-domaine dans cPanel avec PHP"},{"@type":"BreadcrumbList","@id":"https:\/\/helloweb-hosting.com\/creer-un-sous-domaine-dans-cpanel-avec-php\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/helloweb-hosting.com\/"},{"@type":"ListItem","position":2,"name":"cr\u00e9er un sous-domaine dans cPanel avec PHP"}]},{"@type":"WebSite","@id":"https:\/\/helloweb-hosting.com\/en\/#website","url":"https:\/\/helloweb-hosting.com\/en\/","name":"helloweb","description":"Web hosting","publisher":{"@id":"https:\/\/helloweb-hosting.com\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/helloweb-hosting.com\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/helloweb-hosting.com\/en\/#organization","name":"helloweb","url":"https:\/\/helloweb-hosting.com\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/helloweb-hosting.com\/en\/#\/schema\/logo\/image\/","url":"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2024\/02\/cropped-logo-helloweb-2-2.png","contentUrl":"https:\/\/helloweb-hosting.com\/wp-content\/uploads\/2024\/02\/cropped-logo-helloweb-2-2.png","width":250,"height":114,"caption":"helloweb"},"image":{"@id":"https:\/\/helloweb-hosting.com\/en\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/helloweb.tn\/?locale=fr_FR","https:\/\/x.com\/hellowebHosting"]},{"@type":"Person","@id":"https:\/\/helloweb-hosting.com\/en\/#\/schema\/person\/ec251bc44668ce0202a162506f90c189","name":"webhelloweb","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/8231c936e165997c584dcd851a1312190bf023ef22fc0fe388423abfa5bb526f?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/8231c936e165997c584dcd851a1312190bf023ef22fc0fe388423abfa5bb526f?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/8231c936e165997c584dcd851a1312190bf023ef22fc0fe388423abfa5bb526f?s=96&d=mm&r=g","caption":"webhelloweb"},"url":"https:\/\/helloweb-hosting.com\/en\/author\/webhelloweb\/"}]}},"_links":{"self":[{"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/posts\/18346","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/comments?post=18346"}],"version-history":[{"count":2,"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/posts\/18346\/revisions"}],"predecessor-version":[{"id":18350,"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/posts\/18346\/revisions\/18350"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/media\/18347"}],"wp:attachment":[{"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/media?parent=18346"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/categories?post=18346"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/helloweb-hosting.com\/en\/wp-json\/wp\/v2\/tags?post=18346"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}