amber ɹəqɯɐ
New member
I have just discovered ajax. I don't quite understand why this setup doesn't work:
I have a page - users.php
Inside this page I have a button that calls userlist.php to the innerHTML of a div.
It works just fine.
Now I have created admin.php, and using the same method, I have called users.php to a div inside admin.php.
But now the button does not call userlist.php to users.php.
So the code functions properly until it is placed inside a container on another page.
How do you make this work?
I figured it out.
The function to call userlist.php was in users.php
I moved the function to admin.php and it works perfectly.
I have a page - users.php
Inside this page I have a button that calls userlist.php to the innerHTML of a div.
It works just fine.
Now I have created admin.php, and using the same method, I have called users.php to a div inside admin.php.
But now the button does not call userlist.php to users.php.
So the code functions properly until it is placed inside a container on another page.
How do you make this work?
I figured it out.
The function to call userlist.php was in users.php
I moved the function to admin.php and it works perfectly.