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
const array1 = []; | |
// adding 100k elements to array1 | |
for (let i = 0; i < 150000; i++) { | |
array1.push(i); | |
} | |
// creating a copy of the array1 variable | |
const array2 = []; | |
Array.prototype.push.apply(array2, array1); |
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
const array1 = []; | |
// adding 100k elements to array1 | |
for (let i = 0; i < 500000; i++) { | |
array1.push(i); | |
} | |
// creating a copy of the array1 variable | |
const array2 = []; | |
array2.push(...array1); |
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
client_max_body_size 10M; |
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
location /uploads { | |
# ... | |
client_max_body_size 10M; | |
} |
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
server { | |
# ... | |
client_max_body_size 10M; | |
} |
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
http { | |
# ... | |
client_max_body_size 10M; | |
} |
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
// index.js or server.js | |
const express = require("express") | |
// ... | |
const app = express() | |
// ... |
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
<? | |
$curl = curl_init($url); | |
curl_setopt($curl, CURLOPT_URL, "https://www.w3schools.com/jquery/demo_test_post.asp"); | |
// specify that the cURL request is a POST | |
curl_setopt($curl, CURLOPT_POST, true); | |
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); | |
// define the body of the request | |
curl_setopt($curl, CURLOPT_POSTFIELDS, | |
// http_build_query is required to simulate |
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
<? | |
$from = null; | |
$to = null; | |
if (isset($_GET["from"]) && is_numeric($_GET["from"])) { | |
$from = $_GET["from"]; | |
} | |
if (isset($_GET["to"]) && is_numeric($_GET["to"])) { | |
$to = $_GET["to"]; |
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
<? | |
curl_setopt($curl, CURLOPT_PROXY, "<PROXY_URL>"); | |
curl_setopt($curl, CURLOPT_PROXYPORT, "<PROXY_PORT>"); | |
curl_setopt($curl, CURLOPT_PROXYTYPE, "<PROXY_TYPE>"); |