summaryrefslogtreecommitdiff
path: root/http
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2015-01-29 10:50:20 +0100
committeremkael <emkael@tlen.pl>2015-01-29 10:50:20 +0100
commitdd3d2509f6048e11f9b2b127f6c7acb80a506d8d (patch)
treeac9e3b621fcb490493fde1c772ea4f9ef1dd72d9 /http
parentb11bd21d0f1932eb1d4e7459d78c4a994d7c22b9 (diff)
* link to original URLHEADmaster
Diffstat (limited to 'http')
-rw-r--r--http/index.php14
1 files changed, 13 insertions, 1 deletions
diff --git a/http/index.php b/http/index.php
index e8e18a8..a7034b6 100644
--- a/http/index.php
+++ b/http/index.php
@@ -54,7 +54,10 @@ if ($path) {
$content = '<html><head>'
. '<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />'
. '<base href="' . BASE_PATH . '" />'
- . '<style>body {width: 580px; font-family: Tahoma, Geneva, Arial, Helvetica, "sans-serif";}</style>'
+ . '<style>'
+ . 'body{width:580px;font-family:Tahoma,Geneva,Arial,Helvetica,"sans-serif";}'
+ . 'a{text-decoration:none;color:black;}'
+ . '</style>'
. '</head><body>'
. implode(PHP_EOL, array_slice($contentLines, $delimiters[0]+1, $delimiters[1]-$delimiters[0]-1))
. '</body></html>';
@@ -117,6 +120,15 @@ if ($path) {
}
$html->top();
+ // link to the original URL on the image from foto/ directory and on the name+surname
+ // (actually, on every text with font-size:28px set)
+ $linking = $html->find('img[src^="foto/"],span[style*=":28px"]');
+ foreach ($linking as $link) {
+ $link->wrap('<a></a>');
+ $link->parent()->attr('href', $mscUrl);
+ }
+ $html->top();
+
// all done
print $html->html();
}