AJAX not rendering PHP Page Correctly

Get help using Construct 2

Post » Wed Mar 27, 2013 9:27 pm

Hi guys,

I'm having an issue with Ajax, the page that i'm calling is being returned with all of the HTML tags in place, I've tried with several browsers and the same things keeps happening.

Here's what I've set in the event sheet:

https://dl.dropbox.com/u/10801527/event.PNG

I'm trying to make a simple call to an existing PHP file on a server, here is the page as it exists outside of CS2:

http://www.winkleburyfederation.com/mobile.php

When I call this page in an AJAX request from my CS2 project (which HAS been uploaded to the same server ), it is showing the HTML tags.

Click the blue box to call the AJAX request:

http://www.winkleburyfederation.com/ajaxtest/index.html


Any ideas what's going on with the last link?
B
3
Posts: 1
Reputation: 277

Post » Wed Mar 27, 2013 10:57 pm

The text object will just display the result of the AJAX request as text. It's not going to parse HTML for you or anything. You might want to use one of Pode's HTML plugins: http://www.scirra.com/forum/plugins-pode-html-pack_topic51522.html
B
54
S
28
G
18
Posts: 1,520
Reputation: 25,000


Return to How do I....?

Who is online

Users browsing this forum: jul, nimos100 and 22 guests