I have a template with a slideshow in it. Each slide consists of:
For the first
You could use the staticpagepicker
widget if you don't need to link to CMS pages.
https://github.com/rainlab/pages-plugin#backend-forms
If you need to select from a list of static pages in your own backend forms, you can use the
staticpagepicker
widget:fields: field_name: label: Static Page type: staticpagepicker
The field's assigned value will be the static page's file name, which can be used to link to the page as described above.
In your layout file:
{variable name="button_page" label="Button URL" type="staticpagepicker"}{/variable}
Button
Because CMS Pages aren't listed in this widget, you could always setup an alternative field to offer more flexibility to the user.
{variable name="button_url" label="Button (URL)" type="text" span="left" comment="Leave empty if using Button (Page) instead" placeholder="http://"}{/variable}
{variable name="button_page" label="Button (Page)" type="staticpagepicker" span="right" comment="Used if Button (URL) is left empty"}{/variable}
Button