-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
65 lines (52 loc) · 1.79 KB
/
index.php
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php
include_once("includes/mysql_connect.php");
include_once("includes/shopify.php");
/**
* =====================================================================================
* Crear variables
* - $shopify
* - $parameters
* =====================================================================================
*/
// usar Query y Select para tener la información de la tienda
$shopify = new shopify();
$parameters = $_GET;
/**
* =====================================================================================
* cheking the shopify store
* =====================================================================================
*/
include_once("includes/check_token.php");
/**
* =====================================================================================
* Display anything of the store
* =====================================================================================
*/
// se puede cambiar el response aca por cada scope
//$access_scopes = $shopify-> rest_api('/admin/oauth/access_scopes.json', array(),'GET');
//$response = json_decode($access_scopes['body'], true);
?>
<?php include_once("headers.php"); ?>
<?php
$query =array("query" => "{
shop {
id
name
email
}
}");
$graphql_test = $shopify->graphql($query);
$graphql_test = json_decode($graphql_test['body'], true);
echo print_r ($graphql_test);
?>
<section>
<div class="alert column twelve">
<dl>
<dt>
<p>Bienvenidos </P>
</dt>
</dl>
</div>
</section>
<footer></footer>
<?php include_once("footer.php"); ?>