MySQL database in Construct 2

Get help using Construct 2

Post » Sun Aug 23, 2015 4:40 pm

Hello, I have a problem with Construct 2 and my database My Sql.
I would want to put in my game a system of connection (the registration is made in my web site)
I looked tutorial: Simple Login using a MySQL database by emperorkk
The condition if that succeeded was that objects destroy themselves but it does not work!
Here are some screens:
(Sorry for my english, i am frensh)
Image
Image
PS: the layout contains the button TextBox: Password and Username.
PS2: I put the good path(way) towards the login.php
Thank you !
B
4
S
1
Posts: 11
Reputation: 375

Post » Wed Aug 26, 2015 11:53 pm

maybe you can use json code... parsing php and get with ajax :)
B
6
S
1
Posts: 12
Reputation: 422

Post » Thu Aug 27, 2015 1:20 am

@SowSow

your ajax request is calling http://thefunkkystreet.livehost.fr/stars/login.php

but I get a 404 page not found at that address, so it looks like you are calling the wrong page address...
B
94
S
33
G
20
Posts: 438
Reputation: 17,615

Post » Thu Aug 27, 2015 10:10 am

Just below "<?php" put some output information, for example "die('here I am');". Than check if C2 AJAX.LastData holds this value. You can use Browser -> Alert (AJAX.LastData). This will tell you if you are calling a good address. You can do the same with parameters like "die($_GET['login']))" etc. to check if values comes to PHP succesfully.
ImageImage
B
27
S
16
G
68
Posts: 935
Reputation: 38,579


Return to How do I....?

Who is online

Users browsing this forum: stevenode, tarek2 and 9 guests