mehmetejr Posted August 3, 2019 Posted August 3, 2019 Hi there. I have a UCP and I wanna connect SDK with it but whenever I enter credientals, I take this error (btw I am not sure how to fill SDK credientals , I need help about it as well )Fatal error: Uncaught exception 'Exception' with message 'There was a problem with the request. Ensure that the resource exists and that the name is spelled correctly.' in C:\xampp\htdocs\classes\mta_sdk.php:171 Stack trace: #0 C:\xampp\htdocs\classes\mta_sdk.php(74): mta->do_post_request('188.165.168.148', '22005', '/classes/call/_...', '') #1 C:\xampp\htdocs\classes\mta_sdk.php(225): mta->callFunction('classes', '_getPlayerCount', Array) #2 C:\xampp\htdocs\footer.php(5): Resource->call('_getPlayerCount') #3 C:\xampp\htdocs\ucp.php(12): include('C:\\xampp\\htdocs...') #4 {main} thrown in C:\xampp\htdocs\classes\mta_sdk.php on line 171
Addlibs Posted August 4, 2019 Posted August 4, 2019 This exception is thrown when the MTA's server HTTP agent returns a 404 error. This means either the resource 'classes' or the function '_getPlayerCount' doesn't exist on the server. This function is called from line 5 of footer.php which is included on line 12 of ucp.php.
mehmetejr Posted August 4, 2019 Author Posted August 4, 2019 (edited) 5 hours ago, MrTasty said: This exception is thrown when the MTA's server HTTP agent returns a 404 error. This means either the resource 'classes' or the function '_getPlayerCount' doesn't exist on the server. This function is called from line 5 of footer.php which is included on line 12 of ucp.php. well when I change the 22005 port, I don't get any errors but I cannot make connection between server and ucp... Edited August 4, 2019 by mehmetejr
Addlibs Posted August 5, 2019 Posted August 5, 2019 You don't get errors because connection failed ≠ error 404. If you're getting a 404 error (or the 'There was a problem with the request. Ensure that the resource exists and that the name is spelled correctly.' exception), it means you're connecting to a proper HTTP server (and likely the one you want to connect to). Are you sure there is a resource called 'classes' running on the server, and that it has a function called '_getPlayerCount' and that it is indeed exported for HTTP use in meta.xml?
mehmetejr Posted August 5, 2019 Author Posted August 5, 2019 (edited) 10 minutes ago, MrTasty said: You don't get errors because connection failed ≠ error 404. If you're getting a 404 error (or the 'There was a problem with the request. Ensure that the resource exists and that the name is spelled correctly.' exception), it means you're connecting to a proper HTTP server (and likely the one you want to connect to). Are you sure there is a resource called 'classes' running on the server, and that it has a function called '_getPlayerCount' and that it is indeed exported for HTTP use in meta.xml? There is a resource in the server named " usercontrolpanel ". Actually, I made the connection between servers but the problem is that I cannot click transfer icon when I change port to 80... Edited August 5, 2019 by mehmetejr
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now