An HTML preprocessor for Python
Project description
PyHP (Python Hypertext Preprocessor)
PyHP is a Python script that can be used to write Python code in HTML, then execute it and render it to a page.
Getting Started
Installation
To use this project, install it using pip:
pip install python-hypertext-preprocessor
Alternatively, clone the repository and install the dependencies:
git clone https://github.com/Benjymack/pyhp.git
cd pyhp
pip install -r requirements.txt
Running the example Flask server
To run a simple Flask server with the pip installed version, use the following command:
python -m pyhp server path/to/directory
If you cloned from GitHub:
python -m src.pyhp server examples
In both cases, the server will be available at http://localhost:5000/
Running individual files
To run an individual example file, use the following command:
python -m pyhp file path/to/file.pyhp
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file python-hypertext-preprocessor-1.1.1.tar.gz.
File metadata
- Download URL: python-hypertext-preprocessor-1.1.1.tar.gz
- Upload date:
- Size: 10.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3c16a4b2590e9c45bbbe2c0088bcc41d17d14d4c5c06720b10666f65ffa0b62b
|
|
| MD5 |
f0e89faf3ce034b21ca8304ffc64c983
|
|
| BLAKE2b-256 |
9fda872fffc804ca2fbb0737ad010381f82e021b1d4f83703f0becfd33435d20
|
File details
Details for the file python_hypertext_preprocessor-1.1.1-py3-none-any.whl.
File metadata
- Download URL: python_hypertext_preprocessor-1.1.1-py3-none-any.whl
- Upload date:
- Size: 9.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.10.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a31788ddc24eb3eb71e6faceb8eec0b850516941dc992851af4919b757ce3d4c
|
|
| MD5 |
fd401f4db40dc0e76b31956afb973180
|
|
| BLAKE2b-256 |
062fc7a6fca3025478ed4360fe5c043942cd9547ce9b7d42d6ea80d1c5f3af75
|