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> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/redux/4.0.0/redux.min.js"> | |
</script> | |
<script src="https://unpkg.com/[email protected]/dist/react.min.js"></script> | |
<script src="https://unpkg.com/[email protected]/dist/react-dom.min.js"></script> |
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
<div class="main"> | |
<div class="container"> | |
<div class="box"> | |
<div class="circContainer"> | |
<div class="circ"></div> | |
<div class="circPulse one"></div> | |
<div class="circPulse two"></div> | |
</div> | |
</div> | |
</div> |
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
https://www.mercurytide.co.uk/media/resources/django-cheat-sheet.pdf |
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
https://stackoverflow.com/questions/6288661/adding-a-user-to-a-group-in-django | |
from django.contrib.auth.models import Group | |
group = Group.objects.get(name='groupname') | |
user.groups.add(group) | |
l = request.user.groups.values_list('name',flat=True) |
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
ifconfig | |
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
https://stackoverflow.com/questions/618557/django-using-select-multiple-and-post | |
list = request.POST.getlist("items[]") |
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
JSON.parse("["+document.querySelector("input[name='specialty']").value+"]"); | |
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
// data[['type']] = payloads['room']; | |
// data[payloads['data']] = {}; | |
// data[payloads['data']][payloads['type']] = payloads['create']; | |
// data[payloads['data']][payloads['room']] = {}; | |
// data[payloads['data']][payloads['room']][ | |
// payloads['started_by'] | |
// ] = chat_starter_username; | |
// data[payloads['data']][payloads['room']][ | |
// payloads['chat_invite'] | |
// ] = 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
var $jscomp = $jscomp || {}; | |
$jscomp.scope = {}; | |
$jscomp.findInternal = function(g, l, v) { | |
g instanceof String && (g = String(g)); | |
for (var A = g.length, G = 0; G < A; G++) { | |
var L = g[G]; | |
if (l.call(v, L, G, g)) | |
return { | |
i: G, | |
v: L |
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
we = ['a', 'w', 'a', 'i'] | |
temp_dict = {} | |
for w in we: | |
no_count = temp_dict.get(w, '') | |
if no_count == '': | |
temp_dict[w] = 1 | |
else: | |
temp_dict[w] = no_count+1 |
OlderNewer