Project page and archive
This section covers what visitors see after they open a project: the page template, navigation between projects, password protection and the archive.
Project page template
A project page shows what you built in the editor, followed by the navigation to neighbouring projects. Which template wraps it depends on your theme.
| Theme type | Template used |
|---|---|
| Block theme (Twenty Twenty-Five and similar) | The theme’s own Single template. The plugin adds the project navigation after the content |
Classic theme with its own single-portfolios.php | The theme’s file. It always has priority |
| Any other classic theme | The plugin’s simple template: site header, project title, content, navigation, site footer |
The plugin’s template is deliberately plain: a centred column up to 1248 px wide, with the title in your theme’s heading style. Everything inside the content is yours.
To design the page yourself, copy templates/single-portfolios.php from the plugin folder into your theme, keep the file name, and edit the copy. See “Templates and functions” in the Developers section.
Navigation between projects
At the bottom of each project page visitors get links to the previous and next project. The options are in Portfolio → Settings → Single project → Navigation.
Options
| Setting | What it does | Default |
|---|---|---|
| Previous / next navigation | Shows or hides the navigation on every project page | On |
| Style | One of four designs, see below | Button group |
| All projects icon | The icon in the middle of the navigation, shown at 20×20 px. Keep the default four squares or upload your own image. Shown for Button group and Arrows | four squares |
| Same category only | Step through projects of the current project’s category instead of all projects | Off |
| Loop | After the last project, continue from the first one, and the other way round | On |
Style, icon, Same category only and Loop are hidden while the navigation is switched off.
Styles
| Style | Looks like |
|---|---|
| Button group | One bordered group: Previous, a square “all projects” button, Next. Centred |
| Arrows | A round arrow at each edge with the words Previous and Next, and the “all projects” button in the middle |
| Titles | Two columns: a small “Previous” / “Next” caption and the project title under it |
| Cards | Two bordered cards with the project thumbnail, a caption and the title |
On phones Button group and Arrows show only the arrows; Titles and Cards stack in one column.
Which project is “next”
The navigation follows the order of your grid, newest first. Previous leads to the project shown before the current one in the grid (the newer one) and Next to the one after it (the older one). This is the opposite of a blog and matches how visitors move through a grid.
With Loop off, the first project has only Next and the last has only Previous. The remaining button stays on its own side.
The “all projects” button
The middle button takes the visitor back to the list of projects.
- If the visitor came from a portfolio block, the button returns to that page, even after several Previous / Next clicks.
- If the visitor opened the project directly, for example from a search engine, the button leads to the Portfolio page set in Settings → General → Archive.
- If the archive is turned off there, the button is not shown.
The navigation is hidden when there is only one project, and on a password-protected project until the password is entered.
Password-protected projects
A project can be locked with a password, for example work under NDA that only a client should see. The plugin shows its own password form, which looks the same on every theme.
Protect a project
- Open the project in the editor.
- In the sidebar, click the value next to Status (or Visibility in older WordPress versions).
- Choose Password protected and type a password.
- Click Update.
What visitors see
Opening the project shows a form over the blurred page: a lock icon, the heading “This project is protected”, a password field with a show/hide button, and the View project button. The button becomes active once something is typed.
- A wrong password shows “Incorrect password. Please try again.” under the field.
- After the right password the visitor sees the project. WordPress remembers the password in that browser for about ten days.
- The Previous / Next navigation is hidden until the project is unlocked.
Contact link
To show “No password? Contact the author” under the form, enter an address in Portfolio → Settings → Single project → Password protection → Password contact link. It can be a page (https://example.com/contact) or an email link (mailto:you@example.com). Leave it empty to hide the line.
In the grid and navigation
The lock is shown to everyone, including you when you are logged in, so you can tell at a glance which projects are protected. WordPress normally adds “Protected:” in front of such titles; the plugin removes that prefix for projects.
Protected projects stay visible in the portfolio block with their title and thumbnail, marked by a round lock badge in the top-right corner of the thumbnail. In the List layout the badge sits next to the title. The Titles and Cards navigation styles and the search results show a small lock next to the title. To keep a project out of the grid entirely, set it to Private or Draft instead.
Archive and search shortcode
The archive is the page that lists all projects; the search shortcode puts a project search button anywhere on the site.
The portfolio page
Choose what “all projects” means in Portfolio → Settings → General → Archive → Portfolio page.
| Option | Result |
|---|---|
| Automatic archive (default) | WordPress builds the list at /portfolios/ |
| One of your pages | “All projects” links lead to that page, and /portfolios/ redirects to it |
| No archive | There is no list page; /portfolios/ returns “not found” |
The recommended setup is a normal page with the Sparrow Portfolio block on it, selected here. You then control the layout, filter and styles of your main portfolio page from the block.
How the automatic archive looks:
| Theme type | Result |
|---|---|
| Block theme | The theme’s own Archive template |
Classic theme with archive-portfolios.php or archive.php | The theme’s template. Many themes show it like a blog |
| Classic theme without those files | The plugin’s template: a title and the portfolio block with filter, sorting, search and pagination |
Search shortcode
[sparrow_portfolio_search] shows the same search button and dropdown as the block, anywhere: a Shortcode block, a widget, a page builder, or the site header.
Copy it from Portfolio → Settings → General → Search, where the Copy button puts it on the clipboard.
| Attribute | Values | Default |
|---|---|---|
align | left, center, right: the side the dropdown is anchored to. Use right for a button near the right edge of the header | right |
placeholder | Hint text in the field | Search projects |
radius | Rounding of the field in pixels, 0–22 | 22 |
button_radius | Rounding of the button in pixels, 0–18 | 18 |
Example: [sparrow_portfolio_search align="left" placeholder="Find a project"]
Show all results opens the Portfolio page with the search applied. Any portfolio block on that page shows only the matching projects.
Search in the header or menu
WordPress menus cannot hold shortcodes inside menu items, so place the shortcode next to the menu:
- Elementor: add a Shortcode widget beside the menu widget in your header template.
- Block themes: add a Shortcode block in the header template part.
- Classic themes: use a header widget area, or ask your developer to add it to
header.php.
Then turn on Portfolio → Settings → General → Search → Load on every page. The search styles are then loaded in the page head on every page, so the button never appears unstyled for a moment while the page loads.
Still stuck? Write to support.
Contact