Compare commits
No commits in common. 'master' and 'andre' have entirely different histories.
@ -1,171 +0,0 @@
|
||||
import os, json, sys
|
||||
from mwclient import Site
|
||||
from jinja2 import Template
|
||||
from shutil import copy
|
||||
import html5lib
|
||||
from functions import Colors
|
||||
import argparse
|
||||
from xml.etree import ElementTree as ET
|
||||
from urllib.parse import quote as urlquote, unquote as urlunquote
|
||||
|
||||
|
||||
NS_MAIN = 0
|
||||
NS_CATEGORY = 14
|
||||
|
||||
p = argparse.ArgumentParser(description="Dump wiki files to html",
|
||||
formatter_class=argparse.ArgumentDefaultsHelpFormatter)
|
||||
p.add_argument("--host", metavar='', default="hub.xpub.nl/sandbox", help='wiki host')
|
||||
p.add_argument("--path", metavar='', default="/itchwiki/", help="Wiki path. Should end with /")
|
||||
p.add_argument("--output", default="../archive", help="Output path for pages")
|
||||
p.add_argument("--one", default=False, action="store_true", help="Output one page from each category only")
|
||||
p.add_argument("--skipimages", default=False, action="store_true", help="Don't do images (for testing)")
|
||||
p.add_argument("--imgsrc", default='archive',
|
||||
choices=['archive', 'remote'],
|
||||
help="What is the source of the images?")
|
||||
|
||||
args = p.parse_args()
|
||||
print(args)
|
||||
# site and login
|
||||
|
||||
site = Site(host=args.host, path=args.path)
|
||||
wd = os.path.dirname(os.path.abspath(__file__)) # working directory
|
||||
wd_name = os.path.split(wd)[-1] # name of dir running script
|
||||
|
||||
# copy static/ to ../archive/static
|
||||
repo_static_path = './static'
|
||||
archive_static_path = os.path.join(args.output, repo_static_path)
|
||||
os.makedirs(archive_static_path, exist_ok=True) # create static/ dir in archive
|
||||
for static_file in os.listdir(path='./static'):
|
||||
copy(src=os.path.join(repo_static_path, static_file),
|
||||
dst=os.path.join(archive_static_path, static_file))
|
||||
|
||||
|
||||
with open('login.txt', 'r') as login: # read login user & pwd
|
||||
loginlines = login.read()
|
||||
user, pwd = loginlines.split('\n')
|
||||
site.login(username=user, password=pwd) # login to wiki
|
||||
|
||||
if not args.skipimages:
|
||||
imgsjson_fn = os.path.join(wd, 'images.json') # read images.json file
|
||||
with open(imgsjson_fn, 'r') as imgsjson_file:
|
||||
images_info = json.load(imgsjson_file)
|
||||
|
||||
|
||||
SLASH = "\u2044"
|
||||
|
||||
|
||||
def filenameforpage(p):
|
||||
f = p.name.replace(' ','_').replace('/', SLASH) + '.html'
|
||||
return f
|
||||
|
||||
def filenameforlink(href):
|
||||
href = urlunquote(href)
|
||||
if href.startswith("/sandbox/itchwiki/index.php/"):
|
||||
href = href[len("/sandbox/itchwiki/index.php/"):]
|
||||
href = href.replace(' ','_').replace('/', SLASH) + '.html'
|
||||
href = urlquote(href)
|
||||
return href
|
||||
|
||||
|
||||
def rewriteimglinks(tree, page):
|
||||
# invoke after img src has been rewritten
|
||||
# To: remove links to wiki File on all pages
|
||||
# but Overview_main_page page where link to publication page is added
|
||||
if page.name == 'Overview main page':
|
||||
for div_parent in tree.findall(".//div[@class='tooltip']"):
|
||||
anchor_of_img = div_parent.find(".//div/a")
|
||||
if anchor_of_img.find(".//img") is not None: # <a> needs child <img>
|
||||
a_tag = div_parent.find(".//p/span/a")
|
||||
publication_href = a_tag.attrib.get('href')
|
||||
anchor_of_img.attrib['href'] = publication_href
|
||||
else:
|
||||
for a in tree.findall(".//a[@class='image']"): # select img wrapping a
|
||||
if a.findall(".//img"): # ensure a has child: img
|
||||
a.attrib['href'] = 'javascript:void(0);' # disable href
|
||||
return tree
|
||||
|
||||
def rewritelinks(html):
|
||||
t = html5lib.parseFragment(html, treebuilder = "etree", namespaceHTMLElements = False)
|
||||
for a in t.findall(".//*[@href]"):
|
||||
linkclass = a.attrib.get("class", "")
|
||||
href = a.attrib.get("href")
|
||||
if "external" in linkclass:
|
||||
# leave external links alone
|
||||
continue
|
||||
# print ("LINK", href)
|
||||
if href.startswith("/sandbox/itchwiki/index.php/"):
|
||||
new_href = filenameforlink(href)
|
||||
a.attrib['href'] = new_href
|
||||
html = ET.tostring(t, method="html", encoding="unicode")
|
||||
return html
|
||||
|
||||
|
||||
def rewriteimgs(html, page):
|
||||
t = html5lib.parseFragment(html, treebuilder = "etree", namespaceHTMLElements = False)
|
||||
|
||||
# replace images url with local image in ../images
|
||||
for img in t.findall(".//img[@src]"):
|
||||
# imgsrc can be:
|
||||
# remote: url remains
|
||||
# archive f' images/{img_filename}'
|
||||
# local: f'../../images/{img_filename}'
|
||||
|
||||
if args.imgsrc == 'remote':
|
||||
src = img.attrib.get("src")
|
||||
if not src.startswith('http'):
|
||||
img.attrib['src'] = 'https://hub.xpub.nl' + src
|
||||
else: # local / archive imgsrc
|
||||
img_alt = img.attrib.get("alt") # alt property has filename
|
||||
img_page = f'File:{img_alt}' # find image it images.json
|
||||
try:
|
||||
# get its filename
|
||||
img_filename = images_info[img_page]['filename']
|
||||
except KeyError:
|
||||
print(Colors.WARNING, f"{img_page} is not is missing from the local downloaded images")
|
||||
print(Colors.GREEN, 'run python3 download_imgs.py to fix the issue', Colors.ENDC)
|
||||
sys.exit()
|
||||
# same dir as HTML files: archive/
|
||||
img.attrib['src'] = f'./images/{img_filename}'
|
||||
|
||||
img.attrib['srcset'] = "" # rm srcset value:it prevent imgs displaying
|
||||
img.attrib['width'] = ""
|
||||
img.attrib['height'] = ""
|
||||
|
||||
t = rewriteimglinks(tree=t, page=page)
|
||||
|
||||
html = ET.tostring(t, method="html", encoding="unicode")
|
||||
return html
|
||||
|
||||
def dumppage(p, template, rewrite_images=True):
|
||||
htmlsrc = site.parse(page=p.name)['text']['*']
|
||||
htmlsrc = rewritelinks(htmlsrc)
|
||||
if rewrite_images:
|
||||
htmlsrc = rewriteimgs(html=htmlsrc, page=p)
|
||||
html = template.render(page=p, body=htmlsrc, staticpath='.')
|
||||
with open(os.path.join(args.output, filenameforpage(p)), 'w') as f:
|
||||
f.write(html)
|
||||
# print(html, file=f)
|
||||
|
||||
publish=site.Categories['Publish']
|
||||
for cat in publish.members():
|
||||
if cat.namespace == NS_CATEGORY:
|
||||
print('dumping category {}'.format(cat.page_title))
|
||||
# title=site.Categories['Title']
|
||||
try:
|
||||
with open('templates/{}.html'.format(cat.page_title.lower())) as templatefile:
|
||||
template = Template(templatefile.read())
|
||||
except FileNotFoundError:
|
||||
with open('templates/default.html') as templatefile:
|
||||
template = Template(templatefile.read())
|
||||
for p in cat.members():
|
||||
print(p)
|
||||
dumppage(p, template, rewrite_images=not args.skipimages)
|
||||
if args.one:
|
||||
break
|
||||
else:
|
||||
print("Dumping page {}".format(cat.page_title))
|
||||
with open('templates/default.html') as templatefile:
|
||||
template = Template(templatefile.read())
|
||||
dumppage(cat, template, rewrite_images=not args.skipimages)
|
||||
|
||||
|
@ -1,63 +0,0 @@
|
||||
|
||||
# https://www.mediawiki.org/wiki/API:Main_page
|
||||
# https://mwclient.readthedocs.io/en/latest/
|
||||
|
||||
import mwclient
|
||||
from mwclient import Site
|
||||
from secrets import BOTPASSWORD
|
||||
import json
|
||||
|
||||
site = Site("hub.xpub.nl", path="/sandbox/itchwiki/")
|
||||
site.login("Bot", BOTPASSWORD)
|
||||
|
||||
for i in site.allimages():
|
||||
# Use imageinfo to request/create a thumbnail
|
||||
# NB: uses i.name as "titles" (the api call can take a list of titles)
|
||||
# but here it just uses one.
|
||||
# NB: iiurlwidth specifies a max width for the resulting thumbnail
|
||||
# check out the API doc for all the options
|
||||
# https://www.mediawiki.org/wiki/API:Imageinfo
|
||||
r = site.api("query", prop="imageinfo", titles=i.name, iiprop="url", iiurlwidth="80", formatversion=2)
|
||||
iinfo = r['query']['pages'][0]['imageinfo'][0]
|
||||
thumburl = iinfo['thumburl']
|
||||
fullsizeurl = iinfo['url']
|
||||
filepageurl = iinfo['descriptionurl']
|
||||
print ("""
|
||||
<a href="{0}"><img src="{1}"></a>
|
||||
""".format(filepageurl, thumburl))
|
||||
# print (i.name, thumburl, fullsizeurl, filepageurl)
|
||||
|
||||
|
||||
# NOW do an "ASK" api call to get semantic meta data from the same image
|
||||
# This query is the "code" that you get from the "Semantic Ask" page
|
||||
# Except you need to remove the {{#ask: and the }} at the end.
|
||||
|
||||
ask_query = """[[{0}]]
|
||||
|?Title
|
||||
|?Date
|
||||
|?Creator
|
||||
|?Format
|
||||
|?Organization
|
||||
|?Part
|
||||
|?Partof
|
||||
|?Event
|
||||
|?Topic
|
||||
|?Language
|
||||
|format=json
|
||||
|limit=50
|
||||
|offset=0
|
||||
|link=all
|
||||
|sort=
|
||||
|order=asc
|
||||
""".format(i.name)
|
||||
# print ("Made an ASK query", ask_query)
|
||||
ask_result = r = site.api("ask", query=ask_query)
|
||||
# print (json.dumps(ask_result, indent=2))
|
||||
image_metadata = ask_result['query']['results'][i.name]["printouts"]
|
||||
print (json.dumps(image_metadata, indent=2))
|
||||
|
||||
# Calling the api to make/give a thumbnail of a particular image
|
||||
# https://hub.xpub.nl/sandbox/itchwiki/api.php?action=query&format=json&prop=imageinfo&iiprop=url&iiurlwidth=320&titles=File:VF250Commitment-18.jpg
|
||||
# site.api()
|
||||
# Magic URL to generate and get the URL of a thumbnail of an image
|
||||
# https://hub.xpub.nl/sandbox/itchwiki/api.php?action=query&format=json&prop=imageinfo&iiprop=url&iiurlwidth=640&titles=File:VF250Commitment-18.jpg
|
@ -1,350 +0,0 @@
|
||||
|
||||
<p>
|
||||
<h3>1970-02-26 (1/1970/2/26)</h3>
|
||||
<h2>The Philippine Collegian, Part 1 of 2</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Oil_Imperialism-0.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/5/5b/Oil_Imperialism-0.jpg/80px-Oil_Imperialism-0.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 1 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-01.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/b/b9/Sambayanan-01.jpg/80px-Sambayanan-01.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 2 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-02.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/3/3f/Sambayanan-02.jpg/80px-Sambayanan-02.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 3 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-03.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/7/7c/Sambayanan-03.jpg/80px-Sambayanan-03.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 4 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-04.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/5/5c/Sambayanan-04.jpg/80px-Sambayanan-04.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 5 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-05.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/7/77/Sambayanan-05.jpg/80px-Sambayanan-05.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 6 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-06.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/3/35/Sambayanan-06.jpg/80px-Sambayanan-06.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 7 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-07.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/2/28/Sambayanan-07.jpg/80px-Sambayanan-07.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-05-20 (1/1972/5/20)</h3>
|
||||
<h2>Sambayanan, Part 8 of 8</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:Sambayanan-08.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/a/ae/Sambayanan-08.jpg/80px-Sambayanan-08.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-09-21 (1/1972/9/21)</h3>
|
||||
<h2>The Lessons of Martial Law, Part 1 of 4</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF436_The_lessons_of_martial_law-00.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/e/e1/VF436_The_lessons_of_martial_law-00.jpg/80px-VF436_The_lessons_of_martial_law-00.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-09-21 (1/1972/9/21)</h3>
|
||||
<h2>The Lessons of Martial Law, Part 2 of 4</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF436_The_lessons_of_martial_law-01.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/a/a6/VF436_The_lessons_of_martial_law-01.jpg/80px-VF436_The_lessons_of_martial_law-01.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-09-21 (1/1972/9/21)</h3>
|
||||
<h2>The Lessons of Martial Law, Part 3 of 4</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF436_The_lessons_of_martial_law-02.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/4/4d/VF436_The_lessons_of_martial_law-02.jpg/80px-VF436_The_lessons_of_martial_law-02.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1972-09-21 (1/1972/9/21)</h3>
|
||||
<h2>The Lessons of Martial Law, Part 4 of 4</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF436_The_lessons_of_martial_law-03.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/e/e0/VF436_The_lessons_of_martial_law-03.jpg/80px-VF436_The_lessons_of_martial_law-03.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 1 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-00.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/8/8c/VF481_The_logistics_of_repression-00.jpg/80px-VF481_The_logistics_of_repression-00.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 2 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-01.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/9/9c/VF481_The_logistics_of_repression-01.jpg/80px-VF481_The_logistics_of_repression-01.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 3 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-02.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/a/ac/VF481_The_logistics_of_repression-02.jpg/80px-VF481_The_logistics_of_repression-02.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 4 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-03.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/1/1f/VF481_The_logistics_of_repression-03.jpg/80px-VF481_The_logistics_of_repression-03.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 5 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-04.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/9/95/VF481_The_logistics_of_repression-04.jpg/80px-VF481_The_logistics_of_repression-04.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 6 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-05.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/6/6e/VF481_The_logistics_of_repression-05.jpg/80px-VF481_The_logistics_of_repression-05.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 7 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-06.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/d/da/VF481_The_logistics_of_repression-06.jpg/80px-VF481_The_logistics_of_repression-06.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 8 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-07.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/f/fb/VF481_The_logistics_of_repression-07.jpg/80px-VF481_The_logistics_of_repression-07.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 9 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-08.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/2/21/VF481_The_logistics_of_repression-08.jpg/80px-VF481_The_logistics_of_repression-08.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 10 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-09.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/3/3e/VF481_The_logistics_of_repression-09.jpg/80px-VF481_The_logistics_of_repression-09.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 11 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-10.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/2/2f/VF481_The_logistics_of_repression-10.jpg/80px-VF481_The_logistics_of_repression-10.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 12 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-11.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/4/42/VF481_The_logistics_of_repression-11.jpg/80px-VF481_The_logistics_of_repression-11.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 13 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-12.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/0/04/VF481_The_logistics_of_repression-12.jpg/80px-VF481_The_logistics_of_repression-12.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 14 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-13.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/8/8e/VF481_The_logistics_of_repression-13.jpg/80px-VF481_The_logistics_of_repression-13.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 15 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-14.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/6/6f/VF481_The_logistics_of_repression-14.jpg/80px-VF481_The_logistics_of_repression-14.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 16 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-15.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/f/f6/VF481_The_logistics_of_repression-15.jpg/80px-VF481_The_logistics_of_repression-15.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 17 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-16.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/1/17/VF481_The_logistics_of_repression-16.jpg/80px-VF481_The_logistics_of_repression-16.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 18 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-17.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/f/f0/VF481_The_logistics_of_repression-17.jpg/80px-VF481_The_logistics_of_repression-17.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 19 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-18.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/3/3d/VF481_The_logistics_of_repression-18.jpg/80px-VF481_The_logistics_of_repression-18.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 20 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-19.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/6/69/VF481_The_logistics_of_repression-19.jpg/80px-VF481_The_logistics_of_repression-19.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 21 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-20.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/f/fb/VF481_The_logistics_of_repression-20.jpg/80px-VF481_The_logistics_of_repression-20.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 22 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-21.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/9/98/VF481_The_logistics_of_repression-21.jpg/80px-VF481_The_logistics_of_repression-21.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 23 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-22.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/a/aa/VF481_The_logistics_of_repression-22.jpg/80px-VF481_The_logistics_of_repression-22.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 24 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-23.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/a/a6/VF481_The_logistics_of_repression-23.jpg/80px-VF481_The_logistics_of_repression-23.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 25 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-24.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/e/ed/VF481_The_logistics_of_repression-24.jpg/80px-VF481_The_logistics_of_repression-24.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 26 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-25.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/3/3e/VF481_The_logistics_of_repression-25.jpg/80px-VF481_The_logistics_of_repression-25.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 27 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-26.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/c/c7/VF481_The_logistics_of_repression-26.jpg/80px-VF481_The_logistics_of_repression-26.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 28 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-27.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/c/c3/VF481_The_logistics_of_repression-27.jpg/80px-VF481_The_logistics_of_repression-27.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 29 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-28.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/4/46/VF481_The_logistics_of_repression-28.jpg/80px-VF481_The_logistics_of_repression-28.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 30 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-29.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/e/e3/VF481_The_logistics_of_repression-29.jpg/80px-VF481_The_logistics_of_repression-29.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 31 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-30.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/3/32/VF481_The_logistics_of_repression-30.jpg/80px-VF481_The_logistics_of_repression-30.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 32 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-31.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/f/fb/VF481_The_logistics_of_repression-31.jpg/80px-VF481_The_logistics_of_repression-31.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 33 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-32.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/2/2c/VF481_The_logistics_of_repression-32.jpg/80px-VF481_The_logistics_of_repression-32.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 34 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-33.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/5/56/VF481_The_logistics_of_repression-33.jpg/80px-VF481_The_logistics_of_repression-33.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 35 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-34.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/2/2b/VF481_The_logistics_of_repression-34.jpg/80px-VF481_The_logistics_of_repression-34.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 36 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-35.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/8/88/VF481_The_logistics_of_repression-35.jpg/80px-VF481_The_logistics_of_repression-35.jpg"></a>
|
||||
</p>
|
||||
|
||||
|
||||
<p>
|
||||
<h3>1977-01-01 (1/1977/1/1)</h3>
|
||||
<h2>The Logistics of Repression, Part 37 of 86</h2>
|
||||
<a href="http://hub.xpub.nl/sandbox/itchwiki/index.php/File:VF481_The_logistics_of_repression-36.jpg"><img src="http://hub.xpub.nl/sandbox/itchwiki/images/thumb/2/24/VF481_The_logistics_of_repression-36.jpg/80px-VF481_The_logistics_of_repression-36.jpg"></a>
|
||||
</p>
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 1.7 MiB |
@ -1,93 +0,0 @@
|
||||
"""
|
||||
Let's say you're interested in documents related to the topic "US Foreign Policy"
|
||||
|
||||
You can start with an "ask" (first just from the "Semantic Ask" interface) and use the condition:
|
||||
|
||||
[[Topic::US Foreign Policy]]
|
||||
|
||||
Press "Find results" and you get a lot of pages as result.
|
||||
Then you would add the info you're interested in the "printout selection" box, and also make sure to sort the results with the part number to make sure document pages are in order.
|
||||
|
||||
Finally, click on the "Code" view and copy paste the code -- but
|
||||
be careful NOT to copy the "{{#ask:" and the "}}" at the end.
|
||||
|
||||
This you can then paste into the API Sandbox to test it if you want...
|
||||
OR just paste it into the code below as the "ask_query" variable.
|
||||
|
||||
https://hub.xpub.nl/sandbox/itchwiki/index.php/Special:ApiSandbox#action=ask
|
||||
|
||||
"""
|
||||
|
||||
# https://www.mediawiki.org/wiki/API:Main_page
|
||||
# https://mwclient.readthedocs.io/en/latest/
|
||||
|
||||
import datetime
|
||||
import json
|
||||
|
||||
import mwclient
|
||||
from mwclient import Site
|
||||
from secrets import BOTPASSWORD
|
||||
|
||||
|
||||
site = Site("hub.xpub.nl", path="/sandbox/itchwiki/")
|
||||
site.login("Bot", BOTPASSWORD)
|
||||
|
||||
ask_query = """
|
||||
[[Topic::US Foreign Policy]]
|
||||
|?Date
|
||||
|?Part
|
||||
|?Partof
|
||||
|?Title
|
||||
|format=broadtable
|
||||
|limit=50
|
||||
|offset=0
|
||||
|link=all
|
||||
|sort=Date,Title,Part
|
||||
|order=asc,asc,asc
|
||||
|headers=show
|
||||
|searchlabel=... further results
|
||||
|class=sortable wikitable smwtable
|
||||
"""
|
||||
|
||||
# Tested in the APISandbox
|
||||
# See: https://hub.xpub.nl/sandbox/itchwiki/index.php/Special:ApiSandbox#action=ask&format=json&query=%5B%5BTopic%3A%3AUS%20Foreign%20Policy%5D%5D%20%20%7C%3FPart%20%20%7C%3FPartof%20%20%7C%3FTitle%20%20%7C%3FDate%20%20%7Cformat%3Dbroadtable%20%20%7Climit%3D50%20%20%7Coffset%3D0%20%20%7Clink%3Dall%20%20%7Csort%3D%20%20%7Corder%3Dasc%20%20%7Cheaders%3Dshow%20%20%7Csearchlabel%3D...%20further%20results%20%20%7Cclass%3Dsortable%20wikitable%20smwtable&formatversion=2
|
||||
# copy/paste the URL above and press "Make request" to see the results
|
||||
|
||||
response = site.api("ask", query=ask_query, format="json")
|
||||
results = response['query']['results']
|
||||
|
||||
# Results is a dictionary where the keys are wiki names like "File:KSP Kilusan Vol 2 Nos 2 and 3-26.jpg"
|
||||
# results[wikiname] is then another dictionary with all the results specific to that item
|
||||
for wikiname in results:
|
||||
item = results[wikiname]
|
||||
|
||||
# FOR DEBUGGING uncomment the print
|
||||
# print (wikiname, json.dumps(item, indent=2))
|
||||
|
||||
date = datetime.date.fromtimestamp(int(item["printouts"]["Date"][0]['timestamp']))
|
||||
date_raw = item["printouts"]["Date"][0]['raw']
|
||||
title = item["printouts"]["Title"][0]["fulltext"]
|
||||
part = int(item["printouts"]["Part"][0])
|
||||
partof = int(item["printouts"]["Partof"][0])
|
||||
|
||||
r = site.api("query", prop="imageinfo", \
|
||||
titles=wikiname, \
|
||||
iiprop="url", \
|
||||
iiurlwidth="80", \
|
||||
formatversion=2)
|
||||
iinfo = r['query']['pages'][0]['imageinfo'][0]
|
||||
thumburl = iinfo['thumburl']
|
||||
fullsizeurl = iinfo['url']
|
||||
filepageurl = iinfo['descriptionurl']
|
||||
# nb: the code lines *need* to be indented
|
||||
# to stay INSIDE the loop
|
||||
# the output text between the """ can break this rule
|
||||
print ("""
|
||||
<p>
|
||||
<h3>{} ({})</h3>
|
||||
<h2>{}, Part {} of {}</h2>
|
||||
<a href="{}"><img src="{}"></a>
|
||||
</p>
|
||||
""".format(date, date_raw, title, part, partof, filepageurl, thumburl))
|
||||
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 157 KiB |
@ -1,23 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
python3 upload_imgs_dir.py \
|
||||
--title 'Nassa News: Vol. 21 No. 7' \
|
||||
--creator 'The National Secretariat of Social Action Justice and Peace' \
|
||||
--date '1984/07/01' \
|
||||
--org 'Nationalist Alliance for Justice, Freedom and Democracy (NAJFD)' \
|
||||
--format 'Statement' \
|
||||
--event 'The ARTEX Strike' \
|
||||
--topic 'Workers rights' \
|
||||
--language 'English' \
|
||||
--dir '/full/path/to/2020_bantayog/Folder name' \
|
||||
|
||||
|
||||
# --dry
|
||||
|
||||
# Note:
|
||||
# * Add this values to you upload specific upload.
|
||||
# * --dry can be enabled to show you what will be uploaded and the metadata, without actully uploading it
|
||||
# * parameters --event --topic can be added
|
||||
# * \ allow you to continue the command of a different line
|
||||
#
|
||||
# Get help: python3 upload_imgs_dir.py --help
|
@ -0,0 +1,76 @@
|
||||
import os, json
|
||||
from mwclient import Site
|
||||
from pprint import pprint
|
||||
from jinja2 import Template
|
||||
from functions import pandoc, page_props
|
||||
|
||||
site = Site(host='hub.xpub.nl/sandbox', path='/itchwiki/')
|
||||
wd = os.path.dirname(os.path.abspath(__file__)) # working directory
|
||||
imgdir = os.path.join(wd, 'images')
|
||||
imgsjson_fn = os.path.join(wd, 'images.json')
|
||||
with open(imgsjson_fn, 'r') as imgsjson_file:
|
||||
images_info = json.load(imgsjson_file)
|
||||
|
||||
static_html = os.path.join(wd, 'static_html')
|
||||
os.makedirs(static_html, exist_ok=True) # create images/ dir
|
||||
|
||||
with open(os.path.join(wd, 'login.txt'), 'r') as login: # read login user & pwd
|
||||
loginlines = login.read()
|
||||
user, pwd = loginlines.split('\n')
|
||||
site.login(username=user, password=pwd) # login to wiki
|
||||
|
||||
|
||||
page_html_template = '''
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="../static/style.css" />
|
||||
<title>{{title}}</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>{{ title }}</h1>
|
||||
<p><time datetime="{{date}}">{{date}}</time></p>
|
||||
<div id="img">
|
||||
<img src="{{ imgsrc }}" />
|
||||
</div>
|
||||
<div id="content">
|
||||
{{ content }}
|
||||
</div>
|
||||
<footer>
|
||||
Part {{part}} of {{partof}}
|
||||
</footer>
|
||||
</body>
|
||||
</html>
|
||||
'''
|
||||
page_template = Template(page_html_template)
|
||||
|
||||
|
||||
for img_info in images_info.values():
|
||||
print(img_info)
|
||||
page_name = img_info['name']
|
||||
page = site.pages[page_name]
|
||||
# print(page)
|
||||
# pprint(page.__dict__)
|
||||
# print(dir(page))
|
||||
pagetext = page.text()
|
||||
pageproperties = page_props(wikicontent=pagetext)
|
||||
print(pageproperties)
|
||||
|
||||
if pageproperties.get('Title'):
|
||||
pagetext_html = pandoc(pwd=wd ,content=pagetext, format_in='mediawiki', format_out='html')
|
||||
# print('pagetext', pagetext)
|
||||
# print('pagetext_html', pagetext_html)
|
||||
page_html = page_template.render(title=pageproperties.get('Title'),
|
||||
date=pageproperties.get('Date'),
|
||||
imgsrc=os.path.join(imgdir, img_info.get('filename')),
|
||||
content=pagetext_html,
|
||||
part=pageproperties.get('Part'),
|
||||
partof=pageproperties.get('Partof'))
|
||||
htmlpage_fn = "{}_{}.html".format(
|
||||
pageproperties.get('Title').replace(" ", ""),
|
||||
pageproperties.get('Part').zfill(3)
|
||||
)
|
||||
print(htmlpage_fn)
|
||||
with open(os.path.join(static_html, htmlpage_fn), 'w') as htmlfile:
|
||||
htmlfile.write(page_html)
|
@ -1,9 +0,0 @@
|
||||
#!/bin/sh
|
||||
PDF="$1"
|
||||
echo "$PDF"
|
||||
DIR=`echo "$PDF" | sed s/\.pdf//`
|
||||
echo "$DIR"
|
||||
mkdir "$DIR"
|
||||
echo "Starting convertion ..."
|
||||
convert -quality 100 -density 300 "$PDF" "$DIR/"%02d.jpg
|
||||
echo "PDF converted thanks to Damla aka Imagemagick ninja"
|
@ -1,26 +0,0 @@
|
||||
import os, argparse, sys, re, json
|
||||
from mwclient import (Site,
|
||||
errors)
|
||||
|
||||
# API CALL
|
||||
# https://hub.xpub.nl/sandbox/itchwiki/api.php?action=smwbrowse&browse=pvalue¶ms={ "limit": 1500, "offset": 0, "property" : "Title", "search": "" }&format=json
|
||||
# generated orgs.json
|
||||
|
||||
# login
|
||||
site = Site(host='hub.xpub.nl/sandbox', path='/itchwiki/')
|
||||
|
||||
wd =os.path.dirname(os.path.abspath(__file__)) # parent working directory
|
||||
with open(os.path.join(wd, 'login.txt'), 'r') as login: # read login user & pwd
|
||||
loginlines = login.read()
|
||||
user, pwd = loginlines.split('\n')
|
||||
site.login(username=user, password=pwd) # login to wiki
|
||||
|
||||
|
||||
with open('titles.json', 'r') as f:
|
||||
titles = json.load(f)
|
||||
|
||||
for pagename in titles['query']:
|
||||
page = site.pages[pagename]
|
||||
if not page.text(): # if page has no text
|
||||
print(pagename)
|
||||
page.save('{{Publication}}\n[[Category:Title]]')
|
@ -1,33 +0,0 @@
|
||||
import os, argparse, sys, re, json
|
||||
from mwclient import (Site,
|
||||
errors)
|
||||
|
||||
# API CALL
|
||||
# https://hub.xpub.nl/sandbox/itchwiki/api.php?action=smwbrowse&browse=pvalue¶ms={ "limit": 1500, "offset": 0, "property" : "Title", "search": "" }&format=json
|
||||
# generated orgs.json
|
||||
# >>> result = site.api('query', prop='coordinates', titles='Oslo|Copenhagen')
|
||||
# login
|
||||
site = Site(host='hub.xpub.nl/sandbox', path='/itchwiki/')
|
||||
|
||||
wd =os.path.dirname(os.path.abspath(__file__)) # parent working directory
|
||||
with open(os.path.join(wd, 'login.txt'), 'r') as login: # read login user & pwd
|
||||
loginlines = login.read()
|
||||
user, pwd = loginlines.split('\n')
|
||||
site.login(username=user, password=pwd) # login to wiki
|
||||
|
||||
# To query a large number of ite:
|
||||
|
||||
for i in range(0, 1500, 100):
|
||||
# variable i will increase 100 at each iteration
|
||||
# between 0 and 1400
|
||||
# and will make the offset parameter change
|
||||
print('\n', f'Querying from {i} to {i+100}', '\n')
|
||||
|
||||
ask_query = f'[[Category:Title]]|format=json|limit=100|offset={i}'
|
||||
|
||||
response = site.api(action='ask', query=ask_query)
|
||||
for pagetitle in response['query']['results']:
|
||||
print(pagetitle)
|
||||
page = site.pages[pagetitle]
|
||||
# # text = page.text()
|
||||
page.save('{{Publication}}\n[[Category:Title]]')
|
@ -1,15 +0,0 @@
|
||||
import os
|
||||
from jinja2 import Template
|
||||
|
||||
wd = os.path.dirname(os.path.abspath(__file__)) # working directory
|
||||
|
||||
# read template files
|
||||
with open(os.path.join(wd, '../templates/scatch.html')) as document_html:
|
||||
template = Template(document_html.read())
|
||||
|
||||
imgs_list = ['images/01.jpg', 'images/02.jpg', 'images/03.jpg']
|
||||
|
||||
template_render = template.render(title=':) Hello Sandra',
|
||||
imgs=imgs_list
|
||||
)
|
||||
print(template_render)
|
@ -0,0 +1,24 @@
|
||||
import os
|
||||
from mwclient import Site
|
||||
from pprint import pprint
|
||||
|
||||
site = Site(host='hub.xpub.nl/sandbox', path='/itchwiki/')
|
||||
wd = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) # parent working directory
|
||||
|
||||
with open(os.path.join(wd, 'login.txt'), 'r') as login: # read login user & pwd
|
||||
loginlines = login.read()
|
||||
user, pwd = loginlines.split('\n')
|
||||
site.login(username=user, password=pwd) # login to wiki
|
||||
|
||||
print(site)
|
||||
|
||||
for n, img in enumerate(site.allimages()):
|
||||
if n < 5:
|
||||
print(img)
|
||||
print('Image attributes:')
|
||||
pprint(img.__dict__) # info contained in each img object
|
||||
print('Image object methods:', dir(img))
|
||||
# important img info to dictionary
|
||||
print(img.name, img.page_title, img.imageinfo['timestamp'], img.imageinfo['url'],
|
||||
img.imageinfo['descriptionshorturl'])
|
||||
print('\n')
|
@ -1,148 +0,0 @@
|
||||
body {
|
||||
background-color: #F4EBE8;
|
||||
font-family: Roboto Mono;
|
||||
}
|
||||
|
||||
|
||||
.projtextcont{
|
||||
display: inline-block;
|
||||
/*align-items: center;
|
||||
justify-content: center*/
|
||||
color:#371F10;
|
||||
margin-left:200px;
|
||||
margin-bottom: 100px;
|
||||
margin-top:60px;
|
||||
}
|
||||
|
||||
.projtext{
|
||||
width: 80%;
|
||||
display: inline-block;
|
||||
text-align: justify;
|
||||
}
|
||||
|
||||
h1{
|
||||
font-size:50px;
|
||||
display: block;
|
||||
width:65%;
|
||||
text-align: left;
|
||||
background-color: transparent;
|
||||
right:auto;
|
||||
position: relative;
|
||||
padding: 0px;
|
||||
top:0%;
|
||||
z-index: 0;
|
||||
margin-bottom:15px;
|
||||
/*margin-top: 50px;*/
|
||||
}
|
||||
|
||||
h2{
|
||||
font-size:23px;
|
||||
display: block;
|
||||
width:65%;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.img1{
|
||||
display: inline-block;
|
||||
width:80%;
|
||||
margin-top: 20px;
|
||||
margin-bottom: 20px;
|
||||
right: 0%;
|
||||
align-content: right;
|
||||
}
|
||||
|
||||
.img1 img{
|
||||
margin-top: 20px;
|
||||
width: 60%;
|
||||
float:right;
|
||||
}
|
||||
|
||||
.img2{
|
||||
display: inline-block;
|
||||
width:100%;
|
||||
margin-top: 20px;
|
||||
margin-bottom: 20px;
|
||||
right: 0%;
|
||||
align-content: right;
|
||||
}
|
||||
|
||||
.img2 img{
|
||||
margin: 20px;
|
||||
margin-left: 0px;
|
||||
width: 45%;
|
||||
float:left;
|
||||
}
|
||||
|
||||
.img3{
|
||||
display: flex;
|
||||
width:100%;
|
||||
margin-top: 0px;
|
||||
margin-bottom: 20px;
|
||||
right: 0%;
|
||||
align-content: right;
|
||||
}
|
||||
|
||||
.img3 img{
|
||||
margin: 50px;
|
||||
margin-right: 0px;
|
||||
margin-bottom: 0px;
|
||||
width: 55%;
|
||||
right: 0px;
|
||||
float: right;
|
||||
|
||||
}
|
||||
/*.pagelink{
|
||||
position: fixed;
|
||||
display: inline;
|
||||
left:0px;
|
||||
width:20px;
|
||||
height:20px;
|
||||
padding:10px;
|
||||
background-color: white;
|
||||
z-index: 10;
|
||||
font-size: 18px;
|
||||
text-align: center;
|
||||
border-top-style: solid;
|
||||
border-right-style: solid;
|
||||
border-bottom-style: solid;
|
||||
/*border-style: solid;
|
||||
border-width: 1px;
|
||||
border-color: #371F10;
|
||||
|
||||
}
|
||||
|
||||
.pagelink:hover{
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
|
||||
.pagelink{
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
.pagelink a{
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/*.pagelink a:active{
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
|
||||
.active .pagelink:after{
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
|
||||
|
||||
.pagelink .pagename{
|
||||
display: inline;
|
||||
position: absolute;
|
||||
width: auto;
|
||||
padding: 5px;
|
||||
margin-left: 25px;
|
||||
font-size: 13px;
|
||||
background-color: white;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.pagelink:hover .pagename{
|
||||
visibility: visible;
|
||||
}*/
|
@ -1,163 +0,0 @@
|
||||
body {
|
||||
background-color: #aaa4a0;
|
||||
color: #371F10;
|
||||
font-family: Roboto Mono, monospace;
|
||||
}
|
||||
/*.pagelink{
|
||||
position: fixed;
|
||||
display: inline;
|
||||
left:0px;
|
||||
/* width:20px;
|
||||
height:20px;
|
||||
padding: 0px 5px 0px 5px;
|
||||
background-color: white;
|
||||
z-index: 10;
|
||||
font-size: 30px;
|
||||
text-align: center;
|
||||
border-top-style: solid;
|
||||
border-right-style: solid;
|
||||
border-bottom-style: solid;
|
||||
/*border-style: solid;
|
||||
border-width: 1px;
|
||||
border-color: #371F10;
|
||||
|
||||
}*/
|
||||
|
||||
/*.pagelink:hover{
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
.pagelink a{
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.pagelink .pagename{
|
||||
display: inline;
|
||||
position: absolute;
|
||||
width: auto;
|
||||
padding: 5px;
|
||||
margin-left: 25px;
|
||||
font-size: 13px;
|
||||
background-color: white;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.pagelink:hover .pagename{
|
||||
visibility: visible;
|
||||
}*/
|
||||
|
||||
.linkscont{
|
||||
margin-top: 10%;
|
||||
height: 100vh;
|
||||
width: auto;
|
||||
position: fixed;
|
||||
left:0%;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.pagelink{
|
||||
text-align:center;
|
||||
vertical-align:middle;
|
||||
display: block;
|
||||
/*justify-content: center;*/
|
||||
align-items: center;
|
||||
position: fixed;
|
||||
/*text-align: left;*/
|
||||
/*display: block;*/
|
||||
left:0px;
|
||||
width:36px;
|
||||
height:36px;
|
||||
padding-top: 2px;
|
||||
background-color: white;
|
||||
z-index: 2;
|
||||
/*text-align: justify;*/
|
||||
border-top-style: solid;
|
||||
border-right-style: solid;
|
||||
border-bottom-style: solid;
|
||||
/*border-style: solid;*/
|
||||
border-width: 1px;
|
||||
border-color: #371F10;
|
||||
|
||||
}
|
||||
|
||||
.icon{
|
||||
text-align:center;
|
||||
vertical-align:middle;
|
||||
/* display: block;*/
|
||||
/*justify-content: center;*/
|
||||
align-items: center;
|
||||
font-size: 24px;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
vertical-align:middle;
|
||||
}
|
||||
|
||||
.active, .pagelink:hover{
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
|
||||
.pagelink{
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
.pagelink a{
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/*.pagelink a:active{
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
|
||||
.active .pagelink:after{
|
||||
background-color: #0BEFEB;
|
||||
}*/
|
||||
.mw-selflink{
|
||||
/*width: 120%;
|
||||
height: 120%;
|
||||
background-color: #0BEFEB;*/
|
||||
color:blue;
|
||||
|
||||
}
|
||||
|
||||
.pagelink .pagename{
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
width: auto;
|
||||
padding: 5px;
|
||||
margin-left: 20px;
|
||||
font-size: 12px;
|
||||
background-color: white;
|
||||
visibility: hidden;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.pagelink:hover .pagename{
|
||||
visibility: visible;
|
||||
position: absolute;
|
||||
z-index: 20;
|
||||
}
|
||||
|
||||
h1 {
|
||||
position: fixed;
|
||||
right:0%;
|
||||
bottom: 83%;
|
||||
text-align: right;
|
||||
background-color: rgba(11,239,235,0.7);
|
||||
color: #371F10;
|
||||
padding: 3px 35px 3px 10px;
|
||||
z-index: 10;
|
||||
font-size: 28px;
|
||||
max-width: 93%;
|
||||
}
|
||||
|
||||
a, a:visited{
|
||||
color:#371F10;
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
text-decoration: none;
|
||||
color: blue;
|
||||
}
|
||||
|
||||
a.image {cursor: default!important;} /* KEEP THIS: it is important to avoid images to seeming like links */
|
||||
|
@ -1,239 +0,0 @@
|
||||
body {
|
||||
background: white;
|
||||
height: 100vh;
|
||||
}
|
||||
|
||||
/*.img {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
|
||||
.thumb{
|
||||
display: inline;
|
||||
}*/
|
||||
|
||||
h1{
|
||||
font-size: 20px;
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
.thumbborder {
|
||||
/*margin-bottom: 15px;*/
|
||||
/*border : 20px solid blue;*/
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: inline-block;
|
||||
text-align: left;
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.title{
|
||||
margin-top: 15px;
|
||||
line-height: 1.3;
|
||||
}
|
||||
|
||||
.linkscont{
|
||||
position-top:0px;
|
||||
}
|
||||
|
||||
/*.pagelink{
|
||||
position: fixed;
|
||||
display: inline;
|
||||
left:0px;
|
||||
width:20px;
|
||||
height:20px;
|
||||
padding:10px;
|
||||
background-color: white;
|
||||
z-index: 10;
|
||||
font-size: 18px;
|
||||
text-align: center;
|
||||
border-top-style: solid;
|
||||
border-right-style: solid;
|
||||
border-bottom-style: solid;
|
||||
/*border-style: solid;
|
||||
border-width: 1px;
|
||||
border-color: #371F10;
|
||||
|
||||
}
|
||||
|
||||
.pagelink:hover{
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
.pagelink a{
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.pagelink .pagename{
|
||||
display: inline;
|
||||
position: absolute;
|
||||
width: auto;
|
||||
padding: 5px;
|
||||
margin-left: 25px;
|
||||
font-size: 13px;
|
||||
background-color: white;
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.pagelink:hover .pagename{
|
||||
visibility: visible;
|
||||
}*/
|
||||
|
||||
.tooltip {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
width: 70px;
|
||||
margin: 16px;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.tooltip .tooltiptext {
|
||||
display: block;
|
||||
visibility: hidden;
|
||||
width: 400%;
|
||||
height: auto;
|
||||
/*min-height: 100%;*/
|
||||
background-color: #0BEFEB;
|
||||
/*opacity: 80%;*/
|
||||
color: black;
|
||||
text-align: left;
|
||||
padding: 10px;
|
||||
/*border-radius: 6px;*/
|
||||
/* font-family: CothamSans;*/
|
||||
font-size: 16px;
|
||||
position: absolute;
|
||||
/*top: 0px;*/
|
||||
z-index: 1;
|
||||
margin-top:-10px;
|
||||
/*vertical-align: top;*/
|
||||
line-height: 1.3;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.tooltip:hover .tooltiptext {
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
|
||||
|
||||
ul#menu li{
|
||||
display: inline;
|
||||
list-style: none;
|
||||
/* margin-left: 10%
|
||||
margin-right: 10%;*/
|
||||
align-content: initial;
|
||||
|
||||
}
|
||||
|
||||
ul#menu{
|
||||
margin-left: 45px;
|
||||
margin-right: 10px;
|
||||
top:-15px;
|
||||
bottom: 10px;
|
||||
padding-left: 0px;
|
||||
border: none;
|
||||
width: 80vw;
|
||||
height:100%;
|
||||
left:0px;
|
||||
margin-bottom: 20px;
|
||||
padding-bottom: 20px;
|
||||
position: absolute;
|
||||
scrollbar-width: thin;
|
||||
}
|
||||
|
||||
|
||||
div#myBtnContainer{
|
||||
/*background-color: #F4EBE8;*/
|
||||
/*margin-top: 20px;*/
|
||||
margin-left: 30px;
|
||||
margin-bottom: 30px;
|
||||
border: none;
|
||||
max-width: 15vw;
|
||||
display: inline;
|
||||
/* visibility: hidden;*/
|
||||
height:100%;
|
||||
right:0px;
|
||||
top:0px;
|
||||
position: fixed;
|
||||
padding:10px;
|
||||
overflow-y: hidden;
|
||||
/*z-index: -1;*/
|
||||
overflow-y: scroll;
|
||||
scrollbar-width: thin;
|
||||
/* overflow-y: hidden;*/
|
||||
}
|
||||
|
||||
div#myBtnContainer:hover{
|
||||
|
||||
}
|
||||
|
||||
/*div#bigbtncontainer{
|
||||
overflow-y: hidden;
|
||||
-ms-overflow-style: none; Internet Explorer 10+
|
||||
scrollbar-width: thin;
|
||||
/*overflow-y: scroll;
|
||||
|
||||
}*/
|
||||
/*div#myBtnContainer:hover{
|
||||
background-color: white;
|
||||
z-index: 1;
|
||||
}*/
|
||||
|
||||
|
||||
.filter {
|
||||
display: inline-block;
|
||||
box-shadow: 8px 8px 8px #C4BCB9;
|
||||
}
|
||||
|
||||
.show {
|
||||
display: inline-block;
|
||||
/*box-shadow: 8px 8px 8px #303E88;*/
|
||||
box-shadow: 10px 10px 15px #0BEFEB;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Style the buttons */
|
||||
.btn {
|
||||
border: none;
|
||||
outline: none;
|
||||
font-family: Roboto Mono;
|
||||
font-size: 18px;
|
||||
text-align: left;
|
||||
display: block;
|
||||
/*padding: 4px 6px;*/
|
||||
/*text-shadow: 2px 2px 2px #9D9C9C;*/
|
||||
/*background-color: blue;*/
|
||||
cursor: pointer;
|
||||
margin: 8px 2px 8px 2px;
|
||||
padding: 4px;
|
||||
color: #371F10;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
.btn:hover {
|
||||
background-color: #F4EBE8;
|
||||
}
|
||||
|
||||
.btn.active {
|
||||
background-color: #0BEFEB;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.mw-parser-output{
|
||||
display: inline;
|
||||
}
|
||||
|
||||
::-webkit-scrollbar {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.line{
|
||||
margin-top: 10px;
|
||||
margin-bottom: 10px;
|
||||
width: 80vw;
|
||||
height: 2px;
|
||||
background-color: #0BEFEB;
|
||||
}
|
||||
|
||||
a.image {cursor: pointer!important;} /* KEEP THIS: show imgs as link in Overview */
|
@ -1,107 +0,0 @@
|
||||
|
||||
#top {
|
||||
padding-top: 25px;
|
||||
padding-left: 50px;
|
||||
}
|
||||
|
||||
body {
|
||||
background-color: #F4EBE8;
|
||||
font-family: Roboto Mono;
|
||||
}
|
||||
|
||||
/* Organizations list */
|
||||
.collapsible{
|
||||
font-size:14px;
|
||||
padding-left: 70px;
|
||||
line-height: 1;
|
||||
color: #371F10;
|
||||
}
|
||||
|
||||
.active, .collapsible:hover {
|
||||
color: blue;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.active, .collapsible:after {
|
||||
padding-top: 10px;
|
||||
padding-left: 85px;
|
||||
color: #371F10;
|
||||
font-weight: bold;
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
/* Droped-down publication links */
|
||||
.content {
|
||||
max-height: 0;
|
||||
overflow: hidden;
|
||||
transition: max-height 0.2s ease-out;
|
||||
padding-left: 50px;
|
||||
background-color: #371F10;
|
||||
position: relative;
|
||||
line-height: 30px;
|
||||
margin-left: 85px;
|
||||
color: white;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.content a {
|
||||
color:white;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.content a:hover {
|
||||
color: blue;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
/* Scroll buttons */
|
||||
.scrl {
|
||||
position: fixed;
|
||||
background-color: white;
|
||||
color:#371F10;
|
||||
cursor: pointer;
|
||||
border:none;
|
||||
border-right:1px solid #D1C8C8;
|
||||
font-size: 25px;
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
font-weight: bold;
|
||||
z-index: 10;
|
||||
bottom: 0%;
|
||||
}
|
||||
|
||||
.scrl:hover {
|
||||
color: #0BEFEB;
|
||||
}
|
||||
|
||||
button.down span, button.up span {
|
||||
position:relative; left: 30%;
|
||||
position:relative; bottom: 65%;
|
||||
}
|
||||
|
||||
.up {
|
||||
right: 53px;
|
||||
}
|
||||
|
||||
.down {
|
||||
right: 0%;
|
||||
}
|
||||
|
||||
button.bottom span, button.top span {
|
||||
position:relative; left: 15%;
|
||||
position:relative; bottom: 65%;
|
||||
}
|
||||
|
||||
.top {
|
||||
right: 159px;
|
||||
}
|
||||
|
||||
.bottom {
|
||||
right: 106px;
|
||||
}
|
||||
|
||||
/* Scroll button title */
|
||||
.scbt {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
@ -1,50 +0,0 @@
|
||||
body {
|
||||
background-color: #F4EBE8;
|
||||
font-family: Roboto Mono, monospace;
|
||||
font-size:20px;
|
||||
|
||||
}
|
||||
|
||||
#statbody {
|
||||
display: flex;
|
||||
margin: 120px;
|
||||
float: left
|
||||
}
|
||||
|
||||
.statcontainer {
|
||||
display: inline-block;
|
||||
width: 50%;
|
||||
min-height: 900px;
|
||||
padding: 20px;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
|
||||
.counter {
|
||||
display: flex;
|
||||
width: 100%
|
||||
}
|
||||
|
||||
.box {
|
||||
display: inline-block;
|
||||
width: 40%;
|
||||
text-align: center;
|
||||
padding: 20px;
|
||||
|
||||
}
|
||||
|
||||
.number {
|
||||
font-size: 72px;
|
||||
}
|
||||
|
||||
#graphs {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.image{
|
||||
display: inline-block;
|
||||
width: 100%;
|
||||
}
|
||||
#counter {
|
||||
display: inline-block;
|
||||
}
|
@ -1,196 +1,14 @@
|
||||
body{font-size: 12pt;}
|
||||
|
||||
div.part {border: 1px solid #e5e5e5;
|
||||
margin-bottom: 10px;
|
||||
margin-top: 10px;
|
||||
padding: 20px;}
|
||||
|
||||
body {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
background-color: #aaa4a0;
|
||||
}
|
||||
div#content img {width: 50%;}
|
||||
|
||||
/*div.row {display: inline; }
|
||||
div.column { display: inline; }
|
||||
div.column img{ width:24%; }*/
|
||||
|
||||
.grid-container {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
grid-gap: 10px;
|
||||
position: absolute;
|
||||
top: 60%;
|
||||
width: 96%;
|
||||
height: auto;
|
||||
left:2%;
|
||||
/*background-color: blue;*/
|
||||
text-align: : center;
|
||||
z-index: 5;
|
||||
div.metadata span.key {color: red;
|
||||
font-weight: bold;}
|
||||
|
||||
}
|
||||
|
||||
.grid-container > div {
|
||||
position: relative;
|
||||
/*background-color: green;*/
|
||||
text-align: center;
|
||||
/*padding-bottom: 1%;*/
|
||||
z-index: 5;
|
||||
}
|
||||
|
||||
img {
|
||||
position: relative;
|
||||
max-width: 100%;
|
||||
max-height: 100%;
|
||||
|
||||
/*align-content: center;*/
|
||||
|
||||
}
|
||||
|
||||
/*links*/
|
||||
|
||||
a:link {
|
||||
text-decoration: none;
|
||||
color: black;
|
||||
}
|
||||
|
||||
a:visited {
|
||||
text-decoration: none;
|
||||
color: blue;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
text-decoration: none;
|
||||
color: blue;
|
||||
}
|
||||
|
||||
h1 {
|
||||
position: fixed;
|
||||
right:0%;
|
||||
top:3%;
|
||||
text-align: right;
|
||||
background-color: grey;
|
||||
padding: 3px 30px 3px 10px;
|
||||
z-index: 10;
|
||||
color: black;
|
||||
font-size: 28px;
|
||||
}
|
||||
|
||||
h2{
|
||||
position: fixed;
|
||||
right: 0%;
|
||||
top: 15%;
|
||||
text-align: left;
|
||||
background-color: grey;
|
||||
color: black;
|
||||
padding: 3px 3px 3px 30px;
|
||||
z-index: 10;
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
.indexlist {
|
||||
position: absolute;
|
||||
top:20%;
|
||||
}
|
||||
|
||||
|
||||
/* Grid buttons */
|
||||
|
||||
.header {
|
||||
|
||||
position: absolute;
|
||||
text-align: center;
|
||||
padding: 32px;
|
||||
top: 30%;
|
||||
right: 0%;
|
||||
z-index: 9;
|
||||
width: auto;
|
||||
height: auto;
|
||||
}
|
||||
|
||||
p {
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.btn {
|
||||
border: none;
|
||||
outline: none;
|
||||
width: 110px;
|
||||
text-align: center;
|
||||
padding: 12px 0px;
|
||||
background-color: grey;
|
||||
cursor: pointer;
|
||||
font-size: 18px;
|
||||
margin-right: 5px;
|
||||
z-index: 9;
|
||||
}
|
||||
|
||||
.btn:hover {
|
||||
background-color: black;
|
||||
color: blue;
|
||||
}
|
||||
|
||||
.btn:active {
|
||||
background-color: black;
|
||||
color: white;
|
||||
}
|
||||
|
||||
|
||||
.metadata{
|
||||
position: fixed;
|
||||
top:5%;
|
||||
left:0%;
|
||||
background-color: ;
|
||||
width: 40%;
|
||||
z-index: 10;
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
.collapsible {
|
||||
background-color: #777;
|
||||
color: white;
|
||||
cursor: pointer;
|
||||
padding: 18px;
|
||||
width: 10%;
|
||||
height: auto;
|
||||
border: none;
|
||||
text-align: right;
|
||||
outline: none;
|
||||
font-size: 15px;
|
||||
z-index: 10;
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.active, .collapsible:hover {
|
||||
background-color: #555;
|
||||
}
|
||||
|
||||
.content {
|
||||
position: relative;
|
||||
padding: 0px 18px;
|
||||
max-height: 0;
|
||||
overflow: hidden;
|
||||
width: 90%;
|
||||
transition: max-height 0.2s ease-out;
|
||||
background-color: grey;
|
||||
color: white;
|
||||
z-index: 10;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.metadata_links {
|
||||
display: block;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
right: 0%;
|
||||
padding: 10px;
|
||||
text-align: left;
|
||||
/*background-color: blue;*/
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.metadata_organization {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
.fbtn {
|
||||
font-style: italic;
|
||||
}
|
||||
#orc {color:blue;}
|
@ -1,97 +0,0 @@
|
||||
body{
|
||||
width: max-content;
|
||||
background-color: #F4EBE8;
|
||||
}
|
||||
|
||||
.pagetitle {
|
||||
position: fixed;
|
||||
right:0%;
|
||||
top:5%;
|
||||
text-align: right;
|
||||
background-color: rgba(11,239,235,0.7);
|
||||
color: #371F10;
|
||||
padding: 3px 35px 3px 10px;
|
||||
z-index: 10;
|
||||
font-size: 28px;
|
||||
}
|
||||
|
||||
.eventdate {
|
||||
margin-top: 1%;
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-size: 17px;
|
||||
color: #371F10;
|
||||
background-color: #0BEFEB;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
div#body{ width: max-content;}
|
||||
|
||||
.mw-parser-output{
|
||||
/*! position: left top; */
|
||||
/*! display: hidden; */
|
||||
/*! display: inline; */
|
||||
/*! vertical-align: top; */
|
||||
}
|
||||
|
||||
.mw-parser-output > p{
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.content {
|
||||
display: flex;
|
||||
margin-right: 10vw;
|
||||
margin-left: 5vw;
|
||||
}
|
||||
|
||||
.indexlink {
|
||||
position: fixed;
|
||||
font-size: 20px;
|
||||
bottom: 0%;
|
||||
right: 3%;
|
||||
background-color: transparent;
|
||||
border: none;
|
||||
border-right-color: transparent;
|
||||
z-index: 10;
|
||||
padding: 0px 30px 20px 10px
|
||||
border: none;
|
||||
}
|
||||
|
||||
.indexlink a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.event {
|
||||
margin-top: 3%;
|
||||
text-align-last: auto;
|
||||
font-family: Roboto Mono;
|
||||
font-size: 10px;
|
||||
color: #371F10;
|
||||
padding-left: 5vw;
|
||||
display: inline-block;
|
||||
width:200px;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.eventfirstpages {
|
||||
padding-bottom: 5vh;
|
||||
}
|
||||
|
||||
.pubpageinfo {
|
||||
font-size: 15px;
|
||||
color: #371F10;
|
||||
}
|
||||
|
||||
.thumbborder {
|
||||
box-shadow: 10px 10px 15px #C4BCB9;
|
||||
width: 40%;
|
||||
height: auto;
|
||||
}
|
||||
|
||||
.thumbborder:hover {
|
||||
box-shadow: 10px 10px 15px #0BEFEB;
|
||||
width:100%;
|
||||
transition:0.5s;
|
||||
height: auto;
|
||||
}
|
@ -1,355 +0,0 @@
|
||||
body {
|
||||
background-color: #F4EBE8;
|
||||
font-family: Roboto Mono;
|
||||
}
|
||||
|
||||
.grid-container {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
grid-gap: 10px;
|
||||
position: absolute;
|
||||
top: 25%;
|
||||
width: 82%;
|
||||
height: auto;
|
||||
left: 7%;
|
||||
text-align: : center;
|
||||
z-index: 5;
|
||||
padding-bottom: 5%;
|
||||
|
||||
}
|
||||
|
||||
.grid-container > div {
|
||||
position: relative;
|
||||
text-align: center;
|
||||
z-index: 5;
|
||||
|
||||
}
|
||||
|
||||
.thumbborder {
|
||||
position: relative;
|
||||
max-width: 100%;
|
||||
max-height: 100%;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/*links*/
|
||||
|
||||
a:link {
|
||||
text-decoration: ;
|
||||
color: #371F10;
|
||||
}
|
||||
|
||||
a:visited {
|
||||
text-decoration: none;
|
||||
color: #371F10;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
text-decoration: none;
|
||||
color: blue;
|
||||
}
|
||||
|
||||
|
||||
h1 {
|
||||
/* position: fixed;
|
||||
right:0%;
|
||||
bottom:83%;
|
||||
text-align: right;
|
||||
background-color: rgba(11,239,235,0.7);
|
||||
padding: 3px 35px 3px 10px;
|
||||
z-index: 10;*/
|
||||
/* font-size: ;*/
|
||||
/* color: #371F10;
|
||||
max-width: 90%;*/
|
||||
}
|
||||
|
||||
h2{
|
||||
position: fixed;
|
||||
right: 0%;
|
||||
top: 15%;
|
||||
text-align: left;
|
||||
background-color: rgba(11,239,235,0.7);
|
||||
padding: 3px 35px 3px 10px;
|
||||
z-index: 10;
|
||||
font-size: 20px;
|
||||
color: #371F10;
|
||||
}
|
||||
|
||||
/*.viewnav {
|
||||
position: fixed;
|
||||
bottom: 1%;
|
||||
right: 1%;
|
||||
background-color: transparent;
|
||||
width: 5%;
|
||||
z-index: 9;
|
||||
}
|
||||
|
||||
.collapsible2 {
|
||||
background-color: transparent;
|
||||
color: #371F10;
|
||||
cursor: pointer;
|
||||
padding: 0px;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
border: none;
|
||||
text-align: center;
|
||||
outline: none;
|
||||
font-size: 40px;
|
||||
z-index: 10;
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
.collapsible2:hover {
|
||||
background-color: transparent;
|
||||
color: blue;
|
||||
}
|
||||
|
||||
.content2 {
|
||||
position: absolute;
|
||||
max-height: 0;
|
||||
overflow: hidden;
|
||||
width: auto;
|
||||
transition: max-height 0.3s ease-out;
|
||||
background-color: transparent;
|
||||
color: white;
|
||||
z-index: 10;
|
||||
text-align: center;
|
||||
bottom: 100%;
|
||||
}*/
|
||||
|
||||
|
||||
/* Grid buttons */
|
||||
|
||||
.header {
|
||||
|
||||
position: fixed;
|
||||
/* text-align: center;*/
|
||||
bottom: 0%;
|
||||
right: 1%;
|
||||
z-index: 9;
|
||||
width: 110px;
|
||||
height: 50px;
|
||||
background-color: white;
|
||||
color: #371F10;
|
||||
|
||||
}
|
||||
|
||||
p {
|
||||
display: inline-block;
|
||||
/*position: relative;*/
|
||||
color: #371F10;
|
||||
}
|
||||
|
||||
.btnov {
|
||||
position: fixed;
|
||||
display: inline;
|
||||
right: 20px;
|
||||
bottom:0px;
|
||||
border: none;
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
text-align: center;
|
||||
/* padding: 5px 5px;*/
|
||||
background-color: transparent;
|
||||
cursor: pointer;
|
||||
font-size: 20px;
|
||||
z-index: 9;
|
||||
color: #371F10;
|
||||
margin-bottom: 3px;
|
||||
}
|
||||
|
||||
.btn {
|
||||
position: fixed;
|
||||
display: inline;
|
||||
right: 70px;
|
||||
bottom:0px;
|
||||
border: none;
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
text-align: center;
|
||||
background-color: transparent;
|
||||
cursor: pointer;
|
||||
font-size: 30px;
|
||||
z-index: 9;
|
||||
color: #371F10;
|
||||
}
|
||||
|
||||
.btn:hover {
|
||||
color:rgba(11,239,235);
|
||||
/* color: blue;*/
|
||||
}
|
||||
|
||||
.btn:active {
|
||||
color:rgba(11,239,235);
|
||||
}
|
||||
|
||||
.btnov:hover {
|
||||
color:rgba(11,239,235);
|
||||
/* color: blue;*/
|
||||
}
|
||||
|
||||
.btnov:active {
|
||||
color:rgba(11,239,235);
|
||||
}
|
||||
|
||||
.metadata{
|
||||
position: fixed;
|
||||
top: 25%;
|
||||
right: 0%;
|
||||
background-color: transparent;
|
||||
width: 60%;
|
||||
z-index: 10;
|
||||
opacity: 1;
|
||||
text-align: right;
|
||||
/*align-items: right;
|
||||
align-content: right;*/
|
||||
|
||||
}
|
||||
|
||||
.collapsible {
|
||||
|
||||
display: inline-block;
|
||||
right:0%;
|
||||
background-color: white;
|
||||
color: #371F10;
|
||||
cursor: pointer;
|
||||
padding: 18px;
|
||||
width: 3%;
|
||||
height: 100%;
|
||||
/*border: solid 1px;*/
|
||||
text-align: left;
|
||||
outline: none;
|
||||
font-size: 15px;
|
||||
z-index: 10;
|
||||
margin-top: 10px;
|
||||
|
||||
}
|
||||
|
||||
.active, .collapsible:hover {
|
||||
color: #371F10;
|
||||
background-color:rgba(11,239,235);
|
||||
}
|
||||
|
||||
.content {
|
||||
position: relative;
|
||||
padding: 0px 18px;
|
||||
max-height: 0;
|
||||
overflow: hidden;
|
||||
width: auto;
|
||||
transition: max-height 0.2s ease-out;
|
||||
background-color: white;
|
||||
color: #371F10;
|
||||
z-index: 10;
|
||||
text-align: left;
|
||||
opacity: 0.7;
|
||||
right:0%;
|
||||
}
|
||||
|
||||
a.content:link {
|
||||
color:white;
|
||||
}
|
||||
|
||||
.metadata_topic, .metadata_format, .metadata_creator, .metadata_organization {
|
||||
max-width: 95%;
|
||||
}
|
||||
|
||||
.fbtn {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.smw-template-furtherresults {
|
||||
display: none;
|
||||
}
|
||||
/*
|
||||
.orglink {
|
||||
position: fixed;
|
||||
top: 30%;
|
||||
left: 0%;
|
||||
background-color: white;
|
||||
z-index: 10;
|
||||
font-size: 30px;
|
||||
padding: 0px 5px 0px 5px;
|
||||
}
|
||||
|
||||
.orglink .htext {
|
||||
visibility: hidden;
|
||||
width: 120px;
|
||||
background-color: black;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
border-radius: 6px;
|
||||
padding: 5px 0;
|
||||
font-size: 15px;
|
||||
|
||||
|
||||
position: absolute;
|
||||
left: 50px;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.orglink:hover .htext {
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
.timelinelink {
|
||||
position: fixed;
|
||||
top: 20%;
|
||||
left: 0%;
|
||||
background-color: white;
|
||||
z-index: 10;
|
||||
font-size: 30px;
|
||||
padding: 0px 5px 0px 5px;
|
||||
}
|
||||
|
||||
.timelinelink .htext {
|
||||
visibility: hidden;
|
||||
width: 120px;
|
||||
background-color: black;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
border-radius: 6px;
|
||||
padding: 5px 0;
|
||||
font-size: 15px;
|
||||
|
||||
|
||||
position: absolute;
|
||||
left: 50px;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.timelinelink:hover .htext {
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
.indexlink {
|
||||
position: fixed;
|
||||
top:10%;
|
||||
left:0%;
|
||||
background-color: white;
|
||||
z-index: 10;
|
||||
font-size: 30px;
|
||||
padding: 0px 5px 0px 5px;
|
||||
}
|
||||
|
||||
.indexlink .htext {
|
||||
visibility: hidden;
|
||||
width: 120px;
|
||||
background-color: black;
|
||||
color: #fff;
|
||||
text-align: center;
|
||||
border-radius: 6px;
|
||||
padding: 5px 0;
|
||||
font-size: 15px;
|
||||
|
||||
|
||||
position: absolute;
|
||||
left: 50px;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.indexlink:hover .htext {
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
*/
|
@ -1,9 +0,0 @@
|
||||
// image grid
|
||||
|
||||
function myFunction() {
|
||||
document.getElementById("myDIV").style.gridTemplateColumns = "100%";
|
||||
}
|
||||
|
||||
function myFunction2() {
|
||||
document.getElementById("myDIV").style.gridTemplateColumns = "repeat(4, 1fr)";
|
||||
}
|
@ -1,85 +0,0 @@
|
||||
body {
|
||||
background-color: #F4EBE8;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
/*.grid-container {
|
||||
display: inline-grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
grid-column-gap: 5px;
|
||||
grid-row-gap: 120px;
|
||||
grid-auto-flow: dense;
|
||||
position: relative;
|
||||
top: 60%;
|
||||
left: 5%;
|
||||
height: auto;
|
||||
margin-left: 120px;
|
||||
margin-right: 120px;
|
||||
text-align: center;
|
||||
z-index: 5;
|
||||
|
||||
}
|
||||
|
||||
.grid-container > div {
|
||||
position: relative;
|
||||
text-align: left;
|
||||
z-index: 5;
|
||||
}*/
|
||||
|
||||
.grid-container {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
grid-column-gap: 50px;
|
||||
grid-row-gap: 100px;
|
||||
/* grid-auto-flow: dense;*/
|
||||
position: absolute;
|
||||
top: 25%;
|
||||
width: 90%;
|
||||
height: auto;
|
||||
left: 5%;
|
||||
margin-left: 10px;
|
||||
margin-right: 10px;
|
||||
text-align: : center;
|
||||
z-index: 5;
|
||||
padding-bottom: 5%;
|
||||
|
||||
}
|
||||
|
||||
.grid-container > div {
|
||||
position: relative;
|
||||
text-align: center;
|
||||
z-index: 5;
|
||||
}
|
||||
|
||||
.thumbborder {
|
||||
max-height: 100%;
|
||||
position:relative;
|
||||
display: inline-block;
|
||||
max-width: 300px;
|
||||
}
|
||||
|
||||
|
||||
.img {
|
||||
display: inline-block;
|
||||
border-style: hidden hidden solid hidden;
|
||||
border-color: #0BEFEB;
|
||||
height: 500px;
|
||||
}
|
||||
|
||||
.title {
|
||||
display:block;
|
||||
}
|
||||
|
||||
.tooltiptext {
|
||||
display:block;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.metatext {
|
||||
display: inline-block;
|
||||
width: 300px;
|
||||
overflow-wrap: break-word;
|
||||
border-style: hidden;
|
||||
text-align: left;
|
||||
}
|
||||
|
@ -1,137 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<title>Liberation: Vol. 14 No. 4</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Liberation: Vol. 14 No. 4 ↵</h1>
|
||||
<h2>1986.6.1</h2>
|
||||
|
||||
<!-- Header -->
|
||||
<div class="header" id="myHeader">
|
||||
<button class="btn active" onclick="four()">Overview</button>
|
||||
<button class="btn" onclick="one()">100%</button>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- metadata dropdown -->
|
||||
|
||||
<div id="rightnav" class="rightnav">
|
||||
<a href="index.html" id="title">Title</a>
|
||||
<a href="#" id="view">View</a>
|
||||
</div>
|
||||
|
||||
<div id="leftnav" class="leftnav">
|
||||
<a href="#" id="date">Date</a>
|
||||
<a href="https://www.google.com/" id="creator">Creator</a>
|
||||
</div>
|
||||
|
||||
<div class="metadata_Creator"><a href>National Democratic Front (NDF)</a>
|
||||
</div>
|
||||
|
||||
<button class="orgbtn" onclick="myFunction()">Organizations</button>
|
||||
|
||||
<div class="square"></div>
|
||||
|
||||
<div id="myDIV">
|
||||
<ul><a href="index.html">New People's Army (NPA)</a></ul>, National Democratic Front (NDF), Armed Forces of the Philippines (AFP), International Monetary Fund (IMF), Katipunan ng mga Gurong Makabayan (KAGUMA), Philippine Conference for Human Rights (PCHR), World Bank (WB), Kilusang Mayo Uno - May First Movement (KMU), Kabataang Makabayan - Patriotic Youth (KM), National Press Club (NPC), Ministry of National Defense (MND), National Intelligence Security Authority (NISA), Federation of Free Farmers (FFF), Integrated National Police (INP), Military Security Unit (MSU), Communist Party of the Philippines (CPP), Civilian Home Defense Force (CHDF), Communist Party of the Philppines & New Peoples Army (CPP-NPA), Kilusan ng Magbubukid ng Pilipinas (KMP), Trade Union Congress of the Philippines (TUCP), Military Intelligence Service (MIS), Movement of Concerned Citizens for Civil Liberties (MCCCL), Executive Committee of the Central Committee (of the CPP) (EC-CC), National Economic Protectionism Association (NEPA), Pambansang Lakas ng Kilusang Mamamalakaya ng Pilipinas (PAMALAKAYA-Pilipinas), Reform the AFP Movement (RAM), Presidential Security Command (PSC), Metrocom Intelligence and Security Group (MISG), Civilian Armed Geographical Unit (CAFGU), Katipunan Dagiti Mannalon ti Isabela (KAMI-KMP)
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No401.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No405.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No409.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No413.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No418.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No422.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No426.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No402.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No406.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No410.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No414.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No419.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No423.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No427.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No403.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No407.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No411.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No415.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No420.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No424.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No428.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No404.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No408.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No412.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No416.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No421.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/LiberationVol14No425.jpg" style="width:100%">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// Get the elements with class="column"
|
||||
var elements = document.getElementsByClassName("column");
|
||||
|
||||
// Declare a loop variable
|
||||
var i;
|
||||
|
||||
// Four images side by side
|
||||
function four() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "25%"; // IE10
|
||||
elements[i].style.flex = "25%";
|
||||
}
|
||||
}
|
||||
|
||||
// Full-width images
|
||||
function one() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "80%"; // IE10
|
||||
elements[i].style.flex = "80%";
|
||||
}
|
||||
}
|
||||
|
||||
// // Two images side by side
|
||||
// function two() {
|
||||
// for (i = 0; i < elements.length; i++) {
|
||||
// elements[i].style.msFlex = "50%"; // IE10
|
||||
// elements[i].style.flex = "50%";
|
||||
// }
|
||||
// }
|
||||
|
||||
// Add active class to the current button (highlight it)
|
||||
var header = document.getElementById("myHeader");
|
||||
var btns = header.getElementsByClassName("btn");
|
||||
for (var i = 0; i < btns.length; i++) {
|
||||
btns[i].addEventListener("click", function() {
|
||||
var current = document.getElementsByClassName("active");
|
||||
current[0].className = current[0].className.replace(" active", "");
|
||||
this.className += " active";
|
||||
});
|
||||
}
|
||||
|
||||
// toggle text
|
||||
function myFunction() {
|
||||
var x = document.getElementById("myDIV");
|
||||
if (x.style.display === "block") {
|
||||
x.style.display = "none";
|
||||
} else {
|
||||
x.style.display = "block";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,122 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<title>Nineteen Eighty Sick: Year of the Lupus</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Nineteen Eighty Sick: Year of the Lupus ↵</h1>
|
||||
<h2>1986.1.1</h2>
|
||||
|
||||
<!-- Header -->
|
||||
<div class="header" id="myHeader">
|
||||
<button class="btn active" onclick="four()">Overview</button>
|
||||
<button class="btn" onclick="one()">100%</button>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- metadata dropdown -->
|
||||
|
||||
<div id="rightnav" class="rightnav">
|
||||
<a href="index.html" id="title">Title</a>
|
||||
<a href="#" id="view">View</a>
|
||||
</div>
|
||||
|
||||
<div id="leftnav" class="leftnav">
|
||||
<a href="#" id="date">Date</a>
|
||||
<a href="https://www.google.com/" id="creator">Creator</a>
|
||||
</div>
|
||||
|
||||
<div class="metadata_Creator"><a href>Manuel Pamaran, Paki A. Lamero</a>
|
||||
</div>
|
||||
|
||||
<button class="orgbtn" onclick="myFunction()">Organizations</button>
|
||||
|
||||
<div class="square"></div>
|
||||
<div id="myDIV">
|
||||
<ul><a href="index.html">Kabataang Makabayan - Patriotic Youth (KM)</a></ul>
|
||||
<ul><a href="index.html">Civilian Home Defense Force (CHDF)</a></ul>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus01.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus05.jpg" style="width:100%">
|
||||
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus02.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus06.jpg" style="width:100%">
|
||||
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus03.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus07.jpg" style="width:100%">
|
||||
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus04.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/NineteenEightySickYearofLupus08.jpg" style="width:100%">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// Get the elements with class="column"
|
||||
var elements = document.getElementsByClassName("column");
|
||||
|
||||
// Declare a loop variable
|
||||
var i;
|
||||
|
||||
// Four images side by side
|
||||
function four() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "25%"; // IE10
|
||||
elements[i].style.flex = "25%";
|
||||
}
|
||||
}
|
||||
|
||||
// Full-width images
|
||||
function one() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "80%"; // IE10
|
||||
elements[i].style.flex = "80%";
|
||||
}
|
||||
}
|
||||
|
||||
// // Two images side by side
|
||||
// function two() {
|
||||
// for (i = 0; i < elements.length; i++) {
|
||||
// elements[i].style.msFlex = "50%"; // IE10
|
||||
// elements[i].style.flex = "50%";
|
||||
// }
|
||||
// }
|
||||
|
||||
// Add active class to the current button (highlight it)
|
||||
var header = document.getElementById("myHeader");
|
||||
var btns = header.getElementsByClassName("btn");
|
||||
for (var i = 0; i < btns.length; i++) {
|
||||
btns[i].addEventListener("click", function() {
|
||||
var current = document.getElementsByClassName("active");
|
||||
current[0].className = current[0].className.replace(" active", "");
|
||||
this.className += " active";
|
||||
});
|
||||
}
|
||||
|
||||
// toggle text
|
||||
function myFunction() {
|
||||
var x = document.getElementById("myDIV");
|
||||
if (x.style.display === "block") {
|
||||
x.style.display = "none";
|
||||
} else {
|
||||
x.style.display = "block";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,110 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<title>Free all political prisoners: our solidarity will set them free</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Free all political prisoners: our solidarity will set them free ↵</h1>
|
||||
<h2>1984.12.4</h2>
|
||||
|
||||
<!-- Header -->
|
||||
<div class="header" id="myHeader">
|
||||
<button class="btn active" onclick="four()">Overview</button>
|
||||
<button class="btn" onclick="one()">100%</button>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- metadata dropdown -->
|
||||
|
||||
<div id="rightnav" class="rightnav">
|
||||
<a href="index.html" id="title">Title</a>
|
||||
<a href="#" id="view">View</a>
|
||||
</div>
|
||||
|
||||
<div id="leftnav" class="leftnav">
|
||||
<a href="#" id="date">Date</a>
|
||||
<a href="https://www.google.com/" id="creator">Creator</a>
|
||||
</div>
|
||||
|
||||
|
||||
<button class="orgbtn" onclick="myFunction()">Organizations</button>
|
||||
|
||||
<div class="square"></div>
|
||||
|
||||
<div id="myDIV">
|
||||
<ul><a href="index.html">Task Force Detainees of the Philippines (TFDP)</a></ul>, Nationalist Alliance for Justice, Freedom and Democracy (NAJFD), Kapisanan para sa Pagpapalaya at Amnestiya ng mga Detenido sa Pilipinas - Association for the Release and Amnesty of Detainees in the Philippines (KAPATID)
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/VF269Freeallpoliticalprisoners01.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/VF269Freeallpoliticalprisoners02.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
</div>
|
||||
<div class="column">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// Get the elements with class="column"
|
||||
var elements = document.getElementsByClassName("column");
|
||||
|
||||
// Declare a loop variable
|
||||
var i;
|
||||
|
||||
// Four images side by side
|
||||
function four() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "25%"; // IE10
|
||||
elements[i].style.flex = "25%";
|
||||
}
|
||||
}
|
||||
|
||||
// Full-width images
|
||||
function one() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "80%"; // IE10
|
||||
elements[i].style.flex = "80%";
|
||||
}
|
||||
}
|
||||
|
||||
// // Two images side by side
|
||||
// function two() {
|
||||
// for (i = 0; i < elements.length; i++) {
|
||||
// elements[i].style.msFlex = "50%"; // IE10
|
||||
// elements[i].style.flex = "50%";
|
||||
// }
|
||||
// }
|
||||
|
||||
// Add active class to the current button (highlight it)
|
||||
var header = document.getElementById("myHeader");
|
||||
var btns = header.getElementsByClassName("btn");
|
||||
for (var i = 0; i < btns.length; i++) {
|
||||
btns[i].addEventListener("click", function() {
|
||||
var current = document.getElementsByClassName("active");
|
||||
current[0].className = current[0].className.replace(" active", "");
|
||||
this.className += " active";
|
||||
});
|
||||
}
|
||||
|
||||
// toggle text
|
||||
function myFunction() {
|
||||
var x = document.getElementById("myDIV");
|
||||
if (x.style.display === "block") {
|
||||
x.style.display = "none";
|
||||
} else {
|
||||
x.style.display = "block";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,113 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<title>Hamok: Isulong Ang Pambansang Demokratikong Rebolusyon</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Hamok: Isulong Ang Pambansang Demokratikong Rebolusyon ↵</h1>
|
||||
<h2>1977.6.12</h2>
|
||||
|
||||
<!-- Header -->
|
||||
<div class="header" id="myHeader">
|
||||
<button class="btn active" onclick="four()">Overview</button>
|
||||
<button class="btn" onclick="one()">100%</button>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- metadata dropdown -->
|
||||
|
||||
<div id="rightnav" class="rightnav">
|
||||
<a href="index.html" id="title">Title</a>
|
||||
<a href="#" id="view">View</a>
|
||||
</div>
|
||||
|
||||
<div id="leftnav" class="leftnav">
|
||||
<a href="#" id="date">Date</a>
|
||||
<a href="https://www.google.com/" id="creator">Creator</a>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<button class="orgbtn" onclick="myFunction()">Organizations</button>
|
||||
|
||||
<div class="square"></div>
|
||||
|
||||
<div id="myDIV">
|
||||
<ul><a href="index.html">All Organizations</a></ul>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/VF383Hamok00.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/VF383Hamok01.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/VF383Hamok02.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/VF383Hamok03.jpg" style="width:100%">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// Get the elements with class="column"
|
||||
var elements = document.getElementsByClassName("column");
|
||||
|
||||
// Declare a loop variable
|
||||
var i;
|
||||
|
||||
// Four images side by side
|
||||
function four() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "25%"; // IE10
|
||||
elements[i].style.flex = "25%";
|
||||
}
|
||||
}
|
||||
|
||||
// Full-width images
|
||||
function one() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "80%"; // IE10
|
||||
elements[i].style.flex = "80%";
|
||||
}
|
||||
}
|
||||
|
||||
// // Two images side by side
|
||||
// function two() {
|
||||
// for (i = 0; i < elements.length; i++) {
|
||||
// elements[i].style.msFlex = "50%"; // IE10
|
||||
// elements[i].style.flex = "50%";
|
||||
// }
|
||||
// }
|
||||
|
||||
// Add active class to the current button (highlight it)
|
||||
var header = document.getElementById("myHeader");
|
||||
var btns = header.getElementsByClassName("btn");
|
||||
for (var i = 0; i < btns.length; i++) {
|
||||
btns[i].addEventListener("click", function() {
|
||||
var current = document.getElementsByClassName("active");
|
||||
current[0].className = current[0].className.replace(" active", "");
|
||||
this.className += " active";
|
||||
});
|
||||
}
|
||||
|
||||
// toggle text
|
||||
function myFunction() {
|
||||
var x = document.getElementById("myDIV");
|
||||
if (x.style.display === "block") {
|
||||
x.style.display = "none";
|
||||
} else {
|
||||
x.style.display = "block";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,127 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<title>Martsa ng Bayan</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Martsa ng Bayan ↵</h1>
|
||||
<h2>1974.1.7</h2>
|
||||
|
||||
<!-- Header -->
|
||||
<div class="header" id="myHeader">
|
||||
<button class="btn active" onclick="four()">Overview</button>
|
||||
<button class="btn" onclick="one()">100%</button>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- metadata dropdown -->
|
||||
|
||||
<div id="rightnav" class="rightnav">
|
||||
<a href="index.html" id="title">Title</a>
|
||||
<a href="#" id="view">View</a>
|
||||
</div>
|
||||
|
||||
<div id="leftnav" class="leftnav">
|
||||
<a href="#" id="date">Date</a>
|
||||
<a href="https://www.google.com/" id="creator">Creator</a>
|
||||
</div>
|
||||
|
||||
<div class="metadata_Creator"><a href>Philippine Conference for Human Rights (PCHR)</a>
|
||||
</div>
|
||||
|
||||
<button class="orgbtn" onclick="myFunction()">Organizations</button>
|
||||
|
||||
<div class="square"></div>
|
||||
|
||||
<div id="myDIV">
|
||||
<ul><a href="index.html">All Organizations</a></ul>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197401.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197405.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197409.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197413.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197417.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197402.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197406.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197410.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197414.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197403.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197407.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197411.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197415.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197404.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197408.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197412.jpg" style="width:100%">
|
||||
<img src="/Users/sandra/Desktop/XPUB/GIT/special-issue-11-wiki2html/images/MartsangBayanJanuary7197416.jpg" style="width:100%">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
// Get the elements with class="column"
|
||||
var elements = document.getElementsByClassName("column");
|
||||
|
||||
// Declare a loop variable
|
||||
var i;
|
||||
|
||||
// Four images side by side
|
||||
function four() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "25%"; // IE10
|
||||
elements[i].style.flex = "25%";
|
||||
}
|
||||
}
|
||||
|
||||
// Full-width images
|
||||
function one() {
|
||||
for (i = 0; i < elements.length; i++) {
|
||||
elements[i].style.msFlex = "80%"; // IE10
|
||||
elements[i].style.flex = "80%";
|
||||
}
|
||||
}
|
||||
|
||||
// // Two images side by side
|
||||
// function two() {
|
||||
// for (i = 0; i < elements.length; i++) {
|
||||
// elements[i].style.msFlex = "50%"; // IE10
|
||||
// elements[i].style.flex = "50%";
|
||||
// }
|
||||
// }
|
||||
|
||||
// Add active class to the current button (highlight it)
|
||||
var header = document.getElementById("myHeader");
|
||||
var btns = header.getElementsByClassName("btn");
|
||||
for (var i = 0; i < btns.length; i++) {
|
||||
btns[i].addEventListener("click", function() {
|
||||
var current = document.getElementsByClassName("active");
|
||||
current[0].className = current[0].className.replace(" active", "");
|
||||
this.className += " active";
|
||||
});
|
||||
}
|
||||
|
||||
// toggle text
|
||||
function myFunction() {
|
||||
var x = document.getElementById("myDIV");
|
||||
if (x.style.display === "block") {
|
||||
x.style.display = "none";
|
||||
} else {
|
||||
x.style.display = "block";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,39 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<title></title>
|
||||
</head>
|
||||
<body>
|
||||
<h3>Results from query:<br/><code>[[Format::Song]]</code></h3>
|
||||
<ul class="indexlist">
|
||||
|
||||
<li><a href="./MartsangBayan.html">Martsa ng Bayan</a>
|
||||
1974.1.7
|
||||
Philippine Conference for Human Rights (PCHR)
|
||||
</li>
|
||||
|
||||
<li><a href="./HamokIsulongAngPambansangDemokratikongRebolusyon.html">Hamok: Isulong Ang Pambansang Demokratikong Rebolusyon</a>
|
||||
1977.6.12
|
||||
|
||||
</li>
|
||||
|
||||
<li><a href="./Freeallpoliticalprisonersoursolidaritywillsetthemfree.html">Free all political prisoners: our solidarity will set them free</a>
|
||||
1984.12.4
|
||||
|
||||
</li>
|
||||
|
||||
<li><a href="./2NineteenEightySickYearoftheLupus.html">Nineteen Eighty Sick: Year of the Lupus</a>
|
||||
1986.1.1
|
||||
Manuel Pamaran, Paki A. Lamero
|
||||
</li>
|
||||
|
||||
<li><a href="./1LiberationVol14No. 4.html">Liberation: Vol. 14 No. 4</a>
|
||||
1986.6.1
|
||||
National Democratic Front (NDF)
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
@ -1,337 +0,0 @@
|
||||
|
||||
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
background-color: #aaa4a0;
|
||||
}
|
||||
|
||||
/*index page links*/
|
||||
|
||||
li a:hover {
|
||||
text-decoration: none;
|
||||
color: blue;
|
||||
}
|
||||
|
||||
a:link {
|
||||
text-decoration: none;
|
||||
color: black;
|
||||
}
|
||||
|
||||
a:visited {
|
||||
text-decoration: none;
|
||||
color: black;
|
||||
}
|
||||
|
||||
h1 {
|
||||
position: fixed;
|
||||
/*height: 50px;
|
||||
width: auto;*/
|
||||
right:0%;
|
||||
text-align: right;
|
||||
background-color: grey;
|
||||
padding: 3px 30px 3px 10px;
|
||||
}
|
||||
|
||||
h2, h3{
|
||||
position: fixed;
|
||||
left: 0%;
|
||||
top: 5%;
|
||||
text-align: left;
|
||||
background-color: grey;
|
||||
padding: 3px 3px 3px 30px;
|
||||
}
|
||||
|
||||
.indexlist {
|
||||
position: absolute;
|
||||
top:20%;
|
||||
}
|
||||
|
||||
|
||||
.header {
|
||||
/*display: inline-block;*/
|
||||
position: absolute;
|
||||
text-align: center;
|
||||
padding: 32px;
|
||||
top: 15%;
|
||||
right: 0%;
|
||||
z-index: -1;
|
||||
}
|
||||
|
||||
.row {
|
||||
display: -ms-flexbox; /* IE 10 */
|
||||
display: flex;
|
||||
position: absolute;
|
||||
-ms-flex-wrap: wrap; /* IE 10 */
|
||||
flex-wrap: wrap;
|
||||
padding: 0 4px;
|
||||
top: 35%;
|
||||
z-index: -1;
|
||||
|
||||
}
|
||||
|
||||
/* Create two equal columns that sits next to each other */
|
||||
.column {
|
||||
-ms-flex: 25%; /* IE 10 */
|
||||
flex: 25%;
|
||||
padding: 0 4px;
|
||||
}
|
||||
|
||||
.column img {
|
||||
margin-top: 8px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
/* Style the buttons */
|
||||
.btn {
|
||||
position: relative;
|
||||
border: none;
|
||||
outline: none;
|
||||
width: 110px;
|
||||
text-align: center;
|
||||
padding: 12px 0px;
|
||||
background-color: grey;
|
||||
cursor: pointer;
|
||||
font-size: 18px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
.btn:hover {
|
||||
background-color: black;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.active {
|
||||
background-color: black;
|
||||
color: white;
|
||||
}
|
||||
|
||||
/*metadata dropup*/
|
||||
|
||||
.dropbtn {
|
||||
background-color: black;
|
||||
color: white;
|
||||
padding: 16px;
|
||||
font-size: 16px;
|
||||
border: none;
|
||||
width: 200px;
|
||||
|
||||
}
|
||||
|
||||
.dropup {
|
||||
position: absolute;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.dropup-content {
|
||||
display: none;
|
||||
position: absolute;
|
||||
background-color: black;
|
||||
opacity: 0.8;
|
||||
min-width: 160px;
|
||||
bottom: 50px;
|
||||
z-index: 1;
|
||||
width: 300px;
|
||||
color: grey;
|
||||
}
|
||||
|
||||
.dropup-content a {
|
||||
color: grey;
|
||||
padding: 12px 16px;
|
||||
text-decoration: none;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.dropup-content a:hover {color: white;}
|
||||
|
||||
.dropup:hover .dropup-content {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.dropup:hover .dropbtn {
|
||||
background-color: grey;
|
||||
}
|
||||
|
||||
/*metadata dropdown*/
|
||||
.dropbtn {
|
||||
position: fixed;
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
padding: 16px;
|
||||
font-size: 16px;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
bottom:30%;
|
||||
}
|
||||
|
||||
.dropdown {
|
||||
position: fixed;
|
||||
display: inline-block;
|
||||
bottom:30%;
|
||||
width: 300px;
|
||||
}
|
||||
|
||||
.dropdown-content {
|
||||
display: none;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
background-color: #f9f9f9;
|
||||
min-width: 160px;
|
||||
box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.dropdown-content a {
|
||||
color: black;
|
||||
padding: 12px 16px;
|
||||
text-decoration: none;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.dropdown-content a:hover {background-color: #f1f1f1;}
|
||||
.dropdown:hover .dropdown-content {display: block;}
|
||||
.dropdown:hover .dropbtn {background-color: #3e8e41;}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*something*/
|
||||
|
||||
|
||||
#rightnav a {
|
||||
position: absolute;
|
||||
right: -90px;
|
||||
/*top:10%;*/
|
||||
transition: 0.3s;
|
||||
padding: 10px 50px 10px 30px;
|
||||
width: 150px;
|
||||
text-decoration: none;
|
||||
font-size: 20px;
|
||||
color: white;
|
||||
border-radius: 0 5px 5px 0;
|
||||
text-align: right;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
#rightnav a:hover {
|
||||
right: 0;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
#title {
|
||||
top: 10%;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
#view {
|
||||
top: 27%;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
#leftnav a {
|
||||
position: absolute;
|
||||
left: -80px;
|
||||
/*top:10%;*/
|
||||
transition: 0.3s;
|
||||
padding: 10px 50px 10px 20px;
|
||||
width: 125px;
|
||||
text-decoration: none;
|
||||
font-size: 20px;
|
||||
color: white;
|
||||
border-radius: 5px 0 0 5px;
|
||||
text-align: right;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
#leftnav a:hover {
|
||||
left: 0;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
#date {
|
||||
top: 14%;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
#creator {
|
||||
top: 25%;
|
||||
background-color: black;
|
||||
}
|
||||
|
||||
.metadata_Creator{
|
||||
position: absolute;
|
||||
top:20%;
|
||||
font-size: 18px;
|
||||
background-color: grey;
|
||||
padding: 3px 5px 3px 30px;
|
||||
color: black;
|
||||
}
|
||||
|
||||
.metadata_Creator a:hover{
|
||||
color: blue;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#myDIV {
|
||||
display: none;
|
||||
position: absolute;
|
||||
width: 48%;
|
||||
height: auto;
|
||||
left:26%;
|
||||
top:15%;
|
||||
/*padding: 50px 0;*/
|
||||
text-align: center;
|
||||
background-color: grey;
|
||||
margin-top: 20px;
|
||||
z-index: 4;
|
||||
opacity:0.8;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
#myDIV a:hover{
|
||||
color: blue;
|
||||
}
|
||||
|
||||
|
||||
.orgbtn {
|
||||
position: relative;
|
||||
border: none;
|
||||
outline: none;
|
||||
width: 15%;
|
||||
left:11%;
|
||||
text-align: center;
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
background-color: grey;
|
||||
color: grey;
|
||||
cursor: pointer;
|
||||
font-size: 18px;
|
||||
/*margin-right: 5px;*/
|
||||
}
|
||||
|
||||
.orgbtn:hover {
|
||||
background-color: black;
|
||||
color:white;
|
||||
}
|
||||
|
||||
|
||||
.square {
|
||||
display: block;
|
||||
position: absolute;
|
||||
width: 50%;
|
||||
height: 80%;
|
||||
left:25%;
|
||||
top:11%;
|
||||
text-align: center;
|
||||
background-color: transparent;
|
||||
z-index: 2;
|
||||
border-color: black;
|
||||
border: solid 5px;
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/about.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body>
|
||||
{{ body|safe }}
|
||||
</body>
|
||||
</html>
|
@ -1,15 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>{{ page.name }}</h1>
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,91 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="../static/style.css" />
|
||||
<script type="text/javascript" src="../static/script.js"></script>
|
||||
<title>{{ title[0] }}</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>{{ title[0] }}</h1>
|
||||
<h2><time datetime="{{date}}">{{ date.year }}.{{ date.month }}.{{ date.day }}</time></h2>
|
||||
|
||||
<div id="ExpCol">
|
||||
<h3>Metadata</h3>
|
||||
</div>
|
||||
<div id="content">
|
||||
<!-- metadata creator / format / topic -->
|
||||
|
||||
<a class="metadata_links" href="allcreators.html" id="creatornav">Creator</a>
|
||||
<div class="metadata_creator">{{ creator }}</div>
|
||||
|
||||
<a class="metadata_links" href="allformats.html" id="formatnav">Format</a>
|
||||
<div class="metadata_format">{{ format }}</div>
|
||||
|
||||
<a class="metadata_links" href="alltopics.html" id="topicnav">Topic</a>
|
||||
<div class="metadata_topic">{{topic}}</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- nav -->
|
||||
|
||||
<div id="rightnav" class="rightnav">
|
||||
<a href="index.html" id="titlenav">Title</a>
|
||||
</div>
|
||||
|
||||
<div id="leftnav" class="leftnav">
|
||||
<a href="timeline.html" id="datenav">Date</a>
|
||||
</div>
|
||||
|
||||
<!-- organizations toogle -->
|
||||
|
||||
<button class="orgbtn" onclick="orgFunc()">Organizations</button>
|
||||
|
||||
<div class="metadata_organizations" id="org">
|
||||
<ul>{{ organization }}</ul>
|
||||
</div>
|
||||
|
||||
<!-- square -->
|
||||
|
||||
<div class="square"></div>
|
||||
|
||||
<!-- 2 btn grid switch for images -->
|
||||
|
||||
<div class="header" id="myHeader">
|
||||
<p><button class="btn" onclick="myFunction()">100%</button></p>
|
||||
<p><button class="btn" onclick="myFunction2()">overview</button></p>
|
||||
</div>
|
||||
|
||||
<!-- images -->
|
||||
|
||||
{% for row in imgsmatrix %}
|
||||
<div class="grid-container" id="myDIV">
|
||||
{% for img in row %}
|
||||
<div class="column">
|
||||
<img src="{{ img }}">
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
{#
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok00.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok01.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok02.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok03.jpg" style="width:100%">
|
||||
</div>
|
||||
</div>
|
||||
#}
|
@ -1,84 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="../static/style.css" />
|
||||
<script type="text/javascript" src="../static/script.js"></script>
|
||||
<title>{{ title[0] }}</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>{{ title[0] }}</h1>
|
||||
<h2><time datetime="{{date}}">{{ date.year }}.{{ date.month }}.{{ date.day }}</time></h2>
|
||||
|
||||
<!-- metadata creator / format / topic -->
|
||||
|
||||
<div class="metadata_creator">{{ creator }}</div>
|
||||
|
||||
<div class="metadata_format">{{ format }}</div>
|
||||
|
||||
<div class="metadata_topic">{{topic}}</div>
|
||||
|
||||
|
||||
<!-- nav -->
|
||||
|
||||
<div id="rightnav" class="rightnav">
|
||||
<a href="index.html" id="titlenav">Title</a>
|
||||
</div>
|
||||
|
||||
<div id="leftnav" class="leftnav">
|
||||
<a href="timeline.html" id="datenav">Date</a>
|
||||
<a href="allcreators.html" id="creatornav">Creator</a>
|
||||
<a href="allformats.html" id="formatnav">Format</a>
|
||||
<a href="alltopics.html" id="topicnav">Topic</a>
|
||||
</div>
|
||||
|
||||
<!-- organizations toogle -->
|
||||
|
||||
<button class="orgbtn" onclick="orgFunc()">Organizations</button>
|
||||
|
||||
<div class="metadata_organizations" id="org">
|
||||
<ul>{{ organization|list }}</ul>
|
||||
</div>
|
||||
|
||||
<!-- square -->
|
||||
|
||||
<div class="square"></div>
|
||||
|
||||
<!-- 2 btn grid switch for images -->
|
||||
|
||||
<div class="header" id="myHeader">
|
||||
<p><button class="btn" onclick="myFunction()">100%</button></p>
|
||||
<p><button class="btn" onclick="myFunction2()">overview</button></p>
|
||||
</div>
|
||||
|
||||
<!-- images -->
|
||||
|
||||
{% for row in imgsmatrix %}
|
||||
<div class="grid-container" id="myDIV">
|
||||
{% for img in row %}
|
||||
<div class="column">
|
||||
<img src="{{ img }}">
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
{#
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok00.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok01.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok02.jpg" style="width:100%">
|
||||
</div>
|
||||
<div class="column">
|
||||
<img src="./images/VF383Hamok03.jpg" style="width:100%">
|
||||
</div>
|
||||
</div>
|
||||
#}
|
@ -0,0 +1,29 @@
|
||||
<div class="part">
|
||||
|
||||
<div class="img">
|
||||
<img src="{{ imgsrc }}" />
|
||||
<a href="https:{{ fullurl }}">{{ fullurl }}</a>
|
||||
</div>
|
||||
|
||||
<div class="text">
|
||||
{{ text | safe }}
|
||||
</div>
|
||||
|
||||
<div class="metadata">
|
||||
<h3>Metadata</h3>
|
||||
{% for key, value in printout_dict.items() %}
|
||||
{% if key == 'Date' %}
|
||||
<div class="metadata_{{key}}">
|
||||
<span class="key">{{key}}</span>
|
||||
<span class="value">{{value.year}} {{value.month}} {{value.day}}</span>
|
||||
</div>
|
||||
{% else %}
|
||||
<div class="metadata_{{key}}">
|
||||
<span class="key">{{key|upper}}</span>
|
||||
<span class="value">{{value}}</span>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
</div>
|
@ -1,17 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/topicformat.css" />
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body class="title">
|
||||
|
||||
<h1>{{ page.name }}</h1>
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,116 +1,18 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css"/>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/index.css"/>`
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<!-- <script type="text/javascript" src="{{ staticpath }}/static/index.js"></script> -->
|
||||
<title>{{ page.name }}</title>
|
||||
<meta charset="UTF-8">
|
||||
<title>{{title}}</title>
|
||||
</head>
|
||||
<body>
|
||||
<!-- <div class="pagelink">[[Overview_main_page|↱]]<span class="pagename">Main Page</span></div>
|
||||
<div class="pagelink">[[Dates_of_Events|┉]]<span class="pagename">Timeline</span></div>
|
||||
<div class="pagelink">[[Organizations|▤]]<span class="pagename">Organizations</span></div> -->
|
||||
<div class="bigbtncontainer">
|
||||
<div id="myBtnContainer">
|
||||
<button class="btn active" onclick="filterSelection('All')">All Publications</button>
|
||||
<button class="btn" onclick="filterSelection('Arts and Culture')">Arts and Culture</button>
|
||||
<button class="btn" onclick="filterSelection('Civil Rights')">Civil Rights</button>
|
||||
<button class="btn" onclick="filterSelection('Clergy / Religion')">Clergy / Religion</button>
|
||||
<button class="btn" onclick="filterSelection('Economics')">Economics</button>
|
||||
<button class="btn" onclick="filterSelection('Education')">Education</button>
|
||||
<button class="btn" onclick="filterSelection('Elections')">Elections</button>
|
||||
<button class="btn" onclick="filterSelection('Food Production / Nutrition / Food')">Food Production / Nutrition / Food</button>
|
||||
<button class="btn" onclick="filterSelection('Healthcare')">Healthcare</button>
|
||||
<button class="btn" onclick="filterSelection('Imprisonment')">Imprisonment</button>
|
||||
<button class="btn" onclick="filterSelection('Infrastructure')">Infrastructure</button>
|
||||
<button class="btn" onclick="filterSelection('Internal Affairs')">Internal Affairs</button>
|
||||
<button class="btn" onclick="filterSelection('International Affairs')">International Affairs</button>
|
||||
<button class="btn" onclick="filterSelection('Key Political Figures')">Key Political Figures</button>
|
||||
<button class="btn" onclick="filterSelection('Martial Law')">Martial Law</button>
|
||||
<button class="btn" onclick="filterSelection('Military Abuse')">Military Abuse</button>
|
||||
<button class="btn" onclick="filterSelection('Military Resources')">Military Resources</button>
|
||||
<button class="btn" onclick="filterSelection('Natural Phenomena')">Natural Phenomena</button>
|
||||
<button class="btn" onclick="filterSelection('Political Ideologies')">Political Ideologies</button>
|
||||
<button class="btn" onclick="filterSelection('Resistance Tactics')">Resistance Tactics</button>
|
||||
<button class="btn" onclick="filterSelection('Social Policies')">Social Policies</button>
|
||||
<button class="btn" onclick="filterSelection('US Foreign Policy')">US Foreign Policy</button>
|
||||
<button class="btn" onclick="filterSelection('Workers Rights')">Workers Rights</button>
|
||||
<div class="line"></div>
|
||||
<button class="btn" onclick="filterSelection('Agenda')">Agenda</button>
|
||||
<button class="btn" onclick="filterSelection('Article')">Article</button>
|
||||
<button class="btn" onclick="filterSelection('Bulletin')">Bulletin</button>
|
||||
<button class="btn" onclick="filterSelection('Comic')">Comic</button>
|
||||
<button class="btn" onclick="filterSelection('Editorial')">Editorial</button>
|
||||
<button class="btn" onclick="filterSelection('Handbook')">Handbook</button>
|
||||
<button class="btn" onclick="filterSelection('Interview')">Interview</button>
|
||||
<button class="btn" onclick="filterSelection('Invitation')">Invitation</button>
|
||||
<button class="btn" onclick="filterSelection('Legal Document')">Legal Document</button>
|
||||
<button class="btn" onclick="filterSelection('Letter')">Letter</button>
|
||||
<button class="btn" onclick="filterSelection('List')">List</button>
|
||||
<button class="btn" onclick="filterSelection('Manifesto')">Manifesto</button>
|
||||
<button class="btn" onclick="filterSelection('Manual')">Manual</button>
|
||||
<button class="btn" onclick="filterSelection('News')">News</button>
|
||||
<button class="btn" onclick="filterSelection('Notes')">Notes</button>
|
||||
<button class="btn" onclick="filterSelection('Pamphlet')">Pamphlet</button>
|
||||
<button class="btn" onclick="filterSelection('Paper')">Paper</button>
|
||||
<button class="btn" onclick="filterSelection('Poem')">Poem</button>
|
||||
<button class="btn" onclick="filterSelection('Reader')">Reader</button>
|
||||
<button class="btn" onclick="filterSelection('Report')">Report</button>
|
||||
<button class="btn" onclick="filterSelection('Song')">Song</button>
|
||||
<button class="btn" onclick="filterSelection('Statement')">Statement</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <ul id="menu"> -->
|
||||
{{ body|safe }}
|
||||
<!-- </ul> -->
|
||||
|
||||
<h3>Results from query:<br/><code>{{query}}</code></h3>
|
||||
<ul>
|
||||
{% for doc in documentslist %}
|
||||
<li><a href="./{{ doc['file'] }}">{{ doc['title'] }}</a>
|
||||
{{ doc['date'].year }}.{{ doc['date'].month }}.{{ doc['date'].day }}
|
||||
{{doc['creator']}}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
<script>
|
||||
filterSelection("All")
|
||||
function filterSelection(c) {
|
||||
var x, i;
|
||||
x = document.getElementsByClassName("filter");
|
||||
if (c == "All") c = "";
|
||||
for (i = 0; i < x.length; i++) {
|
||||
w3RemoveClass(x[i], "show");
|
||||
if (x[i].className.indexOf(c) > -1) w3AddClass(x[i], "show");
|
||||
}
|
||||
}
|
||||
|
||||
function w3AddClass(element, name) {
|
||||
var i, arr1, arr2;
|
||||
arr1 = element.className.split(" ");
|
||||
arr2 = name.split(" ");
|
||||
for (i = 0; i < arr2.length; i++) {
|
||||
if (arr1.indexOf(arr2[i]) == -1) {element.className += " " + arr2[i];}
|
||||
}
|
||||
}
|
||||
|
||||
function w3RemoveClass(element, name) {
|
||||
var i, arr1, arr2;
|
||||
arr1 = element.className.split(" ");
|
||||
arr2 = name.split(" ");
|
||||
for (i = 0; i < arr2.length; i++) {
|
||||
while (arr1.indexOf(arr2[i]) > -1) {
|
||||
arr1.splice(arr1.indexOf(arr2[i]), 1);
|
||||
}
|
||||
}
|
||||
element.className = arr1.join(" ");
|
||||
}
|
||||
|
||||
// Add active class to the current button (highlight it)
|
||||
var btnContainer = document.getElementById("myBtnContainer");
|
||||
var btns = btnContainer.getElementsByClassName("btn");
|
||||
for (var i = 0; i < btns.length; i++) {
|
||||
btns[i].addEventListener("click", function(){
|
||||
var current = document.getElementsByClassName("active");
|
||||
current[0].className = current[0].className.replace(" active", "");
|
||||
this.className += " active";
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
</html>
|
@ -1,17 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/topicformat.css" />
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body class="title">
|
||||
|
||||
<h1>{{ page.name }}</h1>
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,55 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/orgs.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/orgs.js"></script>
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>{{ page.name }}</h1>
|
||||
|
||||
<div class="scrollcolumn">
|
||||
<button onclick="scrollWin(0,-5000)" class="up scrl"><span>⌜</span><span class="scbt">Up</span></button>
|
||||
<button onclick="scrollWin(0,5000)" class="down scrl"><span>⌟</span><span class="scbt">Down</span></button>
|
||||
<button onclick="scrollToTop()" class="top scrl"><span>⎴</span><span class="scbt">Top</span></button>
|
||||
<button onclick="scrollToBottom()" class="bottom scrl"><span>⎵</span><span class="scbt">Bottom</span></button>
|
||||
</div>
|
||||
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
<script>
|
||||
var coll = document.getElementsByClassName("collapsible");
|
||||
var i;
|
||||
|
||||
for (i = 0; i < coll.length; i++) {
|
||||
coll[i].addEventListener("click", function() {
|
||||
this.classList.toggle("active");
|
||||
var content = this.nextElementSibling;
|
||||
if (content.style.maxHeight){
|
||||
content.style.maxHeight = null;
|
||||
} else {
|
||||
content.style.maxHeight = content.scrollHeight + "px";
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function scrollWin(x, y) {
|
||||
window.scrollBy(x, y);
|
||||
}
|
||||
|
||||
var elmnt = document.getElementById("top");
|
||||
|
||||
function scrollToTop() {
|
||||
elmnt.scrollIntoView(true); // Top
|
||||
}
|
||||
|
||||
function scrollToBottom() {
|
||||
elmnt.scrollIntoView(false); // Bottom
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
@ -1,13 +0,0 @@
|
||||
<h1>{{ title|upper }}</h1>
|
||||
|
||||
<div class="row">
|
||||
<div class="column">
|
||||
|
||||
{% for img in imgs %}
|
||||
<img src="{{img}}" style="width:100%">
|
||||
{% endfor %}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{imgs}}
|
@ -1,12 +0,0 @@
|
||||
{{ '{{' }}ImageMetadata
|
||||
|Title={{ title }}
|
||||
|Date={{ date }}
|
||||
|Part={{ part }}
|
||||
|Partof={{ partof }}
|
||||
|Creator={{ creator }}
|
||||
|Organization={{ organization }}
|
||||
|Format={{ format }}
|
||||
|Event={{ event }}
|
||||
|Topic={{ topic }}
|
||||
|Language={{ language }}
|
||||
{{ '}}' }}
|
@ -1,17 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/stats.css" />
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body class="title">
|
||||
|
||||
<h1>{{ page.name }}</h1>
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,16 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/timeline.css" />
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>Timeline</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Timeline</h1>
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,49 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/title.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/title.js"></script>
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body class="title">
|
||||
|
||||
<h1>{{ page.name }} ↵</h1>
|
||||
|
||||
<!-- <div class="viewnav">
|
||||
<div class="collapsible2 viewbtn">▢</div>
|
||||
<div class="content2"> -->
|
||||
<div class="header" id="myHeader">
|
||||
<p><button class="btn clicked" onclick="myFunction()">▣</button></p>
|
||||
<p><button class="btnov clicked" onclick="myFunction2()">╬╬</button></p>
|
||||
</div>
|
||||
<!-- </div>
|
||||
<div> -->
|
||||
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
<script>
|
||||
var coll = document.getElementsByClassName("collapsible");
|
||||
var i;
|
||||
|
||||
for (i = 0; i < coll.length; i++) {
|
||||
coll[i].addEventListener("click", function() {
|
||||
this.classList.toggle("active");
|
||||
var content = this.nextElementSibling;
|
||||
if (content.style.maxHeight){
|
||||
content.style.maxHeight = null;
|
||||
} else {
|
||||
content.style.maxHeight = content.scrollHeight + "px";
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
var links = document.querySelectorAll("*[title]");
|
||||
for (var i=0; i<links.length; i++) { links[i].setAttribute("title", ""); }
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
@ -1,17 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/archive.css" />
|
||||
<script type="text/javascript" src="{{ staticpath }}/static/archive.js"></script>
|
||||
<link rel="stylesheet" href="{{ staticpath }}/static/topicformat.css" />
|
||||
<link href='https://fonts.googleapis.com/css?family=Roboto+Mono' rel='stylesheet' type='text/css'>
|
||||
<title>{{ page.name }}</title>
|
||||
</head>
|
||||
<body class="title">
|
||||
|
||||
<h1>{{ page.name }}</h1>
|
||||
<div id="body">{{ body|safe }}</div>
|
||||
|
||||
</body>
|
||||
</html>
|
File diff suppressed because one or more lines are too long
@ -1,116 +0,0 @@
|
||||
import os, argparse, sys, re
|
||||
from mwclient import (Site,
|
||||
errors)
|
||||
from jinja2 import Template
|
||||
from functions import (print_colormsg,
|
||||
reorder_imgs)
|
||||
|
||||
p = argparse.ArgumentParser(description='Upload files from a directory, with metadata values to the wiki.\n'
|
||||
'Note that any VALUES CONTAINING '
|
||||
'SPACES SHOULD BE BETWEEN QUOTATION MARKS',
|
||||
formatter_class=argparse.ArgumentDefaultsHelpFormatter)
|
||||
# TODO: Add example of command to description
|
||||
p.add_argument('--host', default='hub.xpub.nl/sandbox', help='wiki host')
|
||||
p.add_argument('--path', default='/itchwiki/', help='Wiki path. Should end with /')
|
||||
p.add_argument('--dry', '-d', action='store_true',
|
||||
help='dry-run: will only print the metadata of each file that '
|
||||
'will be upload, but does NOT upload')
|
||||
p.add_argument('--dir', required=True,
|
||||
help='Required. Full path of the image directory, that you wish to upload')
|
||||
|
||||
p.add_argument('--title', required=True,
|
||||
help='Required. Must not exist yet in the wiki.')
|
||||
p.add_argument('--date', required=True,
|
||||
help='Required. Format: yyyy/mm/dd '
|
||||
'For dates without day or month use 01 as default '
|
||||
'ie. 1986: --date "1986/01/01" '
|
||||
'March 1985: --date "1984/05/01"')
|
||||
p.add_argument('--creator', required=False, action='append', default=[''],
|
||||
help='Multiple values should be SEPARATED BY COMMA')
|
||||
p.add_argument('--org', required=False, action='append', default=[''],
|
||||
help='Organization:Multiple values should be SEPARATED BY '
|
||||
'COMMA')
|
||||
p.add_argument('--format', required=False, action='append', default=[''],
|
||||
help='Multiple values should be SEPARATED BY COMMA')
|
||||
p.add_argument('--event', required=False, action='append', default=[''],
|
||||
help='Multiple values should be SEPARATED BY COMMA')
|
||||
p.add_argument('--topic', required=False, action='append', default=[''],
|
||||
help='Multiple values should be SEPARATED BY COMMA')
|
||||
p.add_argument('--language', required=False, action='append', default=[''],
|
||||
help='Multiple values should be SEPARATED BY COMMA')
|
||||
|
||||
# TODO ADD NEW PROPS
|
||||
args = p.parse_args()
|
||||
|
||||
# login
|
||||
site = Site(host=args.host, path=args.path)
|
||||
|
||||
wd =os.path.dirname(os.path.abspath(__file__)) # parent working directory
|
||||
with open(os.path.join(wd, 'login.txt'), 'r') as login: # read login user & pwd
|
||||
loginlines = login.read()
|
||||
user, pwd = loginlines.split('\n')
|
||||
site.login(username=user, password=pwd) # login to wiki
|
||||
|
||||
# metadata checks
|
||||
if os.path.isdir(args.dir) is False:
|
||||
print_colormsg(f'Error: --dir {args.dir} absolute path cannot be found', level='fail')
|
||||
sys.exit()
|
||||
elif not re.match(r'\d{4}\/\d{2}\/\d{2}', args.date):
|
||||
print_colormsg(f'Error: --date {args.date} format should be --date "yyyy/mm/dd"', level='fail')
|
||||
sys.exit()
|
||||
elif len(list(site.ask(f'[[Title::{args.title}]]'))) > 0:
|
||||
print_colormsg(f'Error: --title "{args.title}" already exists in wiki. Provide a different one', level='fail')
|
||||
sys.exit()
|
||||
|
||||
# read template file
|
||||
with open(os.path.join(wd, 'templates/smw_infobox_template.jinja')) as tmplt:
|
||||
smw_propval_template = Template(tmplt.read())
|
||||
|
||||
lsimgs = reorder_imgs(dir=args.dir, dry=args.dry)
|
||||
dirname = os.path.split(args.dir)[-1].replace(' ', '_')
|
||||
dirname = re.sub(r'[\W]', '', dirname) #remove non letters or digits
|
||||
# print('lsimgs:', lsimgs, '\n', dirname)
|
||||
|
||||
for n, _file in enumerate(lsimgs):
|
||||
pagename = f'{dirname}-{_file}'
|
||||
print_colormsg(pagename, level='ok')
|
||||
page = site.pages[_file]
|
||||
|
||||
if page.exists:
|
||||
url = page.imageinfo['descriptionurl']
|
||||
print_colormsg(
|
||||
f'Already exists in {url} Will NOT be uploaded',
|
||||
level='warning')
|
||||
else:
|
||||
img_smw_prop_val = smw_propval_template.render(
|
||||
title=args.title,
|
||||
date=args.date,
|
||||
part=n + 1,
|
||||
partof=len(lsimgs),
|
||||
creator=(', ').join(args.creator[1:]),
|
||||
organization=(', ').join(args.org[1:]),
|
||||
format=(', ').join(args.format[1:]),
|
||||
event=(', ').join(args.event[1:]),
|
||||
topic=(', ').join(args.topic[1:]),
|
||||
language=(', ').join(args.language[1:])
|
||||
)
|
||||
|
||||
_file_path = os.path.join(args.dir, _file)
|
||||
if not args.dry:
|
||||
pageurl = f'https://{args.host}{args.path}index.php/File:{pagename}'
|
||||
with open(_file_path, 'rb') as _f:
|
||||
try:
|
||||
site.upload(file=_file_path,
|
||||
filename=pagename,
|
||||
description=img_smw_prop_val,
|
||||
ignore=True)
|
||||
print(img_smw_prop_val)
|
||||
except errors.APIError as e:
|
||||
print_colormsg(f'Error: {e.info}\n'
|
||||
f'It will not be uploaded',
|
||||
level='fail')
|
||||
|
||||
print(f'See image at {pageurl}')
|
||||
else:
|
||||
print(img_smw_prop_val)
|
||||
|
Loading…
Reference in New Issue