MySQL export to website with driver 5.6

Discussions about Diving Log 6.0 - questions and hints
Post Reply
mdonkersloot
Posts: 21
Joined: Thu Jun 01, 2017 12:21
Location: Spijkenisse
Contact:

MySQL export to website with driver 5.6

Post by mdonkersloot »

Hello,

i'm brand new here and experimenting with sending my database direct to MySQL on my website.
My website admin tells me they use Driver 5.6 and i can only select 5.1.
I totally get no information in my database.

Am i doing something wrong i use the right credentials in the xport, but no idea if i need to change something else ot drivers are incompatible.

i hope someone can help.

tried to look for the error but MySQL gives statement to many hits so i need to look through everything manually

Regards
Marco
divinglog
Site Admin
Posts: 5768
Joined: Sat Feb 08, 2003 21:02
Location: Coburg
Contact:

Re: MySQL export to website with driver 5.6

Post by divinglog »

Hi Marco

Sorry for the late response, I've missed your post! It's a long time I've been working on this code, but I think the version is only relevant for the ODBC driver on your PC, not the MySQL server version. You can download the ODBC driver from here:

Version 5.1
Version 3.51

Kind regards,
Sven
mdonkersloot
Posts: 21
Joined: Thu Jun 01, 2017 12:21
Location: Spijkenisse
Contact:

Re: MySQL export to website with driver 5.6

Post by mdonkersloot »

Hi Sven,

to many posts so i can understand.

I installed the 5.1 ODBC version and when i upload something flies by, to fast to read, but nothing arrives.
I have a test MySQL DB and when import manually then it arrives (having other issues, but that is a next step)

Is there something as a log for the attempt to upload.

the MySQL DB can be accessed externally.

BTW, is it also possible to change the MySQL upload details if you change user as i have two users, but now i need to change the database and user login every time i want to upload. I don't know if i can mix users details in the same database, but i think not (sorry very green with this)
divinglog
Site Admin
Posts: 5768
Joined: Sat Feb 08, 2003 21:02
Location: Coburg
Contact:

Re: MySQL export to website with driver 5.6

Post by divinglog »

Hi Marco

Thank you for your detailed description! I've found a bug that prevents an error message dialog to show up, if there is any problem with the upload. Please download this update and extract (unzip) it into the Diving Log 6.0 program folder.

Then try the upload again. If there is any problem, you should see now an error message with more details about the problem.

Please note that some web servers do not allow access to the MySQL database from the outside or they require a different server address than the internal one which you're using in PHP files.
BTW, is it also possible to change the MySQL upload details if you change user as i have two users, but now i need to change the database and user login every time i want to upload. I don't know if i can mix users details in the same database, but i think not (sorry very green with this)
Unfortunately there is currently no way to change the MySQL settings automatically when you switch the logbook files. You could change just the table name prefix and store both logbooks in the same MySQL database on the server, just with different table name prefixes. I will add a way to store certain settings directly in the logbook database in the future.

Kind regards,
Sven
mdonkersloot
Posts: 21
Joined: Thu Jun 01, 2017 12:21
Location: Spijkenisse
Contact:

Re: MySQL export to website with driver 5.6

Post by mdonkersloot »

Hi Sven

The update worked perfect i saw it was still having issues with the ODBC driver.
I first installed only 64 bits 5.1.x. Now i installed both 32 and 64 bits and it works perfect in sending the data

About 2 users you told me "different table name prefixes", this means probably manually editing of the file before uploading with phpadmin. if this is is how i think you mean it then it would be much more work then two databases. And i will keep it with different databases.

Can you please confirm that my thoughts are right:)

Regards
Marco
divinglog
Site Admin
Posts: 5768
Joined: Sat Feb 08, 2003 21:02
Location: Coburg
Contact:

Re: MySQL export to website with driver 5.6

Post by divinglog »

Hi Marco

Thank you, I'm glad you got it working! With "Table Prefrix" I mean this setting:

Image1.png
Image1.png (13.01 KiB) Viewed 8961 times

