From 48e55aa595915da4fae55ea5f4c3e51203e866c4 Mon Sep 17 00:00:00 2001 From: spipu Date: Wed, 14 Jun 2017 11:12:38 +0200 Subject: [PATCH] fix Undesired mouseover effect on links in PDF on Chrome Pdf Viewer --- CHANGELOG.TXT | 3 +++ tcpdf.php | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.TXT b/CHANGELOG.TXT index 64c3d47..d6e4cf0 100644 --- a/CHANGELOG.TXT +++ b/CHANGELOG.TXT @@ -1,3 +1,6 @@ +Unreleased + - fix Undesired mouseover effect on links in PDF on Chrome Pdf Viewer + 6.2.13 (2016-06-10) - IMPORTANT: A new version of this library is under development at https://github.com/tecnickcom/tc-lib-pdf and as a consequence this version will not receive any additional development or support. This version should be considered obsolete, new projects should use the new version as soon it will become stable. diff --git a/tcpdf.php b/tcpdf.php index 65196e7..f3c15b3 100644 --- a/tcpdf.php +++ b/tcpdf.php @@ -8157,7 +8157,9 @@ class TCPDF { $annots .= ' /FT /'.$pl['opt']['ft']; $formfield = true; } - $annots .= ' /Contents '.$this->_textstring($pl['txt'], $annot_obj_id); + if ($pl['opt']['subtype'] !== 'Link') { + $annots .= ' /Contents '.$this->_textstring($pl['txt'], $annot_obj_id); + } $annots .= ' /P '.$this->page_obj_id[$n].' 0 R'; $annots .= ' /NM '.$this->_datastring(sprintf('%04u-%04u', $n, $key), $annot_obj_id); $annots .= ' /M '.$this->_datestring($annot_obj_id, $this->doc_modification_timestamp);