Page 1 of 1

ES3Cloud.php problem

Posted: Mon Feb 24, 2020 4:29 am
by dafar
Hi,
When running ES3Cloud.php I got this message:

" Couldn't create PHP file on your server. This could be because file_put_contents is not supported on your server, or you do not have permission to write files to this folder on your server.

To manually install the PHP file, please create a file named ES3Variables.php in the same directory as your ES3.php file with the following contents:

After creating this file, installation will be complete."


It created a table named es3cloud only.
I checked the ES2SQL and saw different tables.. I don't know if it changed. I added them just in case.

But I don't know what to put inside the ES3Variables.php that I need to create manually.
Can you help, please?

Re: ES3Cloud.php problem

Posted: Mon Feb 24, 2020 4:57 am
by dafar
Hi,

I found this on the forum:

Code: Select all

<?php
$api_key        =   'yourNewAPIKey';        // The API key you need to specify to use when accessing this API.
$db_host      =   '0.0.0.0';          // MySQL Host Name.
$db_user     =   'user';             // MySQL User Name.
$db_password =   'pass';             // MySQL Password.
$db_name      =   'database';         // MySQL Database Name.
?>
I put the same Key that I found in the AutoSave - Settings for Current Scene menu of ES3 window inside Unity.
Is this the correct one? Or should be a different Key?
If I reload the ES3Cloud.php from the server it says that the key is invalid.

Re: ES3Cloud.php problem

Posted: Mon Feb 24, 2020 7:50 am
by Joel
Hi there,

The API key should be a random string of letters and numbers. You then use this API key as the apiKey parameter when calling the ES3Cloud methods.

You won't be able to access the ES3Cloud.php directly from a browser because the authentication data won't be sent.

All the best,
Joel

Re: ES3Cloud.php problem

Posted: Mon Feb 24, 2020 2:30 pm
by dafar
Thanks, Joel.

Where can I find examples of codes using CRUD to/from mysql?

I was learning how to do it manually, but decided to give your plugin a try.

I did a login system where I'm keeping the userID and e-mail inside the c#.

Is it possible to get the data from the MYSQL only using the email or userID? Do I always need to send userID and password via C# (I still don't have a clue how)?

thanks,
Daniel

Re: ES3Cloud.php problem

Posted: Mon Feb 24, 2020 5:49 pm
by Joel
Hi Daniel,

You can find examples in the ES3Cloud guide and for each of the ES3Cloud methods in the API.

The password is optional so you can leave it blank if necessary.

All the best,
Joel

Re: ES3Cloud.php problem

Posted: Thu Jun 09, 2022 10:09 am
by Krakentanz
Just a bit of clarification for other users that were puzzeled like i was

The Console-Output states: "make a file next to the ES3.php file"

What it really means is "make a file next to the ES3Cloud.php file"

Re: ES3Cloud.php problem

Posted: Thu Jun 09, 2022 4:39 pm
by Joel
Krakentanz wrote: Thu Jun 09, 2022 10:09 am Just a bit of clarification for other users that were puzzeled like i was

The Console-Output states: "make a file next to the ES3.php file"

What it really means is "make a file next to the ES3Cloud.php file"
Thanks for the clarification, looks like it wasn't updated when we changed the name of the file from ES3.php to ES3Cloud.php, so I'll get this changed.

All the best,
Joel