<feed xmlns='http://www.w3.org/2005/Atom'>
<title>FreshRSS (Customized)/docs/en/developers/03_Backend, branch 1.28.1-custom</title>
<subtitle>Customized version of FreshRSS, a self-hosted RSS feed aggregator</subtitle>
<id>https://git.rdnlsmith.com/fresh-rss-custom/atom?h=1.28.1-custom</id>
<link rel='self' href='https://git.rdnlsmith.com/fresh-rss-custom/atom?h=1.28.1-custom'/>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/'/>
<updated>2025-11-18T14:16:14+00:00</updated>
<entry>
<title>Fix link to Minz docs in 05_Extensions.md (#8229)</title>
<updated>2025-11-18T14:16:14+00:00</updated>
<author>
<name>matthew-neavling</name>
<email>matthew.neavling@proton.me</email>
</author>
<published>2025-11-18T14:16:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=9522e8f95018550122276fae746d136f125397db'/>
<id>urn:sha1:9522e8f95018550122276fae746d136f125397db</id>
<content type='text'>
The link to the Minz docs works on GitHub but 404's on the [live site](https://freshrss.github.io/FreshRSS/en/developers/03_Backend/05_Extensions.html). Replacing the absolute path with a relative path should correct the 404.</content>
</entry>
<entry>
<title>Housekeeping lib_rss.php (#8193)</title>
<updated>2025-11-11T07:17:12+00:00</updated>
<author>
<name>Alexandre Alapetite</name>
<email>alexandre@alapetite.fr</email>
</author>
<published>2025-11-11T07:17:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=a18c35046daee15e7ac5f85db290d54541a03e3c'/>
<id>urn:sha1:a18c35046daee15e7ac5f85db290d54541a03e3c</id>
<content type='text'>
* Housekeeping lib_rss.php
`lib_rss.php` had become much too large, especially after https://github.com/FreshRSS/FreshRSS/pull/7924
Moved most functions to other places.
Mostly no change of code otherwise (see comments).

* Extension: composer run-script phpstan-third-party</content>
</entry>
<entry>
<title>Add a new hook in the UI (#8054)</title>
<updated>2025-10-02T13:33:53+00:00</updated>
<author>
<name>Alexis Degrugillier</name>
<email>aledeg@users.noreply.github.com</email>
</author>
<published>2025-10-02T13:33:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=032316155c03ca1013644476b8f9413ba436b744'/>
<id>urn:sha1:032316155c03ca1013644476b8f9413ba436b744</id>
<content type='text'>
* Add a new hook in the UI

The new hook allows extension to add their own tool bar to navigate between
entries. For instance, if the user wants less or more buttons that what's
available by default.

See #7912
See #7913

* add link data to ease navigation</content>
</entry>
<entry>
<title>Add support for extension priority (#8038)</title>
<updated>2025-10-01T09:01:31+00:00</updated>
<author>
<name>Alexis Degrugillier</name>
<email>aledeg@users.noreply.github.com</email>
</author>
<published>2025-10-01T09:01:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=dac275ce3a3529494af1b86b803f140a1a55424e'/>
<id>urn:sha1:dac275ce3a3529494af1b86b803f140a1a55424e</id>
<content type='text'>
Extension can now define their hook priority. This will allow to define the order in which hooks are triggered.

See #7110

Closes #7110

Changes proposed in this pull request:

- Add support for extension priority

How to test the feature manually:

1. Create an extension with 2 hooks on the same hook type but different priority
2. The hooks must be prepending the title with different values
3. Validate that changing the hook priority changes the final title accordingly.
</content>
</entry>
<entry>
<title>Add hook enums (#8036)</title>
<updated>2025-09-30T20:59:41+00:00</updated>
<author>
<name>Alexis Degrugillier</name>
<email>aledeg@users.noreply.github.com</email>
</author>
<published>2025-09-30T20:59:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=72884813e13596d211471482ffdc6d723ed678c9'/>
<id>urn:sha1:72884813e13596d211471482ffdc6d723ed678c9</id>
<content type='text'>
- add an enum to handle hook types (enum are available since PHP 8.1)
- change hook calls from string value to enum value
</content>
</entry>
<entry>
<title>Add `entry_before_update` and `entry_before_add` hooks (#7977)</title>
<updated>2025-09-18T21:44:17+00:00</updated>
<author>
<name>KleinMann</name>
<email>47398070+rnkln@users.noreply.github.com</email>
</author>
<published>2025-09-18T21:44:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=d670bf1e72d92c3bbeeca874f6a042f4e3a74007'/>
<id>urn:sha1:d670bf1e72d92c3bbeeca874f6a042f4e3a74007</id>
<content type='text'>
Discussion: https://github.com/FreshRSS/FreshRSS/discussions/7973

Changes proposed in this pull request:

- Add new extension hook "entry_before_add"
- Add new extension hook "entry_before_update"

How to test the feature manually:

1. Create extension that uses the hooks and confirm they are invoked correctly.

Extension to use for testing
https://github.com/rnkln/freshrss-xExtension-Discord/pull/2
</content>
</entry>
<entry>
<title>`before_login_btn` hook + system conf attributes (#7761)</title>
<updated>2025-07-30T06:03:04+00:00</updated>
<author>
<name>Inverle</name>
<email>inverle@proton.me</email>
</author>
<published>2025-07-30T06:03:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=e33ef74af9ff2f8ba1c6909b78ee07633cff240a'/>
<id>urn:sha1:e33ef74af9ff2f8ba1c6909b78ee07633cff240a</id>
<content type='text'>
* `before_login_btn` hook + system conf attributes

* phpstan fix

* Refactoring

---------

Co-authored-by: Alexandre Alapetite &lt;alexandre@alapetite.fr&gt;</content>
</entry>
<entry>
<title>Implement custom feed favicons (#7646)</title>
<updated>2025-06-30T10:01:56+00:00</updated>
<author>
<name>Inverle</name>
<email>inverle@proton.me</email>
</author>
<published>2025-06-30T10:01:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=7915abd833e1ab7a72ad27b3ec52020ac9ab7051'/>
<id>urn:sha1:7915abd833e1ab7a72ad27b3ec52020ac9ab7051</id>
<content type='text'>
Closes #3789, #6503

Icon setting when no custom icon is set yet:

![image](https://github.com/user-attachments/assets/28b07dd0-7dac-4c76-b1d7-77035f91a87a)

- `Change...` button opens a file dialog, and after selecting a file shows the chosen icon in the preview on the left. `Submit` must be clicked after selecting the icon.
- `Reset to default` changes the preview icon to the default one, and also requires `Submit` to be clicked to apply the changes.

Full list of changes:
- CSP now includes `blob:` in `img-src` for
   - `indexAction()` and `feedAction()` in `subscriptionController.php`
   - all of the view actions in `indexController.php`
- Introduce new attribute `customFavicon (boolean)` for feeds that indicates if the feed has a custom favicon
   - `hashFavicon()` in `Feed.php` is dependent on this attribute
      - `hashFavicon()` has a new parameter called `skipCache (boolean)` that allows the reset of the favicon hash for the Feed object
      - `resetFaviconHash()` just calls `hashFavicon(skipCache: true)`
- `f.php` URLs now have the format of `/f.php?h=XXXXX&amp;t=cachebuster`, where the `t` parameter is only used for serving custom favicons
   - if `t` parameter is set, `f.php` returns a `Cache-Control: immutable` header
- `stripos` and `strpos` were changed to `str_contains` in various places (refactor)
- JS for handling the custom favicon configuration logic is in `extra.js` inside `init_update_feed()` which is called when feed configuration is opened from the aside or when the subscription management page with the feed is loaded
   - Server-side code for uploading the icon in `subscriptionController.php` under `feedAction()`
   - Errors that may occur during the setting of a custom favicon:
      - Unsupported image file type (handled only server-side with `isImgMime()`)
      - When the file is bigger than 1 MiB (default), handled both client-side and server-side
      - Standard feed error when `updateFeed()` fails
- JS vars `javascript_vars.phtml` are no longer escaped with `htmlspecialchars()`, instead with json encoding,
- CSS for disabled buttons was added
- Max favicon file size is configurable with the `max_favicon_upload_size` option in `config.php` (not exposed via UI)
- Custom favicons are currently deleted only when they are either reset to the default icon, or the feed gets deleted. They do not get deleted when the user deletes their account without removing their feeds first.
- ` faviconPrepare()` and `faviconRebuild()` are not allowed to be called when the `customFavicon` attribute is `true`
- New i18n strings:
   - `'sub.feed.icon' =&gt; 'Icon'`
   - `'sub.feed.change_favicon' =&gt; 'Change…'`
   - `'sub.feed.reset_favicon' =&gt; 'Reset to default'`
   - `'sub.feed.favicon_changed_by_ext' =&gt; 'The icon has been set by the &lt;b&gt;%s&lt;/b&gt; extension.'`
   - `'feedback.sub.feed.favicon.too_large' =&gt; 'Uploaded icon is too large. The maximum file size is &lt;em&gt;%s&lt;/em&gt;.'`
   - `'feedback.sub.feed.favicon.unsupported_format' =&gt; 'Unsupported image file format!'`
- Extension hook `custom_favicon_hash`
   - `setCustomFavicon()` method
   - `resetCustomFavicon()` method
   - `customFaviconExt` and `customFaviconDisallowDel` attributes
   - example of usage: https://github.com/FreshRSS/Extensions/pull/337
- Extension hook `custom_favicon_btn_url`
   - Allows extensions to implement a button for setting a custom favicon for individual feeds by providing an URL. The URL will be sent a POST request with the `extAction` field set to either `query_icon_info` or `update_icon`, along with an `id` field which describes the feed's ID.
</content>
</entry>
<entry>
<title>Exposed the reading modes for extensions through Minz (#7668)</title>
<updated>2025-06-21T22:36:32+00:00</updated>
<author>
<name>Stefan</name>
<email>11146296+tryallthethings@users.noreply.github.com</email>
</author>
<published>2025-06-21T22:36:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=51298cd6bc100b1cc6508abb602a59c01a9e2c04'/>
<id>urn:sha1:51298cd6bc100b1cc6508abb602a59c01a9e2c04</id>
<content type='text'>
* + Exposed the reading modes for extensions through Minz. Now extensions can add a custom view mode. Graceful fallback to normal view in case the extension was disabled without resetting the view_mode through the uninstall method. In that case the user will be informed via Minz_Request::setBadNotification that the view has been reset to normal.
+ Added translation strings for de, en and en-us for the notification

* + Added missing, generated translations

* Simplify indexAction, performance

* Minor settings htmlspecialchars

* i18n: fr

* Minor wording

* Doc

* Fix i18n

---------

Co-authored-by: Alexandre Alapetite &lt;alexandre@alapetite.fr&gt;</content>
</entry>
<entry>
<title>Add API endpoint for extensions (#7576)</title>
<updated>2025-06-02T22:16:17+00:00</updated>
<author>
<name>Alexandre Alapetite</name>
<email>alexandre@alapetite.fr</email>
</author>
<published>2025-06-02T22:16:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.rdnlsmith.com/fresh-rss-custom/commit/?id=cc35094bb261cb3185def89d745317fa756560ee'/>
<id>urn:sha1:cc35094bb261cb3185def89d745317fa756560ee</id>
<content type='text'>
* Add API endpoint for extensions
Useful for https://github.com/FreshRSS/FreshRSS/issues/7572

* Support PATH_INFO
Now also support being invoked like `/api/misc.php/Extension%20Name/`

* More  documentation</content>
</entry>
</feed>
