News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

VM path handling issues and inconsistencies

Started by TechnoMage, July 24, 2017, 13:20:38 PM

Previous topic - Next topic

TechnoMage

Hi,

I am having some issues with my VM path handling (VM 3.2.2 and Joomla 3.6.5) and want to understand how does that work exactly.

My absolute path for the Joomla setup  is

/var/www/yvonne/data/www/harisnyacenter.sytes.net/.

Consequently I have setup both the tmp and logs paths as

/var/www/yvonne/data/www/harisnyacenter.sytes.net/logs/
/var/www/yvonne/data/www/harisnyacenter.sytes.net/tmp/


  • I have the following path setup for VM under settings templates:

        safepath=SafePathXYZ/
        assets_general_path=components/com_virtuemart/assets/
        media_category_path=images/stories/virtuemart/category/
        media_product_path=images/stories/virtuemart/product/
        media_manufacturer_path=images/stories/virtuemart/manufacturer/
        media_vendor_path=images/stories/virtuemart/vendor/
        forSale_path_thumb=images/stories/virtuemart/forSale/resized/

    Once I save the settings the folders are being created under

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/administration/

    e.g. for safepath

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/administration/SafePathXYZ/invoices.

    If I provide my absolute paths the entire folder structure is still being created under

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/administration/

    as

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/administration/var/www/yvonne/data/www/harisnyacenter.sytes.net/administration/SafePathXYZ/invoices.

    This would be fine however VM creates the keys file under

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/SafePathXYZ/keys

    which is inconsistent with the earlier folder creation. To be fair this whole functionality does not make too much sense for me.
  • In addition to this as you can see I have all my vm images under

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/images/stories/virtuemart/

    including the payment and shipment folders

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/images/stories/virtuemart/payment/
    /var/www/yvonne/data/www/harisnyacenter.sytes.net/images/stories/virtuemart/shipment/

    and all my media files are set accordingly under the settings templates (as could have seen under point 1). In spite of this I am getting errors from Joomla because for shipment and payment media files VM and Joomla looks for the images under

    /var/www/yvonne/data/www/harisnyacenter.sytes.net/images/virtuemart/payment/
    /var/www/yvonne/data/www/harisnyacenter.sytes.net/images/virtuemart/shipment/

    This again does not make too much sense for me. Why cannot one specify the path for these folders why are those hard coded if the rest can be customized.

Can someone please explain to me if I am doing something wrong or if these are just shortcomings in the current VM version?

jenkinhill

You should have updated Joomla to 3.7.3 by now, as that was a security release.  https://www.joomla.org/announcements/release-news/5709-joomla-3-7-3-release.html

J3.7 does no longer use images/stories/ by default, so VM3.2.2 is set to work with that. Instead of  images/stories/virtuemart/ it now uses  images/virtuemart/
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

TechnoMage

Thanks jenkinhill.

I had some issues with the core update that is why I have not done it in the past.

Is there an easy way to update all media paths in VM using the new standards?

Also it must be just me being stupid but if there is such a significant change it would be good to have some safeguard in the as part of the update to check first the Joomla version and don't even start the update if it is incompatible with the current core version.

I will check point 1 again using this new core later on.

jenkinhill

VM3.2.3.9579 does work with older versions.  When Joomla 3.7.x is installed on most sites the image files in the stories directory and its subdirectories are automatically moved into the images root. Image paths are automatically updated at that time.

As for safepath & keys I don't have a problem with those as the vmfiles directory is  below server root, invoices and keys are written there.
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

TechnoMage

Thanks.

All the errors were there due to Joomla 3.6.5.

Anyway it would be great to do some Joomla core version check before the update to avoid such problems.