1. Component Guide
  2. Attachment link
  3. Embedded in govspeak
Attachment link example

Embedded in govspeak

This component can be embedded in Govspeak with the [AttachmentLink:] code.

How it looks (preview)

Some introductory information about Temporary snow ploughs: guidance note (PDF, 19.5 KB, 1 page) .

How to call this example

<%= render "govuk_publishing_components/components/govspeak" do %>
  <p>Some introductory information about <%= render "govuk_publishing_components/components/attachment_link", {
  attachment: {
    title: "Temporary snow ploughs: guidance note",
    url: "https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/259634/temporary-snow-ploughs.pdf",
    filename: "temporary-snow-ploughs.pdf",
    content_type: "application/pdf",
    file_size: 20000,
    number_of_pages: 1
  }
} %>.</p>
<% end %>