{"id":16040738,"url":"https://github.com/ryelle/one-page-layout","last_synced_at":"2026-05-10T11:35:59.765Z","repository":{"id":25826363,"uuid":"29265633","full_name":"ryelle/One-Page-Layout","owner":"ryelle","description":"A quick plugin to manage \"one-page\" layouts in WordPress","archived":false,"fork":false,"pushed_at":"2015-01-14T22:39:57.000Z","size":128,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-14T03:46:30.013Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ryelle.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-01-14T21:02:25.000Z","updated_at":"2018-09-23T02:07:15.000Z","dependencies_parsed_at":"2022-07-24T07:45:04.755Z","dependency_job_id":null,"html_url":"https://github.com/ryelle/One-Page-Layout","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryelle%2FOne-Page-Layout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryelle%2FOne-Page-Layout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryelle%2FOne-Page-Layout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryelle%2FOne-Page-Layout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ryelle","download_url":"https://codeload.github.com/ryelle/One-Page-Layout/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241715023,"owners_count":20007913,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-08T23:21:11.205Z","updated_at":"2026-05-10T11:35:59.711Z","avatar_url":"https://github.com/ryelle.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"One Page Layouts\n================\n\nThis is a plugin for theme developers. When used with the Menu Customizer, it gives you a way to manage a \"one-page\" site of content blocks in the customizer.\n\n### How to set up (in code)\n\nSet up via `add_theme_support`. Here are the defaults:\n\n\tadd_theme_support( 'one-page-layout', array(\n\t\t'menu-name'        =\u003e __( 'One Page Layout', 'one-page' ),\n\t\t'posts-template'   =\u003e 'content',\n\t\t'custom-format'    =\u003e '\u003cdiv id=\"%1$s\" class=\"hentry custom\"\u003e\u003ch1 class=\"entry-title\"\u003e\u003ca href=\"%2$s\"\u003e%3$s\u003c/a\u003e\u003c/h1\u003e \u003cdiv class=\"entry-summary\"\u003e\u003cp\u003e%4$s\u003c/p\u003e\u003c/div\u003e\u003c/div\u003e',\n\t\t'archive-template' =\u003e 'content',\n\t\t'archive-before'   =\u003e '\u003cdiv id=\"%1$s\" class=\"archive %2$s\"\u003e\u003ch1 class=\"page-title\"\u003e%3$s\u003c/h1\u003e',\n\t\t'archive-after'    =\u003e '\u003c/div\u003e',\n\t\t'archive-count'    =\u003e '6',\n\t) );\n\nSince menus can contain posts, pages, taxonomy archives, and custom links, the configuration is a little involved. For displaying posts \u0026 pages, we grab the template defined in `posts-template` (content.php by default).\n\nTaxonomy archives are trickier. They're wrapped in `archive-before` and `archive-after`. The placeholders in `archive-before` are 1: an ID, 2: the taxonomy being displayed, 3: the name of this taxonomy. Each post in the archive is displayed with `archive-template` (content.php, again). It'll only display `archive-count` posts. Note: does not take into account non-post post types.\n\nLastly, custom links are output from a format string; 1: an ID, 2: the URL, 3: link title, and 4: description.\n\n### How to set up (in WordPress)\n\nCreate a new menu with the pages/posts/categories etc that you want on your front page. Set this menu to the \"One Page Layout\" menu location (theme devs can rename this).\n\n### Displaying your layout\n\nUse this function in your template, most likely front-page.php, instead of the loop.\n\n\t\u003c?php onepage_layout(); ?\u003e\n\nIf you're using [Menu Customizer](https://github.com/voldemortensen/menu-customizer), you can jump into the customizer and add/manage items in the menu, and see your changes in real-time.\n\n### Try it out\n\nDownload [\"One Page Aventurine\"](https://cloudup.com/cMikaM9p2Oa), a child theme of [Aventurine](https://wordpress.org/themes/aventurine), a quick proof-of-concept for how to use this in a theme.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryelle%2Fone-page-layout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fryelle%2Fone-page-layout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryelle%2Fone-page-layout/lists"}