Skip to content

Instantly share code, notes, and snippets.

View Jignesh-Darji's full-sized avatar
😃
Working as .Net full stack developer

Jignesh Darji Jignesh-Darji

😃
Working as .Net full stack developer
View GitHub Profile
@Jignesh-Darji
Jignesh-Darji / Remove default info window in google map.txt
Created June 28, 2018 13:16
Remove default info window in google map
// Remove default info window in google map
google.maps.event.addListener(infowindow, 'domready', function() {
// Reference to the DIV that wraps the bottom of infowindow
var iwOuter = $('.gm-style-iw');
/* Since this div is in a position prior to .gm-div style-iw.
* We use jQuery and create a iwBackground variable,
* and took advantage of the existing reference .gm-style-iw for the previous div with .prev().
*/
@Jignesh-Darji
Jignesh-Darji / How to set permission of folder on amazon ec2 using putty.txt
Created June 28, 2018 13:08
How to set permission of folder on amazon ec2 using putty
//How to set permission of folder on amazon ec2 using putty
chmod 777 path/
chown -R ec2-user /var/www/html
chmod -R 755 /var/www/html
@Jignesh-Darji
Jignesh-Darji / How do I troubleshoot problems connecting to my EC2 Linux instance using SSH.txt
Created June 28, 2018 13:07
How do I troubleshoot problems connecting to my EC2 Linux instance using SSH
Issue
I have created and launched an EC2 Linux instance, but I can't connect to the instance using SSH or utilities that connect over SSH such as PuTTY. When I attempt to connect from the Linux command shell, the connection attempt hangs, and when I connect using the PuTTY client an error similar to the following is displayed in the PuTTY client user interface:
Network error: Connection timed out
Short Description
Both problems indicate that you are unable to access your EC2 instance from your current IP address using SSH.
Network connectivity to an EC2 instance is not enabled by default. You need to make some configuration changes in your VPC in the AWS management console.
@Jignesh-Darji
Jignesh-Darji / Overlay slide from top using css.html
Created April 9, 2018 09:21
Overlay slide from top using css
<!DOCTYPE html>
<html>
<head>
<style>
.container {
position: relative;
width: 50%;
}
.image {
@Jignesh-Darji
Jignesh-Darji / Simple tooltips made of pure CSS.html
Created April 9, 2018 09:20
Simple tooltips made of pure CSS
<html>
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/balloon-css/0.4.0/balloon.min.css">
</head>
<body>
<button data-balloon-length="xlarge" data-balloon="What about something really big? This may surpass your window dimensions. Imagine you're on that boring class with that boring teacher and you didn't slept so well last night. Suddenly you're sleeping in class. Can you believe it?! What about something really big? This may surpass your window dimensions. Imagine you're on that boring class with that boring teacher and you didn't slept so well last night. Suddenly you're sleeping in class. Can you believe it?!" data-balloon-pos="down">Xlarge tooltip</button>
</body>
</html>
@Jignesh-Darji
Jignesh-Darji / QR Code Scanner Using HTML.html
Created April 9, 2018 09:19
QR Code Scanner Using HTML
<html>
<head>
<style>
body, input {font-size:14pt}
input, label {vertical-align:middle}
.qrcode-text {padding-right:1.7em; margin-right:0}
.qrcode-text-btn {display:inline-block; background:url('http://dab1nmslvvntp.cloudfront.net/wp-content/uploads/2017/07/1499401426qr_icon.svg') 50% 50% no-repeat; height:1em; width:1.7em; margin-left:-1.7em; cursor:pointer}
.qrcode-text-btn > input[type=file] {position:absolute; overflow:hidden; width:1px; height:1px; opacity:0}
</style>
@Jignesh-Darji
Jignesh-Darji / Numeric Updown controller using html 5.html
Created April 9, 2018 09:18
Numeric Updown controller using html 5
<html>
<body>
<input type="number"/>
</body>
</html>
@Jignesh-Darji
Jignesh-Darji / how to display price label in Google Map.html
Created April 9, 2018 09:17
how to display price label in Google Map
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>MarkerWithLabel Example</title>
<style type="text/css">
.labels {
margin-top:-3px;
padding: 5px;
position: absolute;
@Jignesh-Darji
Jignesh-Darji / How to Make Magic, Animated Tooltips With CSS.html
Created April 9, 2018 09:16
How to Make Magic, Animated Tooltips With CSS
<html>
<head>
<style>
/* START TOOLTIP STYLES */
[tooltip] {
position: relative; /* opinion 1 */
}
/* Applies to all tooltips */
[tooltip]::before,
@Jignesh-Darji
Jignesh-Darji / ChangeIISSiteBinding.cs
Last active March 28, 2018 10:19 — forked from vnisor/gist:42ebcc196ab2d8675df46adfc191242c
How to change bindings on a site in IIS using C#
void ChangeSiteBinding(string siteName, string newBindingValue, string protocol)
{
using (ServerManager manager = new ServerManager())
{
// Find the site by name from IIS
Microsoft.Web.Administration.Site site = manager.Sites.Where(q => q.Name == siteName).FirstOrDefault();
if (site == null)
{
throw new Exception("The specified site name does not exist in IIS!");
}