diff --git a/blog.py b/blog.py index 203d3ed2..ca6d5a6a 100644 --- a/blog.py +++ b/blog.py @@ -391,7 +391,7 @@ def htmlBlogPost(authorized: bool, None, False) # show rss links - iconsDir = getIconsWebPath(baseDir) + iconsPath = getIconsWebPath(baseDir) blogStr += '
' blogStr += '' + iconsPath + '/logorss.png" />' # blogStr += '' # blogStr += '' + # iconsPath + '/rss3.png" />' blogStr += '
' @@ -451,7 +451,7 @@ def htmlBlogPage(authorized: bool, session, # show previous and next buttons if pageNumber is not None: - iconsDir = getIconsWebPath(baseDir) + iconsPath = getIconsWebPath(baseDir) navigateStr = '' if pageNumber > 1: # show previous button @@ -459,7 +459,7 @@ def htmlBlogPage(authorized: bool, session, domainFull + '/blog/' + \ nickname + '?page=' + str(pageNumber-1) + '">' + \ '\n' if len(timelineJson['orderedItems']) >= noOfItems: # show next button @@ -467,7 +467,7 @@ def htmlBlogPage(authorized: bool, session, domainFull + '/blog/' + nickname + \ '?page=' + str(pageNumber + 1) + '">' + \ '\n' navigateStr += '
' blogStr += navigateStr @@ -492,13 +492,13 @@ def htmlBlogPage(authorized: bool, session, domainFull + '/blog/' + nickname + '/rss.xml">' blogStr += '' + iconsPath + '/logorss.png" />' # blogStr += '' # blogStr += '' + # iconsPath + '/rss3.png" />' blogStr += '' return blogStr + htmlFooter() @@ -722,7 +722,7 @@ def htmlEditBlog(mediaInstance: bool, translate: {}, print('Edit blog: json not loaded for ' + postFilename) return None - iconsDir = getIconsWebPath(baseDir) + iconsPath = getIconsWebPath(baseDir) editBlogText = '' + \ translate['Write your post text below.'] + '
' @@ -767,7 +767,7 @@ def htmlEditBlog(mediaInstance: bool, translate: {}, dateAndLocation += \ '' + iconsPath + '/calendar.png"/>' dateAndLocation += \ '' dateAndLocation += '' @@ -798,7 +798,7 @@ def htmlEditBlog(mediaInstance: bool, translate: {}, editBlogForm += '
' + \ @@ -304,7 +304,7 @@ def htmlCitations(baseDir: str, nickname: str, domain: str, if os.path.isfile(baseDir + '/epicyon.css'): cssFilename = baseDir + '/epicyon.css' - # iconsDir = getIconsWebPath(baseDir) + # iconsPath = getIconsWebPath(baseDir) htmlStr = htmlHeaderWithExternalStyle(cssFilename) @@ -394,7 +394,7 @@ def htmlNewswireMobile(cssCache: {}, baseDir: str, nickname: str, if os.path.isfile(baseDir + '/epicyon.css'): cssFilename = baseDir + '/epicyon.css' - iconsDir = getIconsWebPath(baseDir) + iconsPath = getIconsWebPath(baseDir) if nickname == 'news': editor = False @@ -419,11 +419,11 @@ def htmlNewswireMobile(cssCache: {}, baseDir: str, nickname: str, htmlStr += '
\n' + iconsPath + '/calendar.png"/>\n' # select a date and time for this post dateAndLocation += '\n' @@ -505,7 +505,7 @@ def htmlNewPost(cssCache: {}, mediaInstance: bool, translate: {}, dateAndLocation += \ '
\n'
+ iconsPath + '/calendar.png"/>\n'
# select start time for the event
dateAndLocation += '\n'
@@ -518,7 +518,7 @@ def htmlNewPost(cssCache: {}, mediaInstance: bool, translate: {},
dateAndLocation += \
'
\n'
+ iconsPath + '/calendar.png"/>\n'
dateAndLocation += '\n'
dateAndLocation += '\n'
@@ -616,7 +616,7 @@ def htmlNewPost(cssCache: {}, mediaInstance: bool, translate: {},
htmlNewPostDropDown(scopeIcon, scopeDescription,
replyStr,
translate,
- iconsDir,
+ iconsPath,
showPublicOnDropdown,
defaultTimeline,
pathBase,
diff --git a/webapp_post.py b/webapp_post.py
index 686333e4..002f89c6 100644
--- a/webapp_post.py
+++ b/webapp_post.py
@@ -108,7 +108,7 @@ def saveIndividualPostAsHtmlToCache(baseDir: str,
def individualPostAsHtml(allowDownloads: bool,
recentPostsCache: {}, maxRecentPosts: int,
- iconsDir: str, translate: {},
+ iconsPath: str, translate: {},
pageNumber: int, baseDir: str,
session, wfRequest: {}, personCache: {},
nickname: str, domain: str, port: int,
@@ -391,7 +391,7 @@ def individualPostAsHtml(allowDownloads: bool,
if showDMicon:
titleStr = \
titleStr + ' \n'
+ iconsPath + '/dm.png" class="DMicon"/>\n'
replyStr = ''
# check if replying is permitted
@@ -445,7 +445,7 @@ def individualPostAsHtml(allowDownloads: bool,
'\n'
+ ' |" src="/' + iconsPath + '/reply.png"/>\n'
# benchmark 10
if not allowDownloads:
@@ -480,7 +480,7 @@ def individualPostAsHtml(allowDownloads: bool,
'\n'
+ ' |" src="/' + iconsPath + '/edit.png"/>\n'
else:
editStr += \
' ' + \
@@ -492,7 +492,7 @@ def individualPostAsHtml(allowDownloads: bool,
'\n'
+ ' |" src="/' + iconsPath + '/edit.png"/>\n'
elif isEvent:
eventPostId = postJsonObject['object']['id']
editStr += \
@@ -505,7 +505,7 @@ def individualPostAsHtml(allowDownloads: bool,
'\n'
+ ' |" src="/' + iconsPath + '/edit.png"/>\n'
announceStr = ''
if not isModerationPost and showRepeatIcon:
@@ -531,7 +531,7 @@ def individualPostAsHtml(allowDownloads: bool,
' ' + \
'\n'
+ ' |" src="/' + iconsPath + '/' + announceIcon + '"/>\n'
# benchmark 12
if not allowDownloads:
@@ -597,7 +597,7 @@ def individualPostAsHtml(allowDownloads: bool,
' ' + \
'\n'
+ ' |" src="/' + iconsPath + '/' + likeIcon + '"/>\n'
# benchmark 12.5
if not allowDownloads:
@@ -629,7 +629,7 @@ def individualPostAsHtml(allowDownloads: bool,
bookmarkStr += \
' ' + \
'\n'
# benchmark 12.9
@@ -663,7 +663,7 @@ def individualPostAsHtml(allowDownloads: bool,
'\n'
+ '" src="/' + iconsPath + '/delete.png"/>\n'
else:
if not isMuted:
muteStr = \
@@ -676,7 +676,7 @@ def individualPostAsHtml(allowDownloads: bool,
'\n'
+ '" src="/' + iconsPath + '/mute.png"/>\n'
else:
muteStr = \
' \n'
+ '" src="/' + iconsPath+'/unmute.png"/>\n'
# benchmark 13.1
if not allowDownloads:
@@ -708,7 +708,7 @@ def individualPostAsHtml(allowDownloads: bool,
' \n'
else:
# benchmark 13.2
@@ -755,7 +755,7 @@ def individualPostAsHtml(allowDownloads: bool,
'\n' + \
' ' + \
@@ -800,7 +800,7 @@ def individualPostAsHtml(allowDownloads: bool,
' \n' + \
' \n' + \
' \n' + \
' \n'
else:
if '/statuses/' in postJsonObject['object']['inReplyTo']:
@@ -888,7 +888,7 @@ def individualPostAsHtml(allowDownloads: bool,
'" alt="' + \
translate['replying to'] + \
'" src="/' + \
- iconsDir + '/reply.png" ' + \
+ iconsPath + '/reply.png" ' + \
'class="announceOrReply"/>\n' + \
' ' + \
'\n' + \
' @' + \
@@ -963,7 +963,7 @@ def individualPostAsHtml(allowDownloads: bool,
'" alt="' + \
translate['replying to'] + \
'" src="/' + \
- iconsDir + \
+ iconsPath + \
'/reply.png" class="announceOrReply"/>\n' + \
' \n' + \
' str:
"""Show the replies to an individual post as html
"""
- iconsDir = getIconsWebPath(baseDir)
+ iconsPath = getIconsWebPath(baseDir)
repliesStr = ''
if repliesJson.get('orderedItems'):
for item in repliesJson['orderedItems']:
repliesStr += \
individualPostAsHtml(True, recentPostsCache,
maxRecentPosts,
- iconsDir, translate, None,
+ iconsPath, translate, None,
baseDir, session, wfRequest, personCache,
nickname, domain, port, item,
None, True, False,
diff --git a/webapp_profile.py b/webapp_profile.py
index c03ed4e7..b38f3788 100644
--- a/webapp_profile.py
+++ b/webapp_profile.py
@@ -245,7 +245,7 @@ def htmlProfileAfterSearch(cssCache: {},
profileStr += ' \n'
profileStr += '\n'
- iconsDir = getIconsWebPath(baseDir)
+ iconsPath = getIconsWebPath(baseDir)
i = 0
for item in parseUserFeed(session, outboxUrl, asHeader,
projectVersion, httpPrefix, domain):
@@ -257,7 +257,7 @@ def htmlProfileAfterSearch(cssCache: {},
continue
profileStr += \
individualPostAsHtml(True, recentPostsCache, maxRecentPosts,
- iconsDir, translate, None, baseDir,
+ iconsPath, translate, None, baseDir,
session, cachedWebfingers, personCache,
nickname, domain, port,
item, avatarUrl, False, False,
@@ -273,7 +273,7 @@ def htmlProfileAfterSearch(cssCache: {},
def getProfileHeader(baseDir: str, nickname: str, domain: str,
- domainFull: str, translate: {}, iconsDir: str,
+ domainFull: str, translate: {}, iconsPath: str,
defaultTimeline: str,
displayName: str,
avatarDescription: str,
@@ -302,7 +302,7 @@ def getProfileHeader(baseDir: str, nickname: str, domain: str,
' ' + \
- '
' + profileDescriptionShort + '
\n' htmlStr += loginButton @@ -451,21 +451,21 @@ def htmlProfile(rssIconAtTop: bool, donateSection += ' \n' donateSection += '\n' - iconsDir = getIconsWebPath(baseDir) + iconsPath = getIconsWebPath(baseDir) if not authorized: loginButton = headerButtonsFrontScreen(translate, nickname, 'features', authorized, - iconsAsButtons, iconsDir) + iconsAsButtons, iconsPath) else: editProfileStr = \ '' + \ - '\n' logoutStr = \ '' + \ - '\n' @@ -553,11 +553,11 @@ def htmlProfile(rssIconAtTop: bool, profileHeaderStr += ' \n' profileHeaderStr += '