How do I add things without updating?

Get help using Construct 2

Post » Mon Oct 13, 2014 3:39 pm

So I was thinking of making a iOS app, but before purchasing everything I'm making a plan.

I want to create a app that shows a list of upcoming eSport matches on CS:GO. Is it possible to modify this list on the app without the need of updating the app continuisly? Like having the list remote-controlled or something.
Website Twitter Indie Developer
B
20
S
6
G
4
Posts: 206
Reputation: 2,954

Post » Mon Oct 13, 2014 9:32 pm

Well. yeah, you need to make the app request data from an external source. I'm sure there is a lot of information out there to do this.
B
43
S
12
G
6
Posts: 446
Reputation: 6,807

Post » Tue Oct 14, 2014 7:05 am

I don't have any experience in this area but the link below should get you started.

AJAX
B
56
S
15
G
13
Posts: 826
Reputation: 17,705

Post » Tue Oct 14, 2014 10:33 am

@Tekniko Ok so I was trying to figure out what Ajax is, basically.
So I made a text object, then I did:
On start of layout -> Request "http://condolent.webuda.com/csgo_games/main.php"
On completed -> Set text to AJAX.LastData

It doesn't give anything.. :/
Website Twitter Indie Developer
B
20
S
6
G
4
Posts: 206
Reputation: 2,954

Post » Tue Oct 14, 2014 10:34 am

The only thing that happens is first the text object says "Text" (which is what I first wanted it to be) then it just goes blank after barely a second
Website Twitter Indie Developer
B
20
S
6
G
4
Posts: 206
Reputation: 2,954

Post » Tue Oct 14, 2014 10:39 am

It seems like it instantly fails. I suspect the cross-domain problem. I don't understand how I send a HTTP header? Is it via construct 2 or is it via the website?
Website Twitter Indie Developer
B
20
S
6
G
4
Posts: 206
Reputation: 2,954

Post » Tue Oct 14, 2014 10:43 am

I am pretty sure the problem is with cross domains being blocked. Maybe someone else can chime in on this.
B
56
S
15
G
13
Posts: 826
Reputation: 17,705

Post » Tue Oct 14, 2014 10:47 am

Yeah, what I need help with is how I send HTTP headers! I know I'm supposed to send Access-Control-Allow-Origin: * but I don't realize how I would do that. Or even if it's from my website or from construct!
Website Twitter Indie Developer
B
20
S
6
G
4
Posts: 206
Reputation: 2,954

Post » Tue Oct 14, 2014 11:46 am

Check out the "How do I FAQ" at the section "AJAX", it should have all the informations you need, and examples of use.
You can also use this keyword while searching for tutorials, IIRC there have already been a few tutorials on the subject as well.
New to Construct ? Where to start

Image Image

Image Image

Please attach a capx to any help request or bug report !
Moderator
B
296
S
119
G
96
Posts: 7,332
Reputation: 71,306

Post » Tue Oct 14, 2014 3:19 pm

@Kyatric I Already got the AJAX how-to solved, but what I'm struggling with is how I create a cross-domain policy for AJAX :/ I'll make a new thread for this, so you can lock this one!
Website Twitter Indie Developer
B
20
S
6
G
4
Posts: 206
Reputation: 2,954


Return to How do I....?

Who is online

Users browsing this forum: ounound and 23 guests