This file contains hidden or 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
<?php | |
@if(old('uid_tag')) | |
@foreach(old('uid_tag') as $product) | |
<input type="text" name="uid_tag[]" value="{{ old('uid_tag')[$loop->index] }}" size="30" /> | |
<textarea | |
placeholder="Include weight or count" | |
name="product_description[]" | |
cols="45" | |
rows="1" | |
value="{{ old('product_description')[$loop->index] }}" |
This file contains hidden or 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
<?php | |
namespace App\Services; | |
use App\Post; | |
class Slug | |
{ | |
/** | |
* @param $title |
This file contains hidden or 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
<?php | |
namespace App\Console\Commands; | |
use Illuminate\Console\Command; | |
class PewPewPew extends Command | |
{ | |
protected $signature = 'pewpewpew'; | |
protected $description = 'Command description'; |
This file contains hidden or 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
function scraper() { | |
/* Create two sheets with name "Settings" and "Scraper".Put your API key in the Setting tab B1 and put your ASIN list | |
in the Scraper tab*/ | |
var apiKey = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Settings").getRange(1, 2).getValue(); | |
var scraperSheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Scraper") | |
var lrow = scraperSheet.getLastRow(); |
This file contains hidden or 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
# Small Python Script to scrape websites for | |
# email addresses and phone numbers(not a very great RE) | |
# Author: Dhruv Baldawa (@dhruvbaldawa on twitter) | |
# Github: http://www.github.com/dhruvbaldawa | |
import urllib,re | |
f = urllib.urlopen("http://www.example.com") | |
s = f.read() | |
re.findall(r"\+\d{2}\s?0?\d{10}",s) | |
re.findall(r"[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}",s) |
This file contains hidden or 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
function zeroCells() { | |
var ss=SpreadsheetApp.getActiveSpreadsheet(); | |
var sheet=ss.getSheets()[0]; | |
var selection=sheet.getDataRange(); | |
var columns=selection.getNumColumns(); | |
var rows=selection.getNumRows(); | |
for (var column=1; column < columns; column++) { | |
for (var row=1; row < rows; row++) { | |
var cell=selection.getCell(row,column); | |
if (cell.isBlank()) { |
This file contains hidden or 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
function initFollowerCount() { | |
// sets up sheet names and Instagram accounts | |
insertFollowerCount("sheet1", "kingandmcgaw"); | |
insertFollowerCount("sheet2", "nickboyce"); | |
} | |
function insertFollowerCount(sheetName, instagramAccountName) { | |
var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
var sheet = ss.getSheetByName(sheetName); | |
sheet.appendRow([Utilities.formatDate(new Date(), "GMT", "yyyy-MM-dd"), getInstagramFollowerCount(instagramAccountName)]); |
This file contains hidden or 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
// Thank you to @juliendev for his script (updated here with minor cosmetic changes) | |
// https://gist.github.com/JulienDev/df5a3b66e899c224fa1b2dc90acfa2ae | |
// Your sheet name in the document | |
var sheetName = "Sheet1"; | |
// Your instagram user id | |
var user_id = ""; //find your id here : https://codeofaninja.com/tools/find-instagram-user-id | |
var instagram_base_url = "https://www.instagram.com/graphql/query/"; | |
var following = "?query_hash=58712303d941c6855d4e888c5f0cd22f&variables=%7B%22id%22%3A%22" + user_id + "%22%2C%22first%22%3A24%7D" |
This file contains hidden or 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
// Exemplo de requisição GET | |
var ajax = new XMLHttpRequest(); | |
// Seta tipo de requisição e URL com os parâmetros | |
ajax.open("GET", "minha-url-api.com/?name=Henry&lastname=Ford", true); | |
// Envia a requisição | |
ajax.send(); | |
// Cria um evento para receber o retorno. |
This file contains hidden or 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
<main class="main post" id="anchor" role="main"> | |
Content... | |
</main> | |
<a id="topBtn" class="btn-fixed" href="#anchor"> | |
Lleva a la parte superior de la página. | |
</a> | |
<script> | |
// When the user scrolls down 500px from the top of the document, show the button |