The script doesnt work | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

The script doesnt work

The script inside echo wont show alert instead directly to header location. Whats wrong? https://code.sololearn.com/wbkb0xvxdxU8/?ref=app

9th Jan 2021, 3:14 AM
Sandy Harys
Sandy Harys - avatar
1 Answer
+ 3
The if statements are not return true... The value of the variable result is not true. Therefore it doesn't alert rather echoes out the text 'Data Gagal Disimpan' as of line 14 But you wont get time to see the text echoed as the php file has used the function header to goto another page...
9th Jan 2021, 3:50 AM
Steve Sajeev
Steve Sajeev - avatar