PHPackages                             hypejunction/elgg-snippets - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. hypejunction/elgg-snippets

ActiveElgg-plugin

hypejunction/elgg-snippets
==========================

Editable HTML snippets for use in themes and views

1.0.1(6y ago)1301GPL-2.0PHPPHP &gt;=7.0

Since Feb 14Pushed 6y ago1 watchersCompare

[ Source](https://github.com/hypeJunction/elgg-snippets)[ Packagist](https://packagist.org/packages/hypejunction/elgg-snippets)[ Docs](http://hypejunction.com)[ RSS](/packages/hypejunction-elgg-snippets/feed)WikiDiscussions master Synced today

READMEChangelog (2)Dependencies (1)Versions (3)Used By (0)

HTML Snippets for Elgg
======================

[](#html-snippets-for-elgg)

[![Elgg 2.3](https://camo.githubusercontent.com/cfd1f9530e267f480ce207ec10333e3a5ffc64bd5e292306d6431ec406aee1d4/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f456c67672d322e332e782d6f72616e67652e7376673f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/cfd1f9530e267f480ce207ec10333e3a5ffc64bd5e292306d6431ec406aee1d4/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f456c67672d322e332e782d6f72616e67652e7376673f7374796c653d666c61742d737175617265)

Reusable and editable snippets with variable interpolation

Features
--------

[](#features)

Using plugin settings to alter large chunks of HTML is repetitive and not very efficient: you have to update plugins settings, remember in which plugin a setting lives, figure out how to populate default values, implement weird mechanics to interpolate variables etc.

This plugin makes it easy, just create a snippets in your views and will be available for editing via admin interface. Snippets can then be injected into your views with `elgg_snippet()`.

Usage
-----

[](#usage)

Once the plugin is enabled, snippets can be edited under Admin &gt; Appearance &gt; HTML Snippets.

Create a default snippet as a .twig view anywhere in `views/default/snippets/`:

```
// my-plugin/views/default/snippets/page/footer.twig

  Contact Us

```

Render a snippet where it belongs:

```
// my-plugin/views/default/somewhere.php
echo elgg_snippet('page/footer');
```

You can provide the title and the description of the snippet using translations:

```
// languages/en.php
return [
   'snippet:page/footer' => 'Page Footer Template',
   'snippet:page/footer:help' => 'Displayed on all pages in the footer area',
];
```

Storage
-------

[](#storage)

Snippet overrides are stored in the dataroot, so be sure to copy them over if migrating your site. You can also reset to default template, by deleting a corresponding snippet from the dataroot.

###  Health Score

26

—

LowBetter than 46% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 80% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~166 days

Total

2

Last Release

2429d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/5071b1cd852e094b3f564962a625e04c227adc73af30c5b46b243ab8f20154a7?d=identicon)[hypeJunction](/maintainers/hypeJunction)

---

Top Contributors

[![hypeJunction](https://avatars.githubusercontent.com/u/1202761?v=4)](https://github.com/hypeJunction "hypeJunction (4 commits)")[![mapkyca](https://avatars.githubusercontent.com/u/124070?v=4)](https://github.com/mapkyca "mapkyca (1 commits)")

---

Tags

pluginelggtemplates

### Embed Badge

![Health badge](/badges/hypejunction-elgg-snippets/health.svg)

```
[![Health](https://phpackages.com/badges/hypejunction-elgg-snippets/health.svg)](https://phpackages.com/packages/hypejunction-elgg-snippets)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