Instead of DL_ you could use the initials of the user names, e.g. AB_ and CD_ to differenciate the table names and store the data in one database. Thus you only have to edit one setting field between uploads.

Kind regards,
Sven
mdonkersloot
Posts: 21
Joined: Thu Jun 01, 2017 12:21
Location: Spijkenisse
Contact:

Re: MySQL export to website with driver 5.6

Post by mdonkersloot »

Hi Sven,

Again many thanks for the help.

Will work with that.
Still need to figure out phpDivinglog before i will play with the entries in the database like this as that will be mutliple users i guess

My site still doesn't show the database and all kinds of errors, so that is my next task

http://donkersloot-duiken.nl
divinglog
Site Admin
Posts: 5768
Joined: Sat Feb 08, 2003 21:02
Location: Coburg
Contact:

Re: MySQL export to website with driver 5.6

Post by divinglog »

Hi Marco
Table 'qb210257_DL_MARCO.Logbook' doesn't exist
Please make sure a table "Logbook" exists in your MySQL database. When you configured a table prefix, the table name is not "Logbook", but "DL_Logbook" for example (or whatever prefix you've setup in the expot dialog settings). You may also have to configure the table prefix in the phpDivingLog config file.

So from the error message, please make sure your database really looks like that in phpMyAdmin:

Database name: qb210257_DL_MARCO
Table name: Logbook

Please make sure the table_prefix in the config.inc.php file matches the one in the settings dialog above:

Image1.png
Image1.png (31.04 KiB) Viewed 8916 times
mdonkersloot
Posts: 21
Joined: Thu Jun 01, 2017 12:21
Location: Spijkenisse
Contact:

Re: MySQL export to website with driver 5.6

Post by mdonkersloot »

Hi Sven

Many thanks for this, i will give it a test and come back with the reply i hope i do it correct and get it fixed :)
mdonkersloot
Posts: 21
Joined: Thu Jun 01, 2017 12:21
Location: Spijkenisse
Contact:

Re: MySQL export to website with driver 5.6

Post by mdonkersloot »

Hi Sven,

it worked and it's now showing the information

again thanks for the help and guidance

http://www.donkersloot-duiken.nl/marco/
http://www.donkersloot-duiken.nl/amber/

Still have some error lines i will lookup to see if i can remove those from the forum.
Also issue when i press a dive to see more details and the images from my dive equipment.
Probably something i'm still doing wrong

regards
Marco
divinglog
Site Admin
Posts: 5768
Joined: Sat Feb 08, 2003 21:02
Location: Coburg
Contact:

Re: MySQL export to website with driver 5.6

Post by divinglog »

Hi Marco

The error messages seem to be related to the webserver configuration. When you Google for "php Strict Standards" you find some results. Unfortunately I'm not PHP expert, so I can't say what could be the reason.

When clicking on a row to see the details, the sub folder "Marco" or "Amber" seems to get lost in the URL somehow:

Image1.png
Image1.png (6.51 KiB) Viewed 8904 times

Once you fix the URL manually, the data is displayed:

Image2.png
Image2.png (22.07 KiB) Viewed 8901 times
mdonkersloot
Posts: 21
Joined: Thu Jun 01, 2017 12:21
Location: Spijkenisse
Contact:

Re: MySQL export to website with driver 5.6

Post by mdonkersloot »

Hi Sven,

Many thanks again for helping and spending time with this noob :)

it seems i used
$_config['web_root'] = 'http://www.donkersloot-duiken.nl/';
$_config['abs_url_path'] = '/amber';

this gives http://www.donkersloot-duiken.nl//amber

i changed
$_config['web_root'] = 'http://www.donkersloot-duiken.nl';

and that works now.

Strange thing is now i only see alot " should not be called statically" will investigate that and if i press a dive then i drop from
http://www.donkersloot-duiken.nl/amber to the main site http://www.donkersloot-duiken.nl/index.php/4.

What am i still doing wrong?

Also i'm probably doing something wrong in exporting the images as those aren't shown neither

Regards
Marco
Post Reply