Page specific PHP code

Phplugins is very powerful as it can be used to customize your Backlight 2 based site to an extend not possible with the Backlight admin interface. Sometimes, it is not desired, that such a customization targets the entire site, but only a single page or a group of pages. In this short post, I show […]

Adding radio buttons and drop-down lists to forms

Since Backlight was introduced, once in a while users asked for more advanced form features such as radio buttons and drop-down lists. Backlight’s contact form editor is easy to use, but only supports text input. These forms are really just intended for simple contact forms. For more advanced forms, it is recommended to use WordPress […]

Get recent blog posts outside of WordPress pages

On my photography site, I display a list of the last 5 blog posts in the footer on all pages. I use the rss feed to get the most recent posts outside of the wordpress environment. This is how I do it using phplugins: And then I can call $this->dlp_get_latest_blog_posts(10, ‘my-link’) wherever I would like […]

Customizing single-page view

The single-page view is a bit of a neglected child. It’s main purpose is to provide a static link to an image that can be easily shared on social media. But there is more! With Backlight 2, the internal classes photo and album are exposed.

Adding breadcrumbs to non-gallery pages (updated August 2020)

Updated August 2020: I now use the newer Schema.org vocabulary for the breadcrumbs structure instead of the now obsolete data-vocabulary.org. For consistency reasons with my other phplugins tips&tricks, I renamed the my_crumb() helper function. It is now called dlp_my_crumb(). Updated August 9, 2020: Added support for backlight/search. Backlight provides the option to use breadcrumbs on […]

Using Markdown with Phplugins

It couldn’t be simpler than that: Or you can have text that spans several lines: Or you can assign text to a variable and then output that content using the Markdown parser: This last examples shows as well how you could add text to an already existing variable. Please note that this will not work […]

Web Design Consulting

Do you need help designing your web site or getting Backlight working the way you want? Contact me to discuss your idea or project.


Buy me a Coffee

If you like what I share here, please consider buying me a coffee or a print. This helps keeping me motivated to continue posting. Thank you!

Buy Me A Coffee

Categories