71b2ab4570bd5879e342930f82b524a5fe062ff7f7e734b4b98b6a5037390e62.php 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. <?php
  2. /* partials/userinfo-avatar.html.twig */
  3. class __TwigTemplate_58193e43aac927bef65e24ea31ff7daeb16dd5c0bfdb2314fc3eba7508dee9b2 extends Twig_Template
  4. {
  5. public function __construct(Twig_Environment $env)
  6. {
  7. parent::__construct($env);
  8. $this->parent = false;
  9. $this->blocks = array(
  10. );
  11. }
  12. protected function doDisplay(array $context, array $blocks = array())
  13. {
  14. // line 1
  15. if ($this->getAttribute(($context["data"] ?? null), "avatar", array())) {
  16. // line 2
  17. echo " <label><img src=\"";
  18. echo twig_escape_filter($this->env, ((($context["base_url_simple"] ?? null) . "/") . $this->getAttribute(twig_first($this->env, $this->getAttribute(($context["data"] ?? null), "avatar", array())), "path", array())), "html", null, true);
  19. echo "\" /></label>
  20. ";
  21. } else {
  22. // line 4
  23. echo " <label><img src=\"https://www.gravatar.com/avatar/";
  24. echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Common\Twig\TwigExtension')->md5Filter($this->getAttribute(($context["data"] ?? null), "email", array())), "html", null, true);
  25. echo "?s=200\" /></label>
  26. ";
  27. }
  28. }
  29. public function getTemplateName()
  30. {
  31. return "partials/userinfo-avatar.html.twig";
  32. }
  33. public function isTraitable()
  34. {
  35. return false;
  36. }
  37. public function getDebugInfo()
  38. {
  39. return array ( 27 => 4, 21 => 2, 19 => 1,);
  40. }
  41. /** @deprecated since 1.27 (to be removed in 2.0). Use getSourceContext() instead */
  42. public function getSource()
  43. {
  44. @trigger_error('The '.__METHOD__.' method is deprecated since version 1.27 and will be removed in 2.0. Use getSourceContext() instead.', E_USER_DEPRECATED);
  45. return $this->getSourceContext()->getCode();
  46. }
  47. public function getSourceContext()
  48. {
  49. return new Twig_Source("{% if data.avatar %}
  50. <label><img src=\"{{ base_url_simple ~ '/' ~ (data.avatar|first).path }}\" /></label>
  51. {% else %}
  52. <label><img src=\"https://www.gravatar.com/avatar/{{ data.email|md5 }}?s=200\" /></label>
  53. {% endif %}", "partials/userinfo-avatar.html.twig", "/home/kevin/Sites/static-ethica.net/user/plugins/admin/themes/grav/templates/partials/userinfo-avatar.html.twig");
  54. }
  55. }