{"id":2464,"date":"2024-09-17T17:03:01","date_gmt":"2024-09-17T16:03:01","guid":{"rendered":"https:\/\/codeflarelimited.com\/blog\/?p=2464"},"modified":"2024-09-19T10:50:15","modified_gmt":"2024-09-19T09:50:15","slug":"php-namespaces","status":"publish","type":"post","link":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/","title":{"rendered":"Understanding PHP Namespaces"},"content":{"rendered":"\n<p>In PHP, namespaces are a way to encapsulate items such as classes, functions, and constants to avoid name conflicts in large applications or projects that use multiple libraries or third-party code. Namespaces were introduced in PHP 5.3 and have since become an essential feature in modern PHP development.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Why Use PHP Namespaces?<\/h3>\n\n\n\n<p>PHP developers often encounter situations where they may want to reuse code from different libraries, and sometimes these libraries can have functions or classes with the same names. Without namespaces, this leads to naming collisions. By grouping code under a namespace, you ensure that classes and functions can coexist without conflicts, even if they have the same name.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">Benefits of PHP Namespaces:<\/h4>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Prevents naming conflicts:<\/strong> Helps manage and avoid conflicts in names of classes, functions, and constants.<\/li>\n\n\n\n<li><strong>Organizes code:<\/strong> Useful for structuring large codebases in a more logical way.<\/li>\n\n\n\n<li><strong>Enables autoloading:<\/strong> Works seamlessly with PHP&#8217;s autoloading mechanism for easier inclusion of classes.<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\">Defining a Namespace in PHP<\/h3>\n\n\n\n<p>Defining a namespace in PHP is simple. You use the <code>namespace<\/code> keyword at the top of the file before any code. Here&#8217;s a basic example:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">&lt;?php\nnamespace MyApp\\Models;\n\nclass User {\n    public function __construct() {\n        echo \"User model loaded!\";\n    }\n}\n?&gt;\n<\/code><\/pre>\n\n\n\n<p>In this example, the class <code>User<\/code> belongs to the <code>MyApp\\Models<\/code> namespace. To use this class outside of the file, you would need to reference it with the fully qualified name.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Accessing Namespaced Classes<\/h3>\n\n\n\n<p>There are several ways to access a class, function, or constant from a namespace.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Using the Fully Qualified Name:<\/strong><\/li>\n<\/ol>\n\n\n\n<p>You can refer to the fully qualified name to avoid any ambiguity. For instance:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">&lt;?php\nrequire 'User.php';\n\n$user = new \\MyApp\\Models\\User();\n?&gt;\n<\/code><\/pre>\n\n\n\n<p>Here, the <code>\\MyApp\\Models\\User<\/code> refers to the class with the full namespace.<\/p>\n\n\n\n<ol start=\"2\" class=\"wp-block-list\">\n<li><strong>Using the <code>use<\/code> Keyword:<\/strong><\/li>\n<\/ol>\n\n\n\n<p>To simplify, you can import a specific class using the <code>use<\/code> keyword:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">&lt;?php\nuse MyApp\\Models\\User;\n\n$user = new User();\n?&gt;\n<\/code><\/pre>\n\n\n\n<p>By importing the class, you don&#8217;t have to repeatedly use the full namespace path.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Nested Namespaces<\/h3>\n\n\n\n<p>Namespaces can also be nested, making it easy to organize code hierarchically. Here&#8217;s an example:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">&lt;?php\nnamespace MyApp\\Controllers\\Admin;\n\nclass DashboardController {\n    public function index() {\n        echo \"Admin dashboard\";\n    }\n}\n?&gt;\n<\/code><\/pre>\n\n\n\n<p>This allows for more specific grouping of code. The class <code>DashboardController<\/code> belongs to the <code>MyApp\\Controllers\\Admin<\/code> namespace.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Namespaces and Autoloading<\/h3>\n\n\n\n<p>Namespaces work efficiently with autoloaders in PHP, such as Composer\u2019s autoloader. By organizing your classes with namespaces, autoloaders can automatically load the required files without manual <code>require<\/code> or <code>include<\/code> statements. This makes your codebase cleaner and easier to maintain.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Global Namespace<\/h3>\n\n\n\n<p>If you ever need to access a PHP core class, function, or constant within a namespaced file, you can use the global namespace by prefixing the core element with a backslash (<code>\\<\/code>). For example:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">&lt;?php\nnamespace MyApp;\n\necho \\strlen(\"Namespace Example\");\n?&gt;\n<\/code><\/pre>\n\n\n\n<p>In this case, <code>\\strlen<\/code> refers to the global <code>strlen()<\/code> function, preventing any conflicts with any custom <code>strlen<\/code> functions in your namespace.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Example of Namespaced Code:<\/h3>\n\n\n\n<p>Let\u2019s consider two classes with the same name from different namespaces:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">&lt;?php\n\/\/ file: MyApp\/Models\/User.php\nnamespace MyApp\\Models;\n\nclass User {\n    public function getUser() {\n        return \"User from Models\";\n    }\n}\n\n\/\/ file: AnotherLibrary\/User.php\nnamespace AnotherLibrary;\n\nclass User {\n    public function getUser() {\n        return \"User from Another Library\";\n    }\n}\n?&gt;\n<\/code><\/pre>\n\n\n\n<p>Now, using these two classes together in the same script:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code lang=\"php\" class=\"language-php\">&lt;?php\nrequire 'MyApp\/Models\/User.php';\nrequire 'AnotherLibrary\/User.php';\n\nuse MyApp\\Models\\User as ModelsUser;\nuse AnotherLibrary\\User as LibraryUser;\n\n$modelUser = new ModelsUser();\necho $modelUser-&gt;getUser();  \/\/ Output: User from Models\n\n$libraryUser = new LibraryUser();\necho $libraryUser-&gt;getUser();  \/\/ Output: User from Another Library\n?&gt;\n<\/code><\/pre>\n\n\n\n<p>In this example, the <code>User<\/code> class from two different namespaces (<code>MyApp\\Models<\/code> and <code>AnotherLibrary<\/code>) is used without any conflict by aliasing the classes with <code>as<\/code>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Conclusion<\/h3>\n\n\n\n<p>PHP namespaces are an essential feature in modern PHP development that allows you to avoid naming conflicts and organize your code better. By using namespaces, you can create modular, reusable code that works seamlessly with autoloaders like Composer. Understanding how to define, use, and access namespaces is crucial for building scalable applications in PHP.<\/p>\n\n\n\n<p><a href=\"https:\/\/codeflarelimited.com\/blog\/php-standard-recommendations\/\">Understanding PHP Standard Recommendations (PSR)<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In PHP, namespaces are a way to encapsulate items such as classes, functions, and constants to avoid name<\/p>\n","protected":false},"author":3,"featured_media":2469,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[87],"tags":[99],"class_list":["post-2464","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-php","tag-software-development"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>PHP Namespaces<\/title>\n<meta name=\"description\" content=\"Learn about PHP Namespaces and how they help organize your code, prevent naming conflicts, and improve modularity in large projects.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"PHP Namespaces\" \/>\n<meta property=\"og:description\" content=\"Learn about PHP Namespaces and how they help organize your code, prevent naming conflicts, and improve modularity in large projects.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/\" \/>\n<meta property=\"article:published_time\" content=\"2024-09-17T16:03:01+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-09-19T09:50:15+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2024\/09\/IMG-20240918-WA0005.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1120\" \/>\n\t<meta property=\"og:image:height\" content=\"630\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Kene Samuel\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"TechArticle\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/\"},\"author\":{\"name\":\"Kene Samuel\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#\\\/schema\\\/person\\\/c501609bab46c16807eb32106074f206\"},\"headline\":\"Understanding PHP Namespaces\",\"datePublished\":\"2024-09-17T16:03:01+00:00\",\"dateModified\":\"2024-09-19T09:50:15+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/\"},\"wordCount\":518,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/09\\\/IMG-20240918-WA0005.jpg\",\"keywords\":[\"software development\"],\"articleSection\":[\"php\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/\",\"url\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/\",\"name\":\"PHP Namespaces\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/09\\\/IMG-20240918-WA0005.jpg\",\"datePublished\":\"2024-09-17T16:03:01+00:00\",\"dateModified\":\"2024-09-19T09:50:15+00:00\",\"description\":\"Learn about PHP Namespaces and how they help organize your code, prevent naming conflicts, and improve modularity in large projects.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#primaryimage\",\"url\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/09\\\/IMG-20240918-WA0005.jpg\",\"contentUrl\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/09\\\/IMG-20240918-WA0005.jpg\",\"width\":1120,\"height\":630},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php-namespaces\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"php\",\"item\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/php\\\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Understanding PHP Namespaces\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/\",\"name\":\"\",\"description\":\"Sustainable solutions\",\"publisher\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#organization\",\"name\":\"Codeflare Limited\",\"url\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/11\\\/codeflare.png\",\"contentUrl\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/11\\\/codeflare.png\",\"width\":1040,\"height\":263,\"caption\":\"Codeflare Limited\"},\"image\":{\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/#\\\/schema\\\/person\\\/c501609bab46c16807eb32106074f206\",\"name\":\"Kene Samuel\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/3e1716cd715a5b5491e1f2da373b52f2f73aeb37d268baff34719116e386d848?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/3e1716cd715a5b5491e1f2da373b52f2f73aeb37d268baff34719116e386d848?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/3e1716cd715a5b5491e1f2da373b52f2f73aeb37d268baff34719116e386d848?s=96&d=mm&r=g\",\"caption\":\"Kene Samuel\"},\"url\":\"https:\\\/\\\/codeflarelimited.com\\\/blog\\\/author\\\/kene\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"PHP Namespaces","description":"Learn about PHP Namespaces and how they help organize your code, prevent naming conflicts, and improve modularity in large projects.","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:\/\/codeflarelimited.com\/blog\/php-namespaces\/","og_locale":"en_US","og_type":"article","og_title":"PHP Namespaces","og_description":"Learn about PHP Namespaces and how they help organize your code, prevent naming conflicts, and improve modularity in large projects.","og_url":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/","article_published_time":"2024-09-17T16:03:01+00:00","article_modified_time":"2024-09-19T09:50:15+00:00","og_image":[{"width":1120,"height":630,"url":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2024\/09\/IMG-20240918-WA0005.jpg","type":"image\/jpeg"}],"author":"Kene Samuel","twitter_card":"summary_large_image","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"TechArticle","@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#article","isPartOf":{"@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/"},"author":{"name":"Kene Samuel","@id":"https:\/\/codeflarelimited.com\/blog\/#\/schema\/person\/c501609bab46c16807eb32106074f206"},"headline":"Understanding PHP Namespaces","datePublished":"2024-09-17T16:03:01+00:00","dateModified":"2024-09-19T09:50:15+00:00","mainEntityOfPage":{"@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/"},"wordCount":518,"commentCount":0,"publisher":{"@id":"https:\/\/codeflarelimited.com\/blog\/#organization"},"image":{"@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#primaryimage"},"thumbnailUrl":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2024\/09\/IMG-20240918-WA0005.jpg","keywords":["software development"],"articleSection":["php"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/","url":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/","name":"PHP Namespaces","isPartOf":{"@id":"https:\/\/codeflarelimited.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#primaryimage"},"image":{"@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#primaryimage"},"thumbnailUrl":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2024\/09\/IMG-20240918-WA0005.jpg","datePublished":"2024-09-17T16:03:01+00:00","dateModified":"2024-09-19T09:50:15+00:00","description":"Learn about PHP Namespaces and how they help organize your code, prevent naming conflicts, and improve modularity in large projects.","breadcrumb":{"@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/codeflarelimited.com\/blog\/php-namespaces\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#primaryimage","url":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2024\/09\/IMG-20240918-WA0005.jpg","contentUrl":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2024\/09\/IMG-20240918-WA0005.jpg","width":1120,"height":630},{"@type":"BreadcrumbList","@id":"https:\/\/codeflarelimited.com\/blog\/php-namespaces\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/codeflarelimited.com\/blog\/"},{"@type":"ListItem","position":2,"name":"php","item":"https:\/\/codeflarelimited.com\/blog\/php\/"},{"@type":"ListItem","position":3,"name":"Understanding PHP Namespaces"}]},{"@type":"WebSite","@id":"https:\/\/codeflarelimited.com\/blog\/#website","url":"https:\/\/codeflarelimited.com\/blog\/","name":"","description":"Sustainable solutions","publisher":{"@id":"https:\/\/codeflarelimited.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/codeflarelimited.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/codeflarelimited.com\/blog\/#organization","name":"Codeflare Limited","url":"https:\/\/codeflarelimited.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/codeflarelimited.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2020\/11\/codeflare.png","contentUrl":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2020\/11\/codeflare.png","width":1040,"height":263,"caption":"Codeflare Limited"},"image":{"@id":"https:\/\/codeflarelimited.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/codeflarelimited.com\/blog\/#\/schema\/person\/c501609bab46c16807eb32106074f206","name":"Kene Samuel","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/3e1716cd715a5b5491e1f2da373b52f2f73aeb37d268baff34719116e386d848?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/3e1716cd715a5b5491e1f2da373b52f2f73aeb37d268baff34719116e386d848?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/3e1716cd715a5b5491e1f2da373b52f2f73aeb37d268baff34719116e386d848?s=96&d=mm&r=g","caption":"Kene Samuel"},"url":"https:\/\/codeflarelimited.com\/blog\/author\/kene\/"}]}},"jetpack_featured_media_url":"https:\/\/codeflarelimited.com\/blog\/wp-content\/uploads\/2024\/09\/IMG-20240918-WA0005.jpg","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/posts\/2464","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/comments?post=2464"}],"version-history":[{"count":1,"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/posts\/2464\/revisions"}],"predecessor-version":[{"id":2465,"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/posts\/2464\/revisions\/2465"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/media\/2469"}],"wp:attachment":[{"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/media?parent=2464"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/categories?post=2464"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/codeflarelimited.com\/blog\/wp-json\/wp\/v2\/tags?post=2464"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}