Skip to content

Commit

Permalink
Add & handling to links
Browse files Browse the repository at this point in the history
  • Loading branch information
jjohare authored Sep 11, 2023
1 parent 04390ce commit 1b42395
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions src/freeplane.py
Original file line number Diff line number Diff line change
Expand Up @@ -1225,15 +1225,22 @@ def plaintext(self, strText, modified=''):

@property
def hyperlink(self):
return self._node.attrib.get("LINK","")
link = self._node.attrib.get("LINK","")

# Unescape XML encoding
link = link.replace('&', '&')

return link

@hyperlink.setter
def hyperlink(self, strLink, modified=''):
self._node.attrib["LINK"] = strLink

# Escape & characters
strLink = strLink.replace('&', '&')



self._node.attrib["LINK"] = strLink
#
# set creation and modification dates
#
Expand Down Expand Up @@ -2847,4 +2854,3 @@ def getText(self, strRootAttribute, strTitleText, strPortion):

# create execute class init with command line environment
Mindmap(id='cli')

0 comments on commit 1b42395

Please sign in to comment.