Skip to content

Instantly share code, notes, and snippets.

Sivaprabu Ganesan gsivaprabu

Block or report user

Report or block gsivaprabu

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@gsivaprabu
gsivaprabu / youtube_remove_like_videos.js
Last active Sep 12, 2019
How to Delete all liked YouTube Videos at once!
View youtube_remove_like_videos.js
/* For more https://www.youtube.com/watch?v=wg3ubtxyfyQ */
/* How to delete all liked YouTube Videos at once!
IMPORTANT! You have to click on "Edit" after you click on the "Liked videos" playlist, then you open up the console and use the code! This method does not work if you don't click on "Edit"!
1. Click on "Liked videos" under "Library".
2. Click on "Edit".
3. Open the browser console.
@gsivaprabu
gsivaprabu / importJSON.js
Created Feb 8, 2019
Fetching JSON using google spread sheet
View importJSON.js
/**
* Retrieves all the rows in the active spreadsheet that contain data and logs the
* values for each row.
* For more information on using the Spreadsheet API, see
* https://developers.google.com/apps-script/service_spreadsheet
*/
function readRows() {
var sheet = SpreadsheetApp.getActiveSheet();
var rows = sheet.getDataRange();
var numRows = rows.getNumRows();
View range.c
#include <stdio.h>
void main() {
int i = 0, recid = i = 320;
int lastRecordId = 0;
printf(" enter last record id :");
scanf("%d", & lastRecordId);
printf("lastRecordId:%d", lastRecordId);
i = recid;
while (i > 0) {
if (i <= lastRecordId && i > (lastRecordId - 300))
@gsivaprabu
gsivaprabu / postman.js
Created Jul 5, 2017
Set cookie value and csrf value as global postaman value
View postman.js
tests["Status code is 200"] = responseCode.code === 200;
// getting CSRF token value from responseBody and stored in global variable
var data = JSON.parse(responseBody);
console.info("CSRF Token Value = " + data.CSRFToken);
postman.setGlobalVariable("csrftoken", data.CSRFToken);
// getting QSESSIONID value from Cookie and stored in global variable
var qsessionidValue = postman.getResponseCookie("QSESSIONID").value
console.log(qsessionidValue);
@gsivaprabu
gsivaprabu / Gruntfile.js
Last active Jul 1, 2017
How to remove the console logs in my minified/compresed js files using below Gruntfile.js ?
View Gruntfile.js
module.exports = function(grunt) {
"use strict";
grunt.initConfig({
// Wipe out previous builds and test reporting.
clean: ["dist/", "test/reports"],
// Run your source code through JSHint's defaults.
jshint: {
options: {
laxcomma: true,
'-W086': true,
@gsivaprabu
gsivaprabu / parseint.html
Last active May 4, 2017
Confusing string/number with parseInt() Using JavaScript
View parseint.html
<!DOCTYPE html>
<html>
<head>
<title> Confusing string/number using JavaScript</title>
<h1 align="center"><u> Confusing string/number with parseInt() Using JavaScript</u></h1>
</head>
<body>
<script type="text/javascript">
@gsivaprabu
gsivaprabu / users.json
Created Feb 10, 2017
Just call test purpose user credetial
View users.json
[{
"firstName": "Sivaprabu",
"lastName": "Ganesan",
"userName": "gsivaprabu",
"password": "gsivaprabu",
"age": 32,
"address": {
"streetAddress": "Kamaraj Nagar",
"city": "Namakkal",
"state": "Tamil Nadu",
@gsivaprabu
gsivaprabu / ipv6Validation.html
Last active Jan 12, 2017
Remove [ and ] in ipv6 address using JavaScript
View ipv6Validation.html
<!DOCTYPE html>
<html>
<head>
<title> Remove [ and ] in ipv6 address using JavaScript</title>
<h1 align="center"><u> Remove [ and ] in ipv6 address using JavaScript</u></h1>
<script>
var ipv6 = '[2001:0db8:0000:0000:0000:ff00:0042:8329]';
// var ipv6 = '10.0.124.75';
ipv6 = ipv6.replace(/[\]\[]/g, '');
@gsivaprabu
gsivaprabu / ClosureInJavaScript.html
Created Dec 23, 2016
Closure concept in JavaScript
View ClosureInJavaScript.html
Closure concept in JavaScript
View broadcast.html
<!DOCTYPE html>
<html>
<head>
<title>Broadcasting</title>
<script src="js/angular.min.js"></script>
<script>
var app = angular.module('app', []);
app.controller("firstCtrl", function ($scope) {
$scope.handleClick = function (msg) {
You can’t perform that action at this time.