Results 1 to 10 of 10
  1. #1
    Join Date
    Aug 2009
    Location
    Longs, SC
    Posts
    626
    Plugin Contributions
    2

    Default Migrating a website from Prostores

    Prostores is shutting down all their websites on Feb 1st. I'm in the process of migrating a client off of that platform and onto zencart. The one fly in the ointment seems to be the product images. Prostores loads the images to a directory that is not accessible and renames them in the process. An export of the product catalog does not contain a complete list of the images and none of what's listed reflects the location on the Prostores servers. I ran a program to scrap the images off the website but I have no wa to map it to the products. Does anybody have an idea about how to accomplish that?

  2. #2
    Join Date
    Jan 2004
    Posts
    66,444
    Plugin Contributions
    279

    Default Re: Migrating a website from Prostores

    If you've scraped the pages from the old website, doesn't the scraper database contain references to which images belong to which pages (ie: to which products)?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Aug 2009
    Location
    Longs, SC
    Posts
    626
    Plugin Contributions
    2

    Default Re: Migrating a website from Prostores

    It did in fact provide a mapping of images to the page they were on. Prostores used a weird naming convention for their pages which I may be able to take advantage of. Part of the url was .../servlet/the-xxxx/ where xxxx was apparently the product number. This seems to be the only linkage between the product export and the scraped site. I used the xxxx as the model number in zencart. Now to figure out how to build a .csv file using only the first image (there are four for each product).

  4. #4
    Join Date
    Jul 2012
    Posts
    16,816
    Plugin Contributions
    17

    Default Re: Migrating a website from Prostores

    Quote Originally Posted by badarac View Post
    It did in fact provide a mapping of images to the page they were on. Prostores used a weird naming convention for their pages which I may be able to take advantage of. Part of the url was .../servlet/the-xxxx/ where xxxx was apparently the product number. This seems to be the only linkage between the product export and the scraped site. I used the xxxx as the model number in zencart. Now to figure out how to build a .csv file using only the first image (there are four for each product).
    Not 100% sure of the status of each "site", but if the data is in ZC, then EP4 (EasyPopulate Ver 4) could be used to export the ZC information, which would include the model number in the record as well. The data could then be manipulated in the spreadsheet to possibly get the format you need to work with. Using Open Office, the file could be saved back to csv format and be "assembled" as desired.

    If the desire is to then populate the ZC version of the site with the associated path, there is an image path provided in the export of product that could be updated with the "reassembled" path from above... That path would be to the main image with all other images (the other 3) following the ZC image naming process, then all four images would appear again upon upload of that full csv. (Generic instruction provided, not each and every detail of using EP4 and the fields that may be omitted/must remain.)
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  5. #5
    Join Date
    Aug 2009
    Location
    Longs, SC
    Posts
    626
    Plugin Contributions
    2

    Default Re: Migrating a website from Prostores

    Quote Originally Posted by mc12345678 View Post
    Not 100% sure of the status of each "site", but if the data is in ZC, then EP4 (EasyPopulate Ver 4) could be used to export the ZC information, which would include the model number in the record as well.
    The site is still live at Prostores and the new Zencart site is being built on another server. I used the export function there to get their product catalog exported to a .csv file. I used EP4 to import the products into Zencart. Unfortunately Prostores does not export the actual image info in their product export or anywhere else. It included a partial record of the original image names. They store the images somewhere and rename them with a unique name for each file. I do have the location of the image files in the output of the site scrape. The scrape built the directory structure of the image files and stored the images with their name in each directory. There are four images for each product with unique names and no indiication which is the main image. The log contains a row for each page with the image file url and page url. The only thing that maps to the Prostores export is the page url which contains the sting the-xxxx where xxxx is the product number. I used their product number as the model on the import to Zencart.

    So what I need to do is read the .csv file from the PS export and the .txt file from the scrape.
    It needs to extract the product number from the scrape url www.mydomain.com/servlet/the-10143/a....
    Then build a new .csv file that contains the model number and image file name of the first image to import into ZC.
    Rename the additional images.

    They have decided to manually input the images using image handler so this is now a learning exercise for me. How would you approach this?

  6. #6
    Join Date
    Jul 2012
    Posts
    16,816
    Plugin Contributions
    17

    Default Re: Migrating a website from Prostores

    Are you trying to automate this (ie, do this type of transfer again and again) or do this sort of "one-time"?

    I can think of a couple of quickk ways to do some of the matching up and data pulling using Open Office (or Excel) if wanting to just get this one done, or possibly Access or through some phpMyAdmin database manipulation/pattern matching. Kind of depends on what the current final goal is. Also the code to this other website is not something that is open source? Possible to put into a code IDE and search for various aspects to identify how it determines the "main" picture and othe subpictures, etc?
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  7. #7
    Join Date
    Aug 2009
    Location
    Longs, SC
    Posts
    626
    Plugin Contributions
    2

    Default Re: Migrating a website from Prostores

    This is a one time thing. Prostores is not open source so you get what they give you. My original thought was to import this into access as two tables and manipulate it that way. That doesn't do anything for renaming the additional image though. My thought was to just pick the first image in the list as the main one. My other thought was to build a couple DB tables in my local WAMP environment and use some php/sql code to do it.
    Last edited by badarac; 30 Jan 2015 at 04:00 PM.

  8. #8
    Join Date
    Jul 2012
    Posts
    16,816
    Plugin Contributions
    17

    Default Re: Migrating a website from Prostores

    If you go that route, you could create a form that displays the four images, selection (by click) activates the one as the primary and deselects the others, do this page by page, and track in the database which was selected. Then on save, with that file being the primary, the others just get renamed following it's rule. Not sure the best utility to do the renaming otherwise (automatically) but, could code a filename rename using a from:to type table and a short php code to do the renaming one time if nothing else "easy" is located.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  9. #9
    Join Date
    Aug 2009
    Location
    Longs, SC
    Posts
    626
    Plugin Contributions
    2

    Default Re: Migrating a website from Prostores

    Well this will be an interesting little project for another day. They have over 2000 products so I'm certainly not going to go through one by one. Thanks for the suggestions.

  10. #10
    Join Date
    Jul 2012
    Posts
    16,816
    Plugin Contributions
    17

    Default Re: Migrating a website from Prostores

    Quote Originally Posted by badarac View Post
    Well this will be an interesting little project for another day. They have over 2000 products so I'm certainly not going to go through one by one. Thanks for the suggestions.
    Just kind of thinking of the phrase: pay me now or pay me later... May not be you to go through the 8000 images, but certainly at some point they will need to be "set right" if the first guess of the first image isn't the best... And then the images will need to be swapped around, etc... Possibly all 8000 of them... So trying to come up with a way to relatively do it right the first time and take some of the you time out of it... You've got your own things to keep doing for the site. Maybe hire someone to do the comparison and "clicking"... Time and labor intensive, but if someone has it...
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

 

 

Similar Threads

  1. migrating zen 1.2 website to a new server
    By raunharman in forum General Questions
    Replies: 1
    Last Post: 26 Sep 2009, 01:18 PM
  2. migrating a website
    By kitcorsa in forum General Questions
    Replies: 2
    Last Post: 2 May 2007, 09:47 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg