Skip to first unread message

Yan

unread,
May 6, 2019, 1:27:01 PM5/6/19
to MIT App Inventor Forum
Hello everyone!
I am beginner on app inventor and I am trying to make a login system connecting with mysql.
It is not successful to show the relevant words when username and password is correct.
When I entered the correct username and password, php program display the information is correct (echo "ok"). 
However, the app inventor can't show "login successful". 
How can I solve this problems???? 
Please help me!!!!!


((I'm sorry for my English >.<
a.png
c.png
b.png

TimAI2

unread,
May 6, 2019, 4:51:39 PM5/6/19
to MIT App Inventor Forum
Does it work if you post the request via your PC browser e.g.:
https://<yourUrl>?userName=abc&Password=123

Also if your text entries include any special characters, or have accents
then add an htmlEncode block for each text element in your join block

for example (from a different project)

blocksSpecialCharactersEncode.png


Taifun

unread,
May 6, 2019, 7:23:24 PM5/6/19
to MIT App Inventor Forum
you might want to use the BuildRequestData method as shown in this example https://puravidaapps.com/mysql.php

Taifun

Trying to push the limits of App Inventor! Snippets, Tutorials and Extensions from Pura Vida Apps by Taifun. 

Message has been deleted

Yan

unread,
May 7, 2019, 12:24:39 AM5/7/19
to mitappinv...@googlegroups.com
Hi, TimAI2
Thanks for replying and reminding of special characters!

It is not worked if I posted the request.... (d.png)
However, "set Label1.Text to get response Content" is "ok" !?!?
Is that the PHP code problem?

I have tried to change from $_POST to $_REQUEST in PHP.
It is worked when I posted the request in the browser(e.png), but it is still not worked in the emulator.
d.png
e.png

Yan

unread,
May 7, 2019, 12:25:42 AM5/7/19
to mitappinv...@googlegroups.com
Hi, Taifun!
Thank you for your reply!

I will try to look at the link.
Reply all
Reply to author
Forward
0 new messages