GithubHelp home page GithubHelp logo

jayanthkv / webpage-generator Goto Github PK

View Code? Open in Web Editor NEW

This project forked from stake2/php

0.0 0.0 0.0 2.87 MB

The PHP files used to create my websites

Home Page: https://thestake2.netlify.app/

License: MIT License

JavaScript 3.75% PHP 87.62% CSS 7.66% HTML 0.83% API Blueprint 0.14%

webpage-generator's Introduction

Stake2 PHP

PHP 7.4.26 Contributors

The PHP files for my Websites
The HTML files are generated using the /generate route on the Index.php file.
They stay here on the Websites Repository
Made by me, Stake2

License

Using MIT License

COC

Read Code of Conduct

Contribute

How to Contribute

Websites

The websites files, configuration, and style, are loaded from the files inside the Websites folder.

Loading websites

  1. Change the Document Root folder of your server to the folder where you cloned the repository
  2. Start your server
  3. You can open the /select route like http://localhost/select to select a website using the HTML form
    Or type the localhost URL with the website and language you want to use
    URL parameters:
http://localhost/select?website=[Website title here]&language=English
website: website name
language: language of the website
  • A list of website names in English and Portuguese can be found in Websites.json
  • Currently supported languages:
English
Portuguese

How websites are loaded

  1. The Index.php file gets the website variables like the title and language from the GET or POST, and stores them in the $_SESSION and $website["method"] variables
  2. It then defines the website files, configuration, style, and other variables for the website
  3. Then loads the website dependencies, PHP files, and tab templates if they exist

How websites are generated

  1. The Index.php file gets the website variables like the title and language from the GET or POST, and stores them in the $_SESSION and $website["method"] variables
  2. It then defines the website files, configuration, style, and other variables for the website
  3. Then loads the website dependencies, PHP files, and tab templates if they exist
  4. Then the /generate route exports the website content into a HTML file inside the specific website folder which exists inside the Websites folder, exporting the file to the correct language folder (en/ for English and pt/ for Portuguese)

Connection of PHP files to Python modules

The "Tasks.php" HTML tab generator reads the JSON database files generated by the "Tasks.py" Python module.
In order to generate the "Tasks" tab on the Tasks website.
And also generate the "Completed tasks" tabs on all year websites.

The "Watched.php" HTML tab generator reads the JSON database files generated by the "Watch_History.py" Python module.
In order to generate the "Watched things" and "Past registries" tabs on the Watch History website.
And also generate the "Watched things" tabs on all year websites.

The "Summary.php" HTML tab generator reads the summary text files generated by the "Years.py" Python module.
In order to generate "Summary" tabs on all year websites website.

Python: Connection of Python files to PHP files

webpage-generator's People

Contributors

stake2 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.