Alexis Degrugillier
db4c2798ae
Allow redirection after login ( #4654 )
...
Before, if you've tried to reach a page without being logged, you'll be
automatically redirected to the index page after login.
Now, the original page is used after login.
Fix #3663
2022-10-03 16:49:52 +02:00
Alexandre Alapetite
97fc0bc95e
GLOB_BRACE is not available on all platforms ( #4628 )
...
https://php.net/glob
#fix https://github.com/FreshRSS/FreshRSS/issues/4627
Improvement of https://github.com/FreshRSS/FreshRSS/pull/4220
2022-09-20 12:03:46 +02:00
berumuron
6813e16e95
fix: Fix preg_match in enforceHttpEncoding ( #4623 )
...
`preg_match` can return `1`, `0` or `false`. In this last case,
`enforceHttpEncoding` was trying to access `$matches[1]`, even if the regex wasn't matching.
2022-09-19 11:50:46 +02:00
Alexandre Alapetite
0c472402f2
Workaround invalid OPMLs ( #4591 )
...
* Workaround invalid OPMLs
#fix https://github.com/FreshRSS/FreshRSS/issues/4590
Accept OPML files lacking text attributes
* Tolerate missing head element
2022-09-09 22:56:34 +02:00
Alexandre Alapetite
442019a054
SimplePie fix base ( #4565 )
...
* SimplePie fix base
#fix https://github.com/FreshRSS/FreshRSS/issues/4562
See `<xml:base>` example in https://datatracker.ietf.org/doc/html/rfc4287#section-1.1
First uses item `<xml:base>` if it exists, or the item own link, or the feed's base URL rules (feed URL, or Web site URL)
* Minor formatting
2022-09-05 09:15:20 +02:00
maTh
4214954ea1
Improved: error page ( #4465 )
...
* error page: true HTML page
* error page: http500 erorr
* error page: add CSP header
* 'log.txt' replaced by LOG_FILENAME
* use ADMIN_LOG
* log.txt => LOG_FILENAME
* error message: add <title>
* Docs created
* delete: documentation on error message page
* line break added
* added: new line at the end
* typo fixed
* Update lib/lib_rss.php
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
* Update lib/lib_rss.php
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
* Minz HTTP 500
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-08-21 22:44:03 +02:00
Alexandre Alapetite
2acf3a4dd8
CssXPath-StarSelector ( #4506 )
...
* CssXPath-StarSelector
Add support for selectors such as `a[href*="example"]`
https://developer.mozilla.org/docs/Web/CSS/Attribute_selectors
Translated to `.//a[contains(@href,"example")]`
Upstream PR: https://github.com/PhpGt/CssXPath/pull/181
* Upstream merged
2022-08-18 11:14:40 +02:00
maTh
a534fc79c4
Fix: logs page=0 error ( #4460 )
...
* add docs of function param()
* page < 0 is impossible now
* show prev/next only, when there is a prev/next page
* set always page params
* Revert "page < 0 is impossible now"
This reverts commit fdb920ee50 .
* Update logs_pagination.phtml
2022-07-27 18:52:30 +02:00
maTh
2d807e06b1
Fix/Improved: Slider mobile ( #4416 )
...
* add close button, add content slider div
* add &ajax=1#slider to the links
* CSS
* fix showPW functionality
* open slider after received Ajax
* do not show empty slider
* RTL CSS
* fixed code smell
* improved: links prep via JS
* Redirect anchor
* enable #anchors in printuri()
* enable #slider when config was saved
* Active sliding via JS
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-07-19 12:56:09 +02:00
Alexandre Alapetite
509c8cae63
Dynamic OPML ( #4407 )
...
* Dynamic OPML draft
#fix https://github.com/FreshRSS/FreshRSS/issues/4191
* Export dynamic OPML
http://opml.org/spec2.opml#1629043127000
* Restart with simpler approach
* Minor revert
* Export dynamic OPML also for single feeds
* Special category type for importing dynamic OPML
* Parameter for excludeMutedFeeds
* Details
* More draft
* i18n
* Fix update
* Draft manual import working
* Working manual refresh
* Draft automatic update
* Working Web refresh + fixes
* Import/export dynamic OPML settings
* Annoying numerous lines in SQL logs
* Fix minor JavaScript error
* Fix auto adding new columns
* Add require
* Add missing 🗲
* Missing space
* Disable adding new feeds to dynamic categories
* Link from import
* i18n typo
* Improve theme icon function
* Fix pink-dark
2022-07-04 09:53:26 +02:00
Alexandre Alapetite
47ab9d5e77
Better trim base_url ( #4423 )
...
Avoid usual errors for instance with quotes, especially when provided through Docker / CLI
2022-06-21 10:46:50 +02:00
Alexandre Alapetite
dcc77ee343
Initial support for PHP 8.2 ( #4421 )
...
* Initial support for PHP 8.2
Using dev image `freshrss/freshrss:latest` https://github.com/FreshRSS/FreshRSS/pull/4420
* Deprecated string interpolation
2022-06-19 20:10:13 +02:00
Alexandre Alapetite
f365a9aeb4
Update all test dependencies ( #4419 )
...
* Update all test dependencies
* Remove old false-positive
* Minor update lock files
* Increase PHPStan memory for Fedora
https://github.com/FreshRSS/FreshRSS/pull/4400#issuecomment-1159514197
* Require PHP8+ for tests
Due to small changes of signature in `ob_implicit_flush` and `simplexml_load_string`, cf. https://github.com/FreshRSS/FreshRSS/pull/4123
* Missing lint in CSS files
2022-06-19 20:08:42 +02:00
Alexandre Alapetite
ec11da4e84
Safer htmlspecialchars_utf8 ( #4411 )
...
* Safer htmlspecialchars_utf8
#fix https://github.com/FreshRSS/FreshRSS/issues/4410
* Undefined variable
2022-06-11 22:14:46 +02:00
Alexandre Alapetite
f89819bd64
Custom logo HTML ( #4369 )
...
* Custom logo HTML
Add option for custom HTML logo/title in the main Web UI view.
Can potentially be different per user.
#fix https://github.com/FreshRSS/FreshRSS/pull/3830/files#r850472247
* logo_html in main config
With new `./data/config.custom.php` to provide custom values before install
* Docker documentation
* whitespace
* Auto relax CSP to allow images for HTML logo
* Documentation
2022-05-23 14:03:19 +02:00
Alexandre Alapetite
cbf2bc085a
Remove HTTP Referer for HTML download ( #4372 )
...
Having this header leads to errors from sites such as LinkedIn. The usage of this header is also decreasing. Finaly, we were not sending the actual Referer but just the same URL as the one being fetched.
I suggest to remove for now, and see whether anyone needs it, in which case an option would be possible.
2022-05-19 21:31:04 +02:00
Artur Weigandt
d6fd78b968
Allow CssXPath updates with composer ( #4368 )
...
* Install CssXPath with composer
* Fix code style in tests
* fix pathnames for tests and linting
* add irrelevant files to .gitignore
* Alphabetic order
* let composer sort the packages alphabetically
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-05-16 12:04:43 +02:00
maTh
807ea755e0
fix preview ( #4291 )
...
* fix
* Update extra.js
* reorga the scripts
* Update extra.js
* Several fixes
https://github.com/FreshRSS/FreshRSS/pull/4291#issuecomment-1125472321
* More fixes
* Cleaning
* fix pr 4291
* Reorganise some script functions
* Remove unused popup-txt
And associated function openPopupWithMessage
* Fix archiving categories
https://github.com/FreshRSS/FreshRSS/pull/4291#issuecomment-1126924602
* Fix stats
https://github.com/FreshRSS/FreshRSS/pull/4291#issuecomment-1126983134
* Fix direct subscription
E.g. http://localhost/i/?c=subscription&id=735
* Fix subscription add
https://github.com/FreshRSS/FreshRSS/pull/4291#issuecomment-1126991621
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-05-15 21:52:52 +02:00
Artur Weigandt
5110d1db3e
Update to PHPMailer 6.6.0 with composer ( #4329 )
...
* Install PHPMailer 6.5.1 with composer
* Fix folder name for phpmailer
* Update PHPMailer to v6.6.0, add LICENSE and README.md
* remove composer and autoload.php after install/update
* Fix path to PHPMailer for PHPStan
* Remove lib/composer.lock, lock PHPMailer at version 6.6.0
* Improve PSR-4 autoloading for PHPMailer
* Markdownlint ignore
* Delete some obvious comments
* ignores
* Support composer update --no-autoloader
* Automatic cleaning
With rules based on https://github.com/PHPMailer/PHPMailer/blob/master/README.md#minimal-installation
* Readme gitignore hint
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-05-14 23:38:16 +02:00
Alexandre Alapetite
4a87206f28
OPML export/import of some proprietary FreshRSS attributes ( #4342 )
...
* OPML export/import of some proprietary FreshRSS attributes
#fix https://github.com/FreshRSS/FreshRSS/issues/4077
And one of the TODOs of https://github.com/FreshRSS/FreshRSS/pull/4220
XPath options, CSS Selector, and action filters
* Bump library patch version
* OPML namespace + documentation
* Add example
2022-05-12 22:15:10 +02:00
Alexandre Alapetite
893d4d14c0
OPML relax error check for non-strict mode ( #4343 )
...
#fix https://github.com/FreshRSS/FreshRSS/issues/3967
2022-05-09 12:57:11 +02:00
Alexandre Alapetite
0b86e347ef
Fix lazyimg single quotes ( #4330 )
...
Little bug for cases with single quote in URL such as
```html
<img src="123?format='jpg'" />
```
Could probably be replaced by `loading="lazy"` in the future, and with a better DOM-aware method, for instance during SimplePie `add_attributes()`
2022-04-26 08:58:08 +02:00
drosoCode
2aba861bc9
Add HTTP_REMOTE_USER header for auth ( #4063 )
...
* add HTTP_REMOTE_USER header for auth
* add ip whitelist for HTTP_REMOTE_USER header
* add IPv6 support for header auth
* fix formatting
* A few fixes
* Add some default trusted sources
* Fix IPv6 doc
* More standard header names
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-04-02 21:40:30 +02:00
Alexandre Alapetite
191abf5ba5
SimplePie fix status_code type ( #4301 )
...
#fix https://github.com/FreshRSS/FreshRSS/issues/4299
2022-04-02 21:39:20 +02:00
Alexandre Alapetite
efb57f965a
Rename conflicting function ( #4289 )
...
#fix https://github.com/FreshRSS/FreshRSS/issues/4284
2022-03-24 21:32:37 +01:00
Alexandre Alapetite
92b0ffe05c
Fix handling of authors with ampersand & ( #4287 )
...
Especially needed for HTML+XPath Web scraping as it makes the rest of the pipeline fail to handle special characters.
2022-03-23 11:29:33 +01:00
Alexandre Alapetite
e8af54a476
WebSub: Use hash instead of base64 to handle long URLs ( #4282 )
...
* WebSub: Use hash instead of base64 to handle long URLs
* Use 410 Gone
(Part of the WebSub specification https://www.w3.org/TR/websub/ )
2022-03-22 23:13:13 +01:00
Alexandre Alapetite
b0a63355b6
SimplePie fix parsing of HTTP Links ( #4283 )
...
* SimplePie fix parsing of HTTP Links
* https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Link
* https://datatracker.ietf.org/doc/html/rfc8288
Before, SimplePie was not able to parse something like
```
Link: <https://pubsubhubbub.appspot.com >; rel="hub", <https://pubsubhubbub.superfeedr.com >; rel=hub, <https://websubhub.com/hub >; rel="hub"
```
2022-03-22 23:12:22 +01:00
Alexandre Alapetite
4363e13c34
Set feed error state when XPath does not match ( #4275 )
...
Gives the ability to filter HTML+XPath feeds that are not working
2022-03-21 12:51:41 +01:00
Alexandre Alapetite
ae54a590b9
Replace lib_phpQuery by PhpGt/CssXPath ( #4261 )
...
https://github.com/PhpGt/CssXPath
2022-03-16 15:10:41 +01:00
Alexandre Alapetite
dc849c3d87
Fix HTML base for get full content ( #4260 )
...
#fix https://github.com/FreshRSS/FreshRSS/issues/4252
2022-03-05 16:00:01 +01:00
Alexandre Alapetite
467ca9d0de
Specific HTML load for lib_phpQuery.php ( #4243 )
...
And reverts a less appropriate workaround for the same thing in https://github.com/FreshRSS/FreshRSS/pull/4220
Avoids XML errors when believing that a document might be XML/XHTML.
2022-03-01 16:03:44 +01:00
Alexandre Alapetite
1fe66ad020
Implement Web scraping "HTML + XPath" ( #4220 )
...
* More PHP type hints for Fever
Follow-up of https://github.com/FreshRSS/FreshRSS/pull/4201
Related to https://github.com/FreshRSS/FreshRSS/issues/4200
* Detail
* Draft
* Progress
* More draft
* Fix thumbnail PHP type hint
https://github.com/FreshRSS/FreshRSS/issues/4215
* More types
* A bit more
* Refactor FreshRSS_Entry::fromArray
* Progress
* Starts to work
* Categories
* Fonctional
* Layout update
* Fix relative URLs
* Cache system
* Forgotten files
* Remove a debug line
* Automatic form validation of XPath expressions
* data-leave-validation
* Fix reload action
* Simpler examples
* Fix column type for PostgreSQL
* Enforce HTTP encoding
* Readme
* Fix get full content
* target="_blank"
* gitignore
* htmlspecialchars_utf8
* Implement HTML <base>
And fix/revert `xml:base` support in SimplePie e49c578817
* SimplePie upstream PR merged
https://github.com/simplepie/simplepie/pull/723
2022-02-28 20:22:43 +01:00
Alexandre Alapetite
946b0a0876
Hot fix: fix type hint null regression ( #4207 )
2022-02-07 01:35:29 +01:00
Alexandre Alapetite
354f22b4fa
PHPStan update to 1.4.6 ( #4203 )
...
https://github.com/phpstan/phpstan/releases
And compose udpdate
2022-02-07 00:56:59 +01:00
Alexandre Alapetite
1c5cf71859
Fix Fever 32 bit ID issue + more PHP type hints ( #4201 )
...
* Fix Fever 32 bit ID issue + more PHP type hints
#fix https://github.com/FreshRSS/FreshRSS/issues/4200
Follow up and fix regression from https://github.com/FreshRSS/FreshRSS/pull/4110
* More PHP type hints with PHPStan
* Fix pull problem
* Avoid more nulls
2022-02-06 14:31:36 +01:00
maTh
cb36fe25a7
Improved: Fetch articles with selector but do not delete the class attribute. (Simplepie: new method: rename_attribute) ( #4175 )
...
* added to simplepie: rename_attributes
* rename the class attribute
* Update lib/SimplePie/SimplePie/Sanitize.php
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
* added 'id' as attribute to rename to 'data-sanitized-id'
* Update lib_rss.php
* source code in sync with simplepie upstream
* fixed parameters
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-02-05 14:15:32 +01:00
Alexandre Alapetite
88b934da8b
Fix root redirection ( #4167 )
...
* Fix root redirection
#fix https://github.com/FreshRSS/FreshRSS/issues/4126
* Smarter
2022-02-04 15:41:20 +01:00
Alexandre Alapetite
47e242aa77
Fix ctype_alnum ( #4182 )
...
* Fix ctype_alnum
#fix https://github.com/FreshRSS/FreshRSS/issues/4180
Ensure `ctype_alnum()` gets a string
* Changelog
2022-01-30 15:53:17 +01:00
berumuron
bc5271b0eb
fix: Ignore non-PHP files in migrations/ folder ( #4163 )
...
Some NAS create folders named `@eaDir` in the FreshRSS tree, including
the `migrations/` folder. This broke the migration system which expected
only valid PHP files to be present in this folder. Now, it ignores
non-PHP files.
Reference: https://github.com/FreshRSS/FreshRSS/issues/4044
2022-01-17 13:13:27 +01:00
Alexandre Alapetite
3502e50cb2
Fix PHP 7.4 signature warnings ( #4140 )
...
Revert some type hints creating warnings in PHP 7.4 (not in PHP 7.0 nor PHP 8.1)
2022-01-09 19:02:12 +01:00
Alexandre Alapetite
4e2dff4591
Add spell checking with typos ( #4138 )
...
* Add spell checking with typos
Implement https://github.com/FreshRSS/FreshRSS/pull/4134#issuecomment-1008027558
* GitHub Actions attempt
* Quiet wget
* Makefile
2022-01-09 18:21:40 +01:00
Thomas Renes
916df412f5
Fix various typos and spelling errors in documentation, comments and code. ( #4134 )
2022-01-08 16:25:17 +01:00
Luc SANCHEZ
ed19445f74
Optimise Minz_ModelPdo::class ( #4119 )
...
* - Fix typo,
- remove unnecessary null in property,
- remove unused property,
- add phpDoc,
- add ext PDO in composer.json,
- use strict comparison,
- indentation
* Translate
* Update lib/Minz/ModelPdo.php
Co-authored-by: Frans de Jonge <fransdejonge@gmail.com >
* The code is more explicite
* Fix phpstan
* Fix phpstan expect one
* Fix phpstan
* Return in back...
* make fix-all
* Fix exception and more types
* Fix more types
* Remove ext- in composer.json
Co-authored-by: Luc SANCHEZ <l.sanchez-ext@ubitransport.com >
Co-authored-by: Frans de Jonge <fransdejonge@gmail.com >
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-01-07 10:05:09 +01:00
Alexandre Alapetite
8e398d24f1
Fix several PHP8.1 warnings ( #4123 )
...
* Fix several PHP8.1 warnings
Taking advantage of https://github.com/FreshRSS/FreshRSS/pull/4121
* Couple oh type hints missing
* Compatibility PHP 7
* Fix variadic PHPDocs syntax
2022-01-06 22:39:35 +01:00
Frans de Jonge
d339b6dd45
[CI] PHPCS: check for opening brace on same line ( #4122 )
...
* [CI] PHPCS: check for opening brace on same line
* make fix-all
* Minor comments
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr >
2022-01-05 00:52:24 +01:00
Alexandre Alapetite
1335a0e3cf
PHPStan level 5 ( #4110 )
...
* Fix most PHPDocs errors
Contributes to https://github.com/FreshRSS/FreshRSS/issues/4103
https://phpstan.org/writing-php-code/phpdoc-types
* Avoid func_get_args
Use variadic syntax instead https://php.net/manual/functions.arguments#functions.variable-arg-list
And avoid dynamic functions names when possible to more easily identify calls and unused functions.
Contributes to https://github.com/FreshRSS/FreshRSS/issues/4103
* PHPStan level 3
* PHPStand level 4
* Update default to PHPStan level 4
* Towards level 5
* Fix level 4 regression
* Towards level 5
* Pass PHPStan level 5
* Towards level 6
* Remove erronenous regression from changelog
https://github.com/FreshRSS/FreshRSS/pull/4116
2022-01-04 13:59:09 +01:00
Alexandre Alapetite
ba0e690235
SimplePie 1.5.8 manual upgrade ( #4113 )
...
Follow-up of https://github.com/FreshRSS/FreshRSS/pull/4011
Instead of https://github.com/FreshRSS/FreshRSS/pull/4102
* bea5de77af
* 5aab77e105
* 76be63e72e
2022-01-02 18:11:42 +01:00
Alexandre Alapetite
a791388ce4
Avoid func_get_args ( #4108 )
...
Use variadic syntax instead https://php.net/manual/functions.arguments#functions.variable-arg-list
And avoid dynamic functions names when possible to more easily identify calls and unused functions.
Contributes to https://github.com/FreshRSS/FreshRSS/issues/4103
2022-01-01 13:54:36 +01:00
Alexandre Alapetite
3f6aa42b81
Fix most PHPDocs errors ( #4107 )
...
Contributes to https://github.com/FreshRSS/FreshRSS/issues/4103
https://phpstan.org/writing-php-code/phpdoc-types
2022-01-01 11:26:56 +01:00