1
0

Madsack+ Viewer WebApp

Description

This simple web application is designed to extract the SEO string from news pages generated by the Arc XP Content Suite CMS. The magic here is in a single regex statement:

json.loads(re.findall('Fusion.globalContent=(.*?);Fusion.globalContentConfig', Article.text)[0])

The resulting JSON blob can now be further processed and displayed in a web application or smartphone app, for example.

Architecture

├── api
│   ├── app
│   │   ├── main.py
│   │   └── requirements.txt
│   ├── build.sh
│   └── Containerfile
├── README.md
└── web
    ├── favicon
    │   └── ...
    ├── index.html
    ├── madsack.js
    └── switch.js

┌──────────────┐         ┌──────────────┐
│ Backend API  │         │ Web Frontend │
│              │◄────────┤              │
│ Python/Flask │   HTTP  │ HTML/CSS/JS  │
└──────────────┘         └──────────────┘

 Backend runs in          Frontend runs on
 a container.             any web server of
                          your choice.

How do I build this?

  1. Build the backend container image using build.sh
  2. Run container - flask is listening on 8088
  3. Deploy the frontend on a web server of your choice (i used nginx)
  4. Configure url variable in getArticle function to your backend endpoint
Description
No description provided
Readme 103 KiB
Languages
HTML 46.7%
JavaScript 45.8%
Python 5.1%
Dockerfile 1.9%
Shell 0.5%