Jump to content

Admin Script Error


ayz1

Recommended Posts

When in admin editing a product the browser hangs for a few seconds and I get a script error. The store has about 8000 products. I've tried lading Firefox in safe mode but get the same error message. Hangs in other browsers as well. Anyone having the same problem or know a fix?

I've seen this post but not sure if related or is still relevant.

 

script.jpg

Link to comment
Share on other sites

I see this from time to time as well, and we have about half as many products as you. We may have more images than you, however. I have seen it on other websites, as well.

Try using Firebug and watch the Net processes and see what the waterfall shows.

Link to comment
Share on other sites

When bringing a product up for editing, CubeCart uses the AJAX functionality of jQuery to fetch a listing of all images (to allow for the assigning of images to the product) and again to fetch a listing of all digital files (to allow for the assigning of a file to make this product a digital download).

Due to a minor programming mistake, CubeCart will also fetch a second and a third entire Add/Edit product page via those two AJAX calls.

In my internal development environment, all this still takes about six seconds for the page to become usable.

Add to this the latency incurred with a less than blazingly fast internet connection, fetching perhaps 8000 image filenames (not the actual images, and this would be not as time consuming if the 8000 images were managed in categorized folders), and a couple of other considerations, the browser comes to realize that the AJAX function is taking way too long - maybe it has become unresponsive (infinite loop, etc).

Depending on the browser, you may be able to check the box "Do not ask again" and "Continue", such that the browser will always remember to keep the script running if this should ever happen again.

 

Link to comment
Share on other sites

Again, to be clear, it is the extra full-page requests that add unnecessary work to the process. There will still be the work of getting the list of images and digital files -- that won't change -- and having the images managed in folders will keep the initial amount of that work to a minimum.

Link to comment
Share on other sites

If an image(s) apply to only a specific product, and that product is no longer visible on the storefront, then in File Manager, create a folder named "notavailable" and move those images into it.

CubeCart fetches image filenames one folder at a time -- starting with the root image folder. As you click on image sub-folder icons, then that is when a separate and distinct AJAX request for the list of filenames happen.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...