From 9020d497654d3e7cc6dc95f60eaf8a5265179f6c Mon Sep 17 00:00:00 2001 From: Roland Franssen Date: Sat, 20 Oct 2018 20:06:30 +0200 Subject: [PATCH] [WebProfilerBundle] Replay referer URL --- .../Resources/views/Profiler/layout.html.twig | 4 ++++ .../Resources/views/Profiler/profiler.css.twig | 9 +++++++++ 2 files changed, 13 insertions(+) diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/layout.html.twig b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/layout.html.twig index 5c990bbdb8..cd1b13a7e6 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/layout.html.twig +++ b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/layout.html.twig @@ -16,6 +16,10 @@ {{ profile.url }} {% else %} {{ profile.url }} + {% set referer = profile.collector('request').requestheaders.get('referer') %} + {% if referer %} + Replay referer URL + {% endif %} {% endif %} diff --git a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/profiler.css.twig b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/profiler.css.twig index bae9317229..122f95f269 100644 --- a/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/profiler.css.twig +++ b/src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/profiler.css.twig @@ -585,10 +585,19 @@ tr.status-warning td { font-size: 21px; margin: 0; text-decoration: none; + vertical-align: middle; } #summary h2 a:hover { text-decoration: underline; } +#summary h2 a.referer { + margin-left: .5em; + font-size: 75%; + color: rgba(255, 255, 255, 0.5); +} +#summary h2 a.referer:before { + content: '\1F503\00a0'; +} #summary .status-success { background: var(--color-success); } #summary .status-warning { background: var(--color-warning); }