Skip to content

Instantly share code, notes, and snippets.

View palchandu's full-sized avatar
😎
Willing for doing more programing..

Chandra Prakash Pal palchandu

😎
Willing for doing more programing..
View GitHub Profile
@palchandu
palchandu / Basic Ubuntu Commands.md
Created September 9, 2024 05:29 — forked from TechRancher/Basic Ubuntu Commands.md
Ubuntu 18.04 Terminal Commands

Basic Ubuntu Commands

This is a list of the most basic but extremely useful commands. Learning these will help you have a strong foundation to add more sophisticated commands upon.

Here are some words that we use and some meanings that you may associate them with.

We use What you may know them as
directory folder
sudo Run as Administor
Create React App is a comfortable environment for learning React, and is the best way to start building a new single-page application in React.
It sets up your development environment so that you can use the latest JavaScript features, provides a nice developer experience, and optimizes your app for production. You’ll need to have Node >= 14.0.0 and npm >= 5.6 on your machine. To create a project, run:
@palchandu
palchandu / sample-php-headers.php
Created September 17, 2020 06:26 — forked from ScottPhillips/sample-php-headers.php
PHP Header Examples
301 moved permanently (redirect):
<?php
header('HTTP/1.1 301 Moved Permanently');
header('Location: http://www.example.com');
die();
?>
302 moved temporarily(redirect):
<?php
header('Location: http://www.example.com');
@palchandu
palchandu / aggregate.js
Created April 17, 2019 12:34
Aggregate data from MongoDB with Node.js and mongoose
var mongoose = require('mongoose');
var Schema = mongoose.Schema;
//Database connection
var uristring = 'mongodb://localhost/test';
var mongoOptions = { };
mongoose.connect(uristring, mongoOptions, function (err, res) {
if (err) {
console.log('Error when connecting to: ' + uristring + '. ' + err);