- Install Node 7 via NVM: https://github.com/creationix/nvm
- Download and setup Visual Studio Code
- Install Nginx (yum install nginx)
- Install Mongodb (https://docs.mongodb.com/manual/administration/install-on-linux/)
- To create a file in /etc, we need to install nano text editor.
sudo dnf install nano
- Create a file in /etc/yum.repos.d/mongodb-org-3.4.repo
sudo nano /etc/yum.repos.d/mongodb-org-3.4.repo
-
[mongodb-org-3.4]
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Configuration; | |
using System.Data; | |
using System.Data.SqlClient; | |
using System.Linq; | |
using System.Web; | |
/// <summary> | |
/// Summary description for CRUDHelper |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$target_dir = "photos/"; | |
$target_file = $target_dir . basename($_FILES["photo"]["name"]); | |
$uploadOk = 1; | |
$imageFileType = strtolower(pathinfo($target_file, PATHINFO_EXTENSION)); | |
// Check if image file is a actual image or fake image | |
if (isset($_POST["submit"])) { | |
$check = getimagesize($_FILES["photo"]["tmp_name"]); | |
if ($check !== false) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$servername = "your-maria-db-server"; | |
$username = "your-db-username"; | |
$password = "your-db-password"; | |
$dbname = "your-dbanme"; | |
$db = new PDO('mysql:host=' . $servername . ';dbname=' . $dbname, $username, $password); | |
function selectAnd($entityName, $where = null, $orderBy = null) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CoreEditor Workload is required. | |
You can remove the Workloads as you deem. | |
Open Command Prompt in the directory where 'vs_community.exe' is downloaded. | |
Run the command 'vs-community-2017-offline.txt' in the Command Prompt. | |
Workloads | |
========= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const cron = require('node-cron'); | |
let fs = require('fs'); | |
let sql = require('mssql/msnodesqlv8'); | |
let mssql = require('mssql'); | |
let lastid = 0; | |
let config = { | |
driver: 'msnodesqlv8', | |
connectionString: 'Driver={SQL Server Native Client 10.0};Server=localhost\\Username;Database=Database;Trusted_Connection=yes;' | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<!-- Latest compiled and minified CSS --> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> | |
<!-- jQuery library --> | |
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> | |
<!-- Latest compiled JavaScript --> | |
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script> | |
<!-- Angular JS file --> | |
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.4/angular.min.js"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo dnf update | |
sudo dnf install nginx | |
sudo dnf install openssh-server openssh-clients | |
sudo dnf install httpd | |
sudo systemctl enable httpd.service | |
sudo systemctl start httpd | |
sudo systemctl status httpd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let moment = require('moment'); | |
let http = require('http'); | |
let url = require('url'); | |
let bluebird = require('bluebird'); | |
let fs = bluebird.promisifyAll(require('fs')); | |
let visitorCount = 0; | |
let users = []; | |
if (visitorCount == 0) { |
NewerOlder