Solved

mysql table with missing image field names

Posted on 2013-06-06
12
664 Views
Last Modified: 2013-06-10
I have a domain on the 1and1 server.

Two days ago I replaced some image field names because the original names were missing from the mysql database table.
After reinserting the image field names in the table I checked and found these were showing normally via the internet.

I checked today and those images are not showing on the internet and in fact the field names are missing again in the dbase table.

I checked the images are still in the /Images folder and they are there.

There are several hundred images listed in the table.

Two new records have been added recently and they both have missing (empty) imagefield entries.

The fields that are missing have a default image I wonder if this is doing something. The field missing image names are empty.

Has anyone any ideas what may be happening and how this problem can be solved?

Thank you

John Hardy
0
Comment
Question by:johnhardy
  • 5
  • 4
  • 2
  • +1
12 Comments
 
LVL 51

Expert Comment

by:Julian Hansen
ID: 39225131
Difficult without knowing more information.

I have several domains hosted at 1and1 where we have multiple tables storing image names - no problems.

The only issue we have had with images is the 1and1 server has the apache module for finding the closest name if the name requested does not match a file - so we were getting the wrong image showing because the real image had a spelling mistake and apache was finding another image as the closest match.

If data is dissappearing from your DB you need to check

a) Who has access to the db
b) Check all scripts that access the db and make sure none of them are causing the problem.
0
 

Author Comment

by:johnhardy
ID: 39225155
Thanks Julian
As far as I know I am the only person having access to the db

Previously in my own investigations some images were appearing incorrectly.
On checking I found these new images had no permission and all sorts of images were  appearing I corrected the permisssion and the correct images appeared.

Whilst updating the permissions a warning script kept appearing  Images folder as follows.
Script
https://my.1and1.co.uk/xml/config/htdocs-controlpanel-app-webresource/script/engineng.js:57
1and1 said they wouls get the engineers to correct this?
Any thoughts?
0
 
LVL 51

Accepted Solution

by:
Julian Hansen earned 300 total points
ID: 39225214
Sounds like a 1and1 problem you should take it up with them.

Bottom line data dissappears out of a database when something takes it out.

Possible culprits (in order of most likely to least likely)

1. Your code
2. Someone with access to 1and1 control panel
3. Malicious code
4. A 1and1 error

I would raise with 1and1 support
0
 

Author Comment

by:johnhardy
ID: 39225228
Thanks julian
I have raised with 1and1 and will let you know what if anything happens.
0
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 39225340
Please post a link to the URL that shows a "missing" image.  We need to see the generated HTML and the symptom as it exists in situ.

Please post the CREATE TABLE statement(s) that are in play.

Do you have access to phpMyAdmin so you can inspect the tables of the data base?
0
 

Author Comment

by:johnhardy
ID: 39225397
Hello Ray
url with missing images
https://my.1and1.co.uk/xml/config/htdocs-controlpanel-app-webresource/script/engineng.js:57

Not sure how to get CREATE TABLE statements

I used phpmyadmin on the 1and1.co.uk server  to re apply the image field names before they vanished again
0
6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

 
LVL 51

Expert Comment

by:Julian Hansen
ID: 39225406
That URL won't help us it is behind a login ....
0
 

Author Comment

by:johnhardy
ID: 39225481
Thanks Ray

but I cannot get you behind the login can I?
0
 
LVL 51

Expert Comment

by:Julian Hansen
ID: 39225781
Not without giving us the login credentials ... (don't)
0
 
LVL 108

Assisted Solution

by:Ray Paseur
Ray Paseur earned 150 total points
ID: 39226587
You can learn about SHOW CREATE TABLE here:
http://dev.mysql.com/doc/refman/5.0/en/show-create-table.html

You can learn more about how to use PHP and MySQL here (it's a good investment of both money and time):
http://www.amazon.com/PHP-MySQL-Web-Development-Edition/dp/0321833899

If there is no public-facing URL that will illustrate the problem, please consider setting one up.  We are experts but not mind readers and when we are made to guess at the symptoms, it reduces the likelihood that we will diagnose the problem.

Thanks and regards, ~Ray
0
 
LVL 15

Assisted Solution

by:Jagadishwor Dulal
Jagadishwor Dulal earned 50 total points
ID: 39227815
Two days ago I replaced some image field names because the original names were missing from the mysql database table.
After reinserting the image field names in the table I checked and found these were showing normally via the internet.

I checked today and those images are not showing on the internet and in fact the field names are missing again in the dbase table.

If your fields is right and image file is also there then check your image extension be sure that is .jpg or .JPG small letter or capital.
0
 

Author Closing Comment

by:johnhardy
ID: 39233995
Thanks everyone for being so helpful.

Eventually I found my error.
My code, Julians suggestion to rectify.

I was trying to update images where no images existed on that page.

All seems stable now so hopefully that solves the problem
Regards

John
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Suggested Solutions

Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now