From bcc37329aa8f481aeb837ddad69b13ec2dee2d8c Mon Sep 17 00:00:00 2001 From: Michael Wallner Date: Wed, 20 Aug 2014 15:45:11 +0200 Subject: [PATCH] prepare for general docs prepended by ": " --- mdref/RefEntry.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/mdref/RefEntry.php b/mdref/RefEntry.php index 9db99f7..2ad3d27 100644 --- a/mdref/RefEntry.php +++ b/mdref/RefEntry.php @@ -56,13 +56,15 @@ class RefEntry continue; } if (strlen($link)) { - if ($upper && !ctype_upper($parts[$i][0])) { + if ($parts[$i][0] === ":") { + $link = ""; + } elseif ($upper && !ctype_upper($parts[$i][0])) { $link .= "::"; } else { $link .= "\\"; } } - $link .= $parts[$i]; + $link .= trim($parts[$i], ": "); $upper = ctype_upper($parts[$i][0]); } return $link; -- 2.30.2