VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: betterlead on October 25, 2015, 20:14:06 PM

Title: Synchronize media to VM brings File for x missing
Post by: betterlead on October 25, 2015, 20:14:06 PM
Hi,

When I "Synchronize media to VirtueMart" I get at least a hundred messages like this: "File for /home/livingstudio/public_html/images/stories/virtuemart/product/secrid-wallet-s-black-amazon.jpg is missing"

I understand this is both a removed product and a removed image. What is still calling for the files? Where can I find this and if possible, remove in  the database? Which table and which column?

This is significant on this site, that I have upgraded from J2.5 & VM2.5 to J3 & VM3

Cheers

My site: https://livingstudio.se
Title: Re: Synchronize media to VM brings File for x missing
Post by: Studio 42 on October 26, 2015, 02:34:35 AM
Hi,

If you removed the file, you need to remove it from the "media" list. Else you continue to get this message.'File for XXX is missing".

I know it's a pain. Perhaps some core Dev add the feature to remove media not anymore existing.

Regards,
Patrick K
Title: Re: Synchronize media to VM brings File for x missing
Post by: betterlead on October 26, 2015, 09:47:27 AM
Great! Thanks a lot Studio 42.
Yes a filtering option would be nice - one could then simply mark all missing files at once. But it was really quite simple, anyway, when I saw them all with an exclamation sign.

This leads me to next question: Do you happen to know what this message means?:

Error
vmError: COM_VIRTUEMART_URL_NOT_VALID

Thanks again - you made my day and I learned more by spin off effect.
Title: Re: Synchronize media to VM brings File for x missing
Post by: Studio 42 on October 26, 2015, 12:24:47 PM
Hi,
Quote from: betterlead on October 26, 2015, 09:47:27 AM
This leads me to next question: Do you happen to know what this message means?:

Error
vmError: COM_VIRTUEMART_URL_NOT_VALID
I have do a simple search for COM_VIRTUEMART_URL_NOT_VALID:
if (strpos ($this->file_url, '..') !== FALSE) {
$ok = FALSE;
vmError (vmText::sprintf ('COM_VIRTUEMART_URL_NOT_VALID', $this->file_url));
}

This mean that you have .. in the file url for a media.
Title: Re: Synchronize media to VM brings File for x missing
Post by: betterlead on October 26, 2015, 12:36:31 PM
Hi,

Ok, excuse my ignorance, what would be the cure?
Title: Re: Synchronize media to VM brings File for x missing
Post by: GJC Web Design on October 26, 2015, 23:21:16 PM
fix the url .. it is saying u have a double .. in the url

if u provide a text for the constant like 'non valid url:  %s'

the url should also echo out after the error message
Title: Re: Synchronize media to VM brings File for x missing
Post by: Studio 42 on October 27, 2015, 03:29:39 AM
Quote from: GJC Web Design on October 26, 2015, 23:21:16 PM
fix the url .. it is saying u have a double .. in the url

if u provide a text for the constant like 'non valid url:  %s'

the url should also echo out after the error message
he cannot see the right message (and url) because he have :
vmError: COM_VIRTUEMART_URL_NOT_VALID
this mean no language string at all.
Title: Re: Synchronize media to VM brings File for x missing
Post by: betterlead on October 27, 2015, 06:22:19 AM
Yep, true. I have searched for the constant and couldn't find it.
I'm still "out in the blue".


Skickat från min LG-H815 via Tapatalk

Title: Re: Synchronize media to VM brings File for x missing
Post by: GJC Web Design on October 27, 2015, 10:17:25 AM
Studio 42 ->  thats why I said..  if u provide a text for the constant like 'non valid url:  %s'   ::)

QuoteI have searched for the constant and couldn't find it.

then make it....
Title: Re: Synchronize media to VM brings File for x missing
Post by: betterlead on October 27, 2015, 10:18:14 AM
Ah!

Skickat från min SM-G925F via Tapatalk

Title: Re: Synchronize media to VM brings File for x missing
Post by: betterlead on October 27, 2015, 15:14:45 PM
Hmmm, I think I need help, because I still don't get it... See attached screen shot.
Title: Re: Synchronize media to VM brings File for x missing
Post by: Jörgen on October 27, 2015, 15:39:16 PM
Hello

Have You added it to both frontend and backend ?

Jörgen @ Kreativ Fotografi
Title: Re: Synchronize media to VM brings File for x missing
Post by: betterlead on October 27, 2015, 19:30:58 PM
Yes

Skickat från min LG-H815 via Tapatalk

Title: Re: Synchronize media to VM brings File for x missing
Post by: Milbo on October 27, 2015, 21:12:02 PM
Maybe you have a general path problem? I have no clue, why it should not be translated and BE language should be enough
Title: Re: Synchronize media to VM brings File for x missing
Post by: GJC Web Design on October 27, 2015, 21:38:38 PM
To add to the confusion-- in 3.0.11 components\com_virtuemart\language\en-GB\en-GB.com_virtuemart.ini I find line 521

COM_VIRTUEMART_URL_NOT_VALID="Url is not valid"

but life is too short....

just add in administrator\components\com_virtuemart\tables\medias.php ~ line 105

//vmError (vmText::sprintf ('COM_VIRTUEMART_URL_NOT_VALID', $this->file_url));
vmError ('url not valid: '.$this->file_url);
Title: Re: Synchronize media to VM brings File for x missing
Post by: Milbo on October 27, 2015, 22:30:42 PM
thx, fixed.
Title: Re: Synchronize media to VM brings File for x missing
Post by: betterlead on October 29, 2015, 10:06:41 AM
Wow! //

Thanks, "Mr Eliminator".
Title: Re: Synchronize media to VM brings File for x missing
Post by: Milbo on October 29, 2015, 19:37:41 PM
http://dev.virtuemart.net/attachments/download/975/com_virtuemart.3.0.11.2_extract_first.zip

should show now the path of the file creating the problem