diff options
author | nodiscc <nodiscc@gmail.com> | 2015-03-05 13:40:43 +0100 |
---|---|---|
committer | nodiscc <nodiscc@gmail.com> | 2015-03-05 13:40:43 +0100 |
commit | baf5cbf27d18467d838a24b6f451036cebaa27bf (patch) | |
tree | 7972d6d680802e80400c9c431f762983b1d38dd7 | |
parent | 403a19940961eaf3edae84c7e9c4fa0bd074e940 (diff) | |
download | Shaarli-baf5cbf27d18467d838a24b6f451036cebaa27bf.tar.gz Shaarli-baf5cbf27d18467d838a24b6f451036cebaa27bf.tar.zst Shaarli-baf5cbf27d18467d838a24b6f451036cebaa27bf.zip |
Improve URL cleaning:
* also remove action_type_map, action_ref_map and action_object maps params used by facebook
-rw-r--r-- | index.php | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1644,7 +1644,7 @@ function renderPage() | |||
1644 | 1644 | ||
1645 | 1645 | ||
1646 | // We remove the annoying parameters added by FeedBurner, GoogleFeedProxy, Facebook... | 1646 | // We remove the annoying parameters added by FeedBurner, GoogleFeedProxy, Facebook... |
1647 | $annoyingpatterns = array('/[\?&]utm_source=[^&]*/', '/[\?&]utm_campaign=[^&]*/', '/[\?&]utm_medium=[^&]*/', '/#xtor=RSS-[^&]*/', '/[\?&]fb_[^&]*/', '/[\?&]__scoop[^&]*/', '/#tk\.rss_all\?/'); | 1647 | $annoyingpatterns = array('/[\?&]utm_source=[^&]*/', '/[\?&]utm_campaign=[^&]*/', '/[\?&]utm_medium=[^&]*/', '/#xtor=RSS-[^&]*/', '/[\?&]fb_[^&]*/', '/[\?&]__scoop[^&]*/', '/#tk\.rss_all\?/', '/[\?&]action_ref_map=[^&]*/', '/[\?&]action_type_map=[^&]*/', '/[\?&]action_object_map=[^&]*/'); |
1648 | foreach($annoyingpatterns as $pattern) | 1648 | foreach($annoyingpatterns as $pattern) |
1649 | { | 1649 | { |
1650 | $url = preg_replace($pattern, "", $url); | 1650 | $url = preg_replace($pattern, "", $url); |