Skip to content

Instantly share code, notes, and snippets.

View avinashseth's full-sized avatar
🎯
Focusing

Avinash Seth avinashseth

🎯
Focusing
  • Self Employed
  • India
View GitHub Profile
{
"require": {
"phpmailer/phpmailer": "~5.2"
}
}
<?php
// check your directory structure, since i'm using this on project, your might look different
require_once(__DIR__ . '/../vendor/phpmailer/phpmailer/PHPMailerAutoload.php');
function send_new_email
(
$from = null,
$to = null,
$subject = null,
$message = null
)
<html lang="en">
<head>
<meta charset="utf-8">
<title>Learning react js - avinashseth.com</title>
<!-- you can also find it here https://facebook.github.io/react/downloads.html -->
<script src="https://fb.me/react-15.2.1.min.js"></script>
<script src="https://fb.me/react-dom-15.2.1.min.js"></script>
<!-- you can find this here https://facebook.github.io/react/docs/getting-started.html -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/babel-core/5.8.34/browser.min.js"></script>
</head>
<?php
require_once("basics_of.php");
echo "Working on core PHP both object oriented and functional, php version < 7";
echo "Worked on frameworks like Codeigniter both 2.x.x and 3.x.x";
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Avinash Seth</title>
<meta name="description" content="Looking for a job">
<!-- Mobile-friendly viewport -->
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
*{
margin: 0px;
padding: 0px;
}
/* Working experience on twitter bootstrap */
/* Working experience on core CSS */
var express = require('express');
var app = express();
app.get('/', function (req, res) {
res.send("Hi, i'm looking for a job? Do you have one?");
/* note for html, look at https://gist.github.com/avinashseth/c698c91d86200be8b384e88a12c1396f */
});
app.post('/response', function(req, res) {
var answer = req.param('answer');
$('document').ready(function(){
$('input[type=radio][name=opening]').on('change', function() {
$.ajax({
url: 'avinashseth.com/response',
data: {'answer':$('input[type=radio][name=opening]').val()},
error: function(error){
alert('Unable to make request, please check your internet connection');
},
success: function(message){
if(message.status == 200 || message.status == 101){
@avinashseth
avinashseth / hello_world.c
Last active July 10, 2018 13:54
How to write a hello world in c language
#include<stdio.h>
int main()
{
printf("Hello world!");
return 0;
}
#include<stdio.h>
int main()
{
int a = 5, b;
b = a++; // post increment operator
printf("%d", b); // output will be 5
// but now lets find the value of a
printf(" %d", a); // output will be 5 6
return 0;
}