How to display the current and parent category in WordPress
Need to show the category hierarchy in your theme? Learn how to get the current category and its parent using get_the_category() and get_category_parents().
A PHP application built for a council or another public body has an accessibility duty from its first release, and the duty belongs to the body that commissions it. I build PHP and WordPress projects remotely from Gdynia, by written agreement, as I have since 2006. I design the interface or implement your design. I am not a lawyer. Whether a body is in scope, and what its statement says, is for the body and its legal adviser. What I deliver is a build that can pass an audit and the records the statement draws on.

the Newcastle quayside with the bridges across the Tyne. Newcastle photo by Wilka Hudson, licence CC BY 2.0, via Wikimedia Commons.
The Public Sector Bodies (Websites and Mobile Applications) (No. 2) Accessibility Regulations 2018 were made on 29 August 2018 and came into force on 23 September 2018, according to legislation.gov.uk. Regulation 2 revokes the earlier instrument of almost the same name, and the legislation site notes that the No. 2 version was made in consequence of a defect in it. The legislation site shows that the text has been amended since: in 2022 for the end of the EU framework, and in 2025 by the Transfer of Functions (Digital Government) Order, which changed several references to the Secretary of State.
The core duty is in regulation 6. Public sector bodies must comply with the accessibility requirement, which regulation 3 defines as making a website or mobile application perceivable, operable, understandable and robust. Regulation 6 is subject to regulation 7, the disproportionate burden assessment.
Regulation 3 defines a public sector body as the State, regional or local authorities, bodies governed by public law, and associations formed by those that exist to meet needs in the general interest and have no industrial or commercial character. A body governed by public law has legal personality, is established to meet needs in the general interest, and is mostly financed or supervised by public authorities, or has a board in which public authorities appoint more than half the members.
Regulation 4 sets the exceptions. The regulations do not apply to the websites and apps of public service broadcasters and their subsidiaries. They do not apply to non-governmental organisations unless these provide services that are essential to the public or specifically address people with disabilities. Schools and nurseries are covered only for the content of their sites relating to essential online administrative functions.
The gov.uk guidance restates this in plain words: the requirements cover central and local government and some charities and other bodies. A mobile app for a defined group such as employees or students is not covered. Intranets and extranets are covered where disabled employees working in or with the public sector may use them. That matters for a PHP case-management tool or staff portal: do not assume that an internal system is out of scope.
Regulation 9 says a website or app is presumed to conform with the accessibility requirement to the extent that it conforms to the Level A and AA success criteria of the Web Content Accessibility Guidelines recommended by the World Wide Web Consortium, as amended from time to time. The text was substituted in 2022.
Gov.uk goes a step further and names the version. It says checks must be made against the WCAG 2.2 AA standard, and the update history on the sample statement page says references to WCAG 2.1 were removed on 30 September 2024. For a project that began under 2.1, the acceptance criteria need to be read again.
The practical consequence for a PHP build is that the standard applies to what the browser receives, whatever generates it. Templates, form handling, error messages, generated documents and email links all count. Gov.uk says to test new features with assistive technologies, so the review runs on the rendered output and not on the PHP source.
Four parts of the regulations decide what the build has to include.
Content created by the application. Regulation 4(2) lists what is not covered. Office file formats published before 23 September 2018 are exempt unless needed for active administrative processes. Pre-recorded time-based media published before 23 September 2020 is exempt, and so is live media. Third-party content that is neither funded nor developed by, nor under the control of, the body is exempt. Intranet and extranet content published before 23 September 2019 is exempt until the site undergoes a substantial revision. These exemptions look back to fixed dates. A PDF letter that an application generates today, or a form that is redesigned today, is new content.
Third-party widgets. The exemption in regulation 4(2)(e) covers third-party content that is neither funded nor developed by, nor under the control of, the body. Gov.uk gives social media like buttons as the example. Regulation 4(2)(d) exempts online maps and mapping services as long as essential information is provided in an accessible digital manner for maps intended for navigation, and gov.uk gives an address as the example of such information. Whether a given embedded widget falls under the exemption is for the body to decide with its adviser.
Mobile applications. Regulation 3 defines a mobile application as application software designed and developed by or on behalf of a public sector body for use by the general public on mobile devices. Gov.uk says apps developed for public use are covered, including those with bespoke functionality or branding.
Outsourced work. Gov.uk says the body is legally responsible for its website meeting the requirements even if it is outsourced. The guidance says to agree with suppliers what to fix now and what later, and to state the plan in the statement. For new or renewed contracts it recommends shorter contract terms, open standards, web technologies over native apps where possible, accessibility in the request for quotation, regular accessibility reviews and accessibility in contract evaluation.
Regulation 8 says a body must provide an accessibility statement in accordance with the model statement and keep it under regular review. For a website the statement must be in an accessible format and published on the site. It must include:
Gov.uk adds the compliance status, which is fully, partially or not compliant. Partially compliant means most requirements are met. The statement is published as an HTML page and linked from every page, ideally in the footer, and it is written in plain English. It must be reviewed when there are major changes and at least once a year. Evaluation methods and the plan to fix problems are optional content.
The sample statement on gov.uk has these sections: how accessible this website is, feedback and contact information, enforcement procedure, technical information about the website’s accessibility, compliance status, non-accessible content, what the body is doing to improve accessibility, and preparation of the statement. The sample marks some wording as legally required. Its compliance status wording reads that the website has been tested against the WCAG 2.2 AA standard, and the preparation section asks for the date the statement was first published and the date of the last test.
A developer cannot write the statement for the body, because it states the body’s own position. A developer can hand over what the statement needs: a list of known failures with the reason and the fix plan, the date and method of the last test, and a working route for feedback.
Regulation 13 gives a person the right to notify the body that its site or app fails the requirement, and to request in an accessible format information excluded under regulation 4(2) or 7(4). The body must respond within a reasonable period of time. If it does not, or the person is dissatisfied, the person may complain to the enforcement body.
The contact form from the statement is therefore part of the application, with a process behind it. A minimal version stores each report with a timestamp, so that a response time can be shown later:
<?php
declare(strict_types=1);
function recordAccessibilityReport(PDO $db, string $pageUrl, string $message, ?string $contact): int
{
$stmt = $db->prepare(
'INSERT INTO accessibility_reports (page_url, message, contact, received_at)
VALUES (?, ?, ?, ?)'
);
$stmt->execute([$pageUrl, $message, $contact, gmdate('Y-m-d H:i:s')]);
return (int) $db->lastInsertId();
}The code is the easy part. The body decides who reads the table, what counts as a reasonable response time and how an accessible alternative is produced. Regulation 7(4) also asks for accessible alternatives to documents that are not available on the site or app when the body relies on a disproportionate burden.
Regulation 7 lets a body decline to comply to the extent that compliance would impose a disproportionate burden, and it requires the body to perform an assessment first. The assessment takes account of the size, resources and nature of the body, and of the estimated costs and benefits for the body in relation to the estimated benefits for people with disabilities, considering the frequency and duration of use. If the body decides that the burden is disproportionate, it must explain in the statement which parts it could not meet and, where appropriate, provide accessible alternatives.
Gov.uk is direct about the limits: lack of time, lack of knowledge, or not having made accessibility a priority cannot be counted. It also says the assessment is legally required if a body claims that a detailed audit is disproportionate, and that reasonable adjustments under the Equality Act 2010 still apply. A developer should not offer the burden argument as a way to skip a fix. The decision belongs to the body, with the assessment on record.
Regulation 12 treats a failure to comply with the accessibility requirement as a failure to make a reasonable adjustment under sections 20, 21 and 29 of the Equality Act 2010, or the corresponding sections of the Disability Discrimination Act 1995 in Northern Ireland. Regulation 11 names the Equality and Human Rights Commission as the enforcement body for bodies that must comply with the Equality Act 2010, and the Equality Commission for Northern Ireland for those under the 1995 act.
Regulation 14 covers the statement. The Secretary of State may assess whether a body has complied with regulation 8 and may require information, which the body must provide within 28 days. If the response does not demonstrate compliance, the Secretary of State makes a determination, the body may ask for a review within 28 days, and an upheld determination is published together with the body’s name.
On monitoring, regulation 10 requires the Secretary of State to monitor compliance and to publish a report on the outcome by 23 December 2024 and every three years after. Gov.uk says the Government Digital Service examines a sample of websites and apps each year and can request information and access to intranets, extranets, apps and websites. That page still names the Central Digital and Data Office in one passage, while its update history says responsibility moved in 2022, so check the current wording before you cite either.
Other PHP work for public bodies and companies is listed on the PHP developer page.
If you commission or maintain a PHP application for a public body in the North East, send me the application, its users, your current statement and your deadline through the contact form. A first written estimate for a council project costs nothing. Whether the body is in scope and what its statement says is for the body and its legal adviser to decide.
Examples of my work.
Ogloszenia.osemka.pl is a classifieds portal that operated as a subdomain of the social platform Osemka.pl, designed and implemented in 2006-2007. The goal w...
Olsztyn.com.pl is one of the key projects in my WordPress developer portfolio, serving as a comprehensive city portal dedicated to the residents of Olsztyn. ...
A package of various special banners for the osemka.pl website
Describe your project by e-mail. I reply within 24 hours.
Describe your projectNeed to show the category hierarchy in your theme? Learn how to get the current category and its parent using get_the_category() and get_category_parents().
Need to get the URL of the first image or link in an article? Prefer DOMDocument over regex. Ready-made WordPress PHP for developers.
On 1 December 2026 Taylor Otwell shipped the Laravel Rust beta, and Laravel Go followed a day later. What the framework contains, what the 18x benchmark really measures, what happens to Laravel PHP and WordPress, and when a rewrite makes sense.
Custom WordPress engineering and architecture.
Scalable headless, ERP, and AI architecture for enterprise.
Stores, checkout flow, and sales logic.
Stability, updates, and post-launch support.
What the monthly care fee covers and what changes it.
Business process automation around WordPress and company systems.
Headless WordPress, Sanity, Strapi, and Contentful with Astro or Next.js.
Astro, MDX, edge delivery, and Core Web Vitals measured on real traffic.

How to start as a WordPress developer in 2026. Local environment, theme and plugin development, REST API and headless paths, security and Core Web Vitals. A practitioner playbook that does not waste your first month.

WordPress 7.0 with AI Client against Astro 7 with the Rust compiler and Vite 8. Speed, cost, SEO and security compared, plus the real bill for my own Astro 6 to 7 migration.

A detailed comparison table of EmDash CMS and WordPress across architecture, security, plugins, AI features, content model, hosting, and ecosystem maturity.