Send text receive text

Get help using Construct 2

Post » Tue Dec 06, 2011 2:10 am

I want to make a sort of "game" where you send text to a web server/database, and you get something that someone submitted from that database. Does this involve ajax? Is it possible in Construct 2?
B
17
S
3
G
5
Posts: 24
Reputation: 3,438

Post » Tue Dec 06, 2011 2:27 am

Yeah, you'd need AJAX to do this, but it certainly is possible. If you need to learn how to use it with Construct 2, this tutorial is a great place to start:

http://scirra.com/tutorials/61/ajax-example-with-construct-2

And of course, we're here if you have any questions after that.
B
20
S
9
G
6
Posts: 607
Reputation: 6,112

Post » Tue Dec 06, 2011 2:28 am

I actually just found that. How do I send stuff to a database though?
B
17
S
3
G
5
Posts: 24
Reputation: 3,438

Post » Tue Dec 06, 2011 2:37 am

You should check the "AJAX" section of the how do I FAQ.
There are practical examples.
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,999
Reputation: 57,793

Post » Tue Dec 06, 2011 6:18 am

Alright so I had a look at the example here: http://www.scirra.com/forum/topic45860_post287339.html

I think I understand how the system works, but how do I send text from a textbox?
B
17
S
3
G
5
Posts: 24
Reputation: 3,438

Post » Tue Dec 06, 2011 7:26 pm

Bump, I really need an answer.
B
17
S
3
G
5
Posts: 24
Reputation: 3,438

Post » Tue Dec 06, 2011 7:38 pm

Unfortunately your question doesn't make that much sense.
Could you precise what you would like to do, what is the intent in the code, and some idea you would have to implement this function ?

If you have followed the tutorials/examples about AJAX, you should be able to answer to your question by yourself honestly.
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,999
Reputation: 57,793

Post » Tue Dec 06, 2011 7:47 pm

I want the code to be able to take text a user puts into a textbox, send it to a database, and at the same time pull and display a random line of text from that database onto the screen when the user submits his text.
B
17
S
3
G
5
Posts: 24
Reputation: 3,438


Return to How do I....?

Who is online

Users browsing this forum: HeinRich, Zakeru and 24 guests