check: stats for links in article ; need more investigating for others

This commit is contained in:
Cyrille L 2022-11-18 16:36:46 +01:00
parent 623540a92a
commit 413b6d2912
2 changed files with 8 additions and 7 deletions

View File

@ -520,6 +520,7 @@ def check_links(line, ln, stats_links_uniq):
log.append_f(post_logs,msg_log,1)
Post_Err = True
if Post_Err: return
# Set final marker_N
link = (
@ -530,7 +531,7 @@ def check_links(line, ln, stats_links_uniq):
globals()[link_nbr] = link
# Stats: count occurence
stats_links_p = stats_counter(link_page)
stats_links_p = stats_links_p + stats_counter(link_page)
#=================================#
# Check every marker "file:" #

View File

@ -94,12 +94,12 @@ def manage_wip(file_post, Force):
wip_begin_markers(wip_html.rsplit('\n'))
wip_titles( wip_html.rsplit('\n'))
wip_words_markers(wip_html)
wip_anchors( wip_html)
wip_abbrs( wip_html)
if anchors > 0: wip_anchors( wip_html)
if abbrs_u > 0: wip_abbrs( wip_html)
# After all, convert protected contents
wip_links( wip_html)
wip_quotes( wip_html.rsplit('\n'))
if links_u > 0: wip_links( wip_html)
if quotes > 0: wip_quotes( wip_html.rsplit('\n'))
print('> Article HTML:')
print(wip_html)
@ -132,7 +132,7 @@ def wip_begin_markers(wip_lines):
for line in wip_lines:
if len(line) == 0: continue
# Find if line hase marker and remplace
# Find if line has marker and remplace
for marker in marks_html:
if re.match(marker[0], line):
if marker[2]: # Has CSS