forked from incarnate/curl-to-php
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
47 lines (39 loc) · 1.86 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<!DOCTYPE html>
<html>
<head>
<title>curl-to-PHP: Convert Curl commands to PHP code</title>
<meta charset="utf-8">
<script src="resources/js/jquery.min.js" type="text/javascript"></script>
<script src="resources/js/highlight.pack.js" type="text/javascript"></script>
<script src="resources/js/common.js" type="text/javascript"></script>
<!--<script src="resources/js/json-to-PHP.js" type="text/javascript"></script> -->
<script src="resources/js/curl-to-php.js" type="text/javascript"></script>
<link rel="stylesheet" href="resources/css/color-brewer.css">
<link rel="stylesheet" href="resources/css/common.css">
</head>
<body>
<header>
<h1>Curl-to-PHP</h1>
<h2>Instantly convert <a href="http://curl.haxx.se/">curl</a> commands to <a href="http://php.net/">PHP</a> code</h2>
<p>
This tool turns a Curl command into PHP code. Currently, it knows the following options: -d/--data/--data-binary, -F/--form, -H/--header, -I/--head, -u/--user, compressed, ---url and -X/--request. There's probably bugs; please <a href="https://github.com/incarnate/curl-to-php">contribute on GitHub</a>!
</p>
<p>
This script derives from Matt Holt's excellent <a href="https://github.com/mholt/curl-to-go">curl-to-Go</a>.
</p>
<p class="examples">
<a href="javascript:" id="example1">Example 1</a> ·
<a href="javascript:" id="example2">Example 2</a> ·
<a href="javascript:" id="example3">Example 3</a> ·
<a href="javascript:" id="example4">Example 4</a> ·
<a href="javascript:" id="example5">Example 5</a>
</header>
<main>
<textarea id="input" rows="4" placeholder="Paste curl here"></textarea>
<div id="output"></div>
</main>
<footer>
© 2017 - John C <a href="https://github.com/incarnate/curl-to-php">View on GitHub</a> - <a id="dark" href="javascript:">dark mode</a>
</footer>
</body>
</html>