summaryrefslogtreecommitdiff
path: root/cgi-bin/link.py
diff options
context:
space:
mode:
authorCtibor Brančík <ctibor@brancik.cz>2017-04-25 19:36:57 +0200
committerCtibor Brančík <ctibor@brancik.cz>2017-04-25 19:36:57 +0200
commit11340cccc2743c519f8625843e9cf631e83e5ada (patch)
treebdfa61e4aaf5157094645cb062c425bba1128384 /cgi-bin/link.py
parentb4382e7d04836cfcf2f1ff402829890a044f09cb (diff)
downloadhnizdo-11340cccc2743c519f8625843e9cf631e83e5ada.tar.gz
hnizdo-11340cccc2743c519f8625843e9cf631e83e5ada.tar.bz2
Add link to full size image.
Diffstat (limited to 'cgi-bin/link.py')
-rwxr-xr-x[-rw-r--r--]cgi-bin/link.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/cgi-bin/link.py b/cgi-bin/link.py
index 2b870bb..334184a 100644..100755
--- a/cgi-bin/link.py
+++ b/cgi-bin/link.py
@@ -73,6 +73,12 @@ class Link:
return "<a href=\""+self.href(target)+"\">"+link+"</a>"
else:
return "<span>"+link+"</span>"
+
+ def full(self, target, link):
+ if self.detect(target):
+ return "<a href=\"/img/"+target+"-full.jpeg\">"+link+"</a>"
+ else:
+ return "<span>"+link+"</span>"
def delta(self, delta):
date=os.path.split(self.img)