We need to create a virtual env for our app to run in: More Here Run this command in whatever folder you want to create your venv folder
python -m venv ./venv
<?php | |
$host = 'localhost'; | |
$user = 'root'; | |
$password = '123456'; | |
$dbname = 'pdoposts'; | |
// Set DSN | |
$dsn = 'mysql:host='. $host .';dbname='. $dbname; | |
// Create a PDO instance |
# GET VERSION | |
yarn -v (or --version) | |
# GET HELP | |
yarn help | |
# CREATE PACKAGE.JSON | |
yarn init | |
yarn init -y // Use defaults |
class Stack { | |
constructor() { | |
this.items = [] | |
this.count = 0 | |
} | |
// Add element to top of stack | |
push(element) { | |
this.items[this.count] = element | |
console.log(`${element} added to ${this.count}`) |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/brython/3.8.8/brython.js" integrity="sha256-rA89wPrTJJQFWJaZveKW8jpdmC3t5F9rRkPyBjz8G04=" crossorigin="anonymous"></script> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/brython/3.8.8/brython_stdlib.js" integrity="sha256-Gnrw9tIjrsXcZSCh/wos5Jrpn0bNVNFJuNJI9d71TDs=" crossorigin="anonymous"></script> |
// Construct Single Node | |
class Node { | |
constructor(data, next = null) { | |
this.data = data; | |
this.next = next; | |
} | |
} | |
// Create/Get/Remove Nodes From Linked List | |
class LinkedList { |
We need to create a virtual env for our app to run in: More Here Run this command in whatever folder you want to create your venv folder
python -m venv ./venv
<?php | |
/* | |
* PDO DATABASE CLASS | |
* Connects Database Using PDO | |
* Creates Prepeared Statements | |
* Binds params to values | |
* Returns rows and results | |
*/ | |
class Database { | |
private $host = DB_HOST; |
Create the backend for a bootcamp directory website. The frontend/UI will be created by another team (future course). The html/css template has been created and can be used as a reference for functionality. All of the functionality below needs to be fully implmented in this project.