{"id":2619,"date":"2021-10-05T06:06:15","date_gmt":"2021-10-05T06:06:15","guid":{"rendered":"https:\/\/ownwebservers.com\/kb\/?p=2619"},"modified":"2021-10-05T06:06:15","modified_gmt":"2021-10-05T06:06:15","slug":"customizing-the-user-list-layout-in-drupal","status":"publish","type":"post","link":"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/","title":{"rendered":"Customizing The User List Layout In Drupal"},"content":{"rendered":"<p>In this article we are going to understand how to override the default user list page layout while using phptemplate primarily based themes and also the profile.module. you&#8217;ll see the user list page after you go to any web address followed by \u2018profile\u2019 for example\u2013<\/p>\n<p><code>www.example.com\/profile<\/code><\/p>\n<p>With the utilization of this override it&#8217;s possible for you to manage the profile fields that are displayed and you&#8217;ll additionally control their positioning\/layout.<\/p>\n<p>Step 1<\/p>\n<p>Open a text editor like notepad.exe, create a file named template.php with the utilization of the subsequent snippet. If you have already have a template.php file, simply add it to your existing one.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-2621 aligncenter\" src=\"https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-1-300x167.jpg\" alt=\"drupal-1\" width=\"621\" height=\"346\" srcset=\"https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-1-300x167.jpg 300w, https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-1.jpg 621w\" sizes=\"auto, (max-width: 621px) 100vw, 621px\" \/><\/p>\n<p>You must be sure to upload the template.php file to your active theme folder.<\/p>\n<p>Step 2<\/p>\n<p>The template.php snippet catches the default user list page layout before it&#8217;s displayed and it additionally appearance within the same folder for profile_profile.tpl.php file that determines the new layout.<\/p>\n<p>A very simple example of a<\/p>\n<p><code>profile_profile.tpl.php<\/code><\/p>\n<p>file maybe illustrated as follows<\/p>\n<p>Here the custom extended fields that are setup are called profile_city, profile_country, profile_postcode<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"size-medium wp-image-2622 aligncenter\" src=\"https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-2-300x110.jpg\" alt=\"drupal-2\" width=\"623\" height=\"229\" srcset=\"https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-2-300x110.jpg 300w, https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-2.jpg 623w\" sizes=\"auto, (max-width: 623px) 100vw, 623px\" \/><\/p>\n<p>Upload your profile_profile.tpl.php file to your active theme folder and go to your user list page at<\/p>\n<p><code>www.example.com\/profile<\/code><\/p>\n<p>to view the new layout.<\/p>\n<p>You can perform the following functions Once the process is complete:<\/p>\n<p>According to your preference Name the classes or change the layout.<br \/>\nEdit your style.css file or whatever your main style sheet is termed so as to regulate the category designs.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this article we are going to understand how to override the default user list page layout while using phptemplate primarily based themes and also the profile.module. you&#8217;ll see the user list page after you go to any web address followed by \u2018profile\u2019 for example\u2013 www.example.com\/profile With the utilization of this override it&#8217;s possible for [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[23],"tags":[],"class_list":["post-2619","post","type-post","status-publish","format-standard","hentry","category-tutorials"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v15.2.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Customizing The User List Layout In Drupal - OWS KB<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Customizing The User List Layout In Drupal - OWS KB\" \/>\n<meta property=\"og:description\" content=\"In this article we are going to understand how to override the default user list page layout while using phptemplate primarily based themes and also the profile.module. you&#8217;ll see the user list page after you go to any web address followed by \u2018profile\u2019 for example\u2013 www.example.com\/profile With the utilization of this override it&#8217;s possible for [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/\" \/>\n<meta property=\"og:site_name\" content=\"OWS KB\" \/>\n<meta property=\"article:published_time\" content=\"2021-10-05T06:06:15+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-1-300x167.jpg\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\">\n\t<meta name=\"twitter:data1\" content=\"admin\">\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\">\n\t<meta name=\"twitter:data2\" content=\"1 minute\">\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/#website\",\"url\":\"https:\/\/ownwebservers.com\/kb\/\",\"name\":\"OWS KB\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":\"https:\/\/ownwebservers.com\/kb\/?s={search_term_string}\",\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/#primaryimage\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/ownwebservers.com\/kb\/wp-content\/uploads\/2021\/10\/drupal-1.jpg\",\"width\":621,\"height\":346,\"caption\":\"drupal-1\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/#webpage\",\"url\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/\",\"name\":\"Customizing The User List Layout In Drupal - OWS KB\",\"isPartOf\":{\"@id\":\"https:\/\/ownwebservers.com\/kb\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/#primaryimage\"},\"datePublished\":\"2021-10-05T06:06:15+00:00\",\"dateModified\":\"2021-10-05T06:06:15+00:00\",\"author\":{\"@id\":\"https:\/\/ownwebservers.com\/kb\/#\/schema\/person\/4a40fe3fe17a08ddd1d7c113668e75f2\"},\"breadcrumb\":{\"@id\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"item\":{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/\",\"url\":\"https:\/\/ownwebservers.com\/kb\/\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"position\":2,\"item\":{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/\",\"url\":\"https:\/\/ownwebservers.com\/kb\/customizing-the-user-list-layout-in-drupal\/\",\"name\":\"Customizing The User List Layout In Drupal\"}}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/#\/schema\/person\/4a40fe3fe17a08ddd1d7c113668e75f2\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/ownwebservers.com\/kb\/#personlogo\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/ba5db5841d48bd7517bb2583e13983e6d2fa56a4099a0b3c61ad2daefc321303?s=96&d=mm&r=g\",\"caption\":\"admin\"},\"sameAs\":[\"https:\/\/ownwebservers.com\/kb\"]}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","_links":{"self":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts\/2619","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/comments?post=2619"}],"version-history":[{"count":1,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts\/2619\/revisions"}],"predecessor-version":[{"id":2623,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/posts\/2619\/revisions\/2623"}],"wp:attachment":[{"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/media?parent=2619"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/categories?post=2619"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ownwebservers.com\/kb\/wp-json\/wp\/v2\/tags?post=2619"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}