I am trying to import product records into Phoca cart (ver 4.0.ORC) and am running into problems. First of all is there any detailed documentation of the import/export functions as the online documentation is very sparse? If I can get at a more detailed discussion of the the requirements and specifications, that might allow me to solve this problem. A search of this forum did not help.
I have created upload files that are precisely structured like the export of current products (2 records). In one case the import file version is exactly the same as the export version except for a change in product price to allow me to determine that I can replace existing files; the existing product ID is part of that file; note that 'Attributes' are excluded from the export and import files. I've also created an identical file without product ID's, testing whether that would create two new records. In both cases, I am seemingly able to upload the file in question at which point it correctly identifies the number of records in the file but when I click on 'Import' nothing happens; there is no progress bar showing the process executing. Further when I go away from this screen and return to it, that file appears to still be there in a queue waiting to be processed. Clearing the caches generally doesn't help although on one try it did clear the pending import. Import files are formatted UTF-8. Is there any other way to clear such a pending file or does one simply upload a new file to do so?
For the record, Logging is enabled for all errors but no errors show up in the Phoca logs. Joomla debugging is enabled; I'm not seeing anything in the way of an obvious error there. When I look at the Chrome Console tools I do see the following output:
Failed to load resource: the server responded with a status of 500 (Internal Server Error)
DevTools failed to load source map: Could not load content for chrome-extension://pgjjikdiikihdfpoppgaidccahalehjh/webspeed.js.map: System error: net::ERR_BLOCKED_BY_CLIENT
jquery.js?3.6.0:10109 GET https://talos4.net/j4-A/administrator/i ... 1&p=1&lp=1 500 (Internal Server Error)
send @ jquery.js?3.6.0:10109
ajax @ jquery.js?3.6.0:9690
phGetNextItem @ index.php?option=com_phocacart&view=phocacartimports:199
phImportAllItems @ index.php?option=com_phocacart&view=phocacartimports:220
dispatch @ jquery.js?3.6.0:5430
elemData.handle @ jquery.js?3.6.0:5234
I have no idea what any of that means. For the record, when I look at my server's Apache Error logs I get a bunch of errors like this:
[cgi:error] [pid 4558] [client 98.237.88.222:42096] AH01215: php7.4.cgi: line 2: ulimit: max user processes: cannot modify limit: Operation not permitted: /home/talos4n/public_html/cgi-bin/php7.4.cgi, referer: https://talos4.net/j4-A/administrator/i ... artimports
While I could be wrong I don't think my ulimit parameters are wrong on this server and is probably a result of some other underlying problem. Could this be a permission issue in the folder where the file is uploaded. It would be nice to know where that folder is!
Can anyone help me on this. Just more detailed documentation would be a good place to start.
Import Does Not Work
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Import Does Not Work
Hi, first you need to find which error is stopping you:
- if the error occurs before the importing (e.g. in AJAX - some javascript error)
- or then on server.
500 mostly means a PHP error, so this seems to be some error on server (probably PHP) - but if you get 500 error, you even should get information in log (php error log on your server: https://www.phoca.cz/documents/16-jooml ... rs-on-site or directly in the site - if this happens in AJAX, you should get it in AJAX)
I would recommend to use this debug tool as it can even stop and display the PHP errors inside AJAXes:
https://bitbucket.org/n3t/n3t-debug/downloads/
Regarding max user processes error on your server, hard to say what error this exactly is, this is maybe much more a question on server hosting Is this the error which is last and stops the script when importing?
Jan
- if the error occurs before the importing (e.g. in AJAX - some javascript error)
- or then on server.
500 mostly means a PHP error, so this seems to be some error on server (probably PHP) - but if you get 500 error, you even should get information in log (php error log on your server: https://www.phoca.cz/documents/16-jooml ... rs-on-site or directly in the site - if this happens in AJAX, you should get it in AJAX)
I would recommend to use this debug tool as it can even stop and display the PHP errors inside AJAXes:
https://bitbucket.org/n3t/n3t-debug/downloads/
Regarding max user processes error on your server, hard to say what error this exactly is, this is maybe much more a question on server hosting Is this the error which is last and stops the script when importing?
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Member
- Posts: 28
- Joined: 07 Mar 2022, 20:30
Re: Import Does Not Work
I got some error output as a result of the debug app you referenced. To save time I put the images of two sets of errors on my own website. I also included the raw CSV files associated with each message on that page. Both errors appear identical however. The error is entitled 'Product must have a title' but you can clearly see from the CSV files that both title and alias fields have data.
https://talos4.net/j4-A/index.php/phoca-cart/article-2
https://talos4.net/j4-A/index.php/phoca-cart/article-2
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Import Does Not Work
Hmmm, testing now CSV, without any problem. Are you able to reexport the products to other format - to XML - to test if you get the same problem?
Jan
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Member
- Posts: 28
- Joined: 07 Mar 2022, 20:30
Re: Import Does Not Work
I just did as you suggested. I changed the export format from CSV to XML, exported my existing products (all two of them as per the prior CSV files), then turned around and imported that exact file. When I click on the download part of that dialog nothing happens - no progress bar showing the download process.
The only thing I can think to do next, unless you have another suggestion, is to install a new and totally clean Joomla 4 account (although this one is pretty clean), install PhocaCart and try this again. That might take a day or two to get to.
The only thing I can think to do next, unless you have another suggestion, is to install a new and totally clean Joomla 4 account (although this one is pretty clean), install PhocaCart and try this again. That might take a day or two to get to.
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Import Does Not Work
Hi, when tere is no response, the problem can be related to some Javascript error - did you check the Javascript console?
Jan
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Member
- Posts: 28
- Joined: 07 Mar 2022, 20:30
Re: Import Does Not Work
From clean Joomla 4 install. Only updated Joomla to latest version and installed PhocaCart + modules + n3tdebug.
n3tdebug output (my default browser is Brave/Chrome) was exactly the same as previously referenced.
From Brave Developer Tools/Console after attempted import:
Uncaught TypeError: Cannot read properties of undefined (reading 'split')
at getCookie (/j4-B/media/templates/administrator/atum/js/template.js?74e5d2f17741fe5ca18d9ac3b7ef2969:9:127)
at setDesktop (/j4-B/media/templates/administrator/atum/js/template.js?74e5d2f17741fe5ca18d9ac3b7ef2969:180:16)
at /j4-B/media/templates/administrator/atum/js/template.js?74e5d2f17741fe5ca18d9ac3b7ef2969:200:7
DevTools failed to load source map: Could not load content for chrome-extension://pgjjikdiikihdfpoppgaidccahalehjh/webspeed.js.map: System error: net::ERR_BLOCKED_BY_CLIENT
From FireFox Console after trying to execute Import:
Error in parsing value for ‘-webkit-text-size-adjust’. Declaration dropped. template.css:110:29
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2247:15
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2251:15
Unknown pseudo-class or pseudo-element ‘-moz-focus-outer’. Ruleset ignored due to bad selector. template.css:2613:13
Ruleset ignored due to bad selector. template.css:2634:35
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2722:32
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2725:32
Unknown pseudo-class or pseudo-element ‘-moz-placeholder-shown’. Ruleset ignored due to bad selector. template.css:2731:37
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2735:37
Unknown pseudo-class or pseudo-element ‘-moz-placeholder-shown’. Ruleset ignored due to bad selector. template.css:2751:37
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2755:37
On a clean install none of this makes sense. I run a dozen Joomla 3 installations at present with no issues and these two J4 apps; I realize J4 is a big change in the codebse. For the record all my permissions are at normal defaults.
n3tdebug output (my default browser is Brave/Chrome) was exactly the same as previously referenced.
From Brave Developer Tools/Console after attempted import:
Uncaught TypeError: Cannot read properties of undefined (reading 'split')
at getCookie (/j4-B/media/templates/administrator/atum/js/template.js?74e5d2f17741fe5ca18d9ac3b7ef2969:9:127)
at setDesktop (/j4-B/media/templates/administrator/atum/js/template.js?74e5d2f17741fe5ca18d9ac3b7ef2969:180:16)
at /j4-B/media/templates/administrator/atum/js/template.js?74e5d2f17741fe5ca18d9ac3b7ef2969:200:7
DevTools failed to load source map: Could not load content for chrome-extension://pgjjikdiikihdfpoppgaidccahalehjh/webspeed.js.map: System error: net::ERR_BLOCKED_BY_CLIENT
From FireFox Console after trying to execute Import:
Error in parsing value for ‘-webkit-text-size-adjust’. Declaration dropped. template.css:110:29
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2247:15
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2251:15
Unknown pseudo-class or pseudo-element ‘-moz-focus-outer’. Ruleset ignored due to bad selector. template.css:2613:13
Ruleset ignored due to bad selector. template.css:2634:35
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2722:32
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2725:32
Unknown pseudo-class or pseudo-element ‘-moz-placeholder-shown’. Ruleset ignored due to bad selector. template.css:2731:37
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2735:37
Unknown pseudo-class or pseudo-element ‘-moz-placeholder-shown’. Ruleset ignored due to bad selector. template.css:2751:37
Unknown pseudo-class or pseudo-element ‘-ms-input-placeholder’. Ruleset ignored due to bad selector. template.css:2755:37
On a clean install none of this makes sense. I run a dozen Joomla 3 installations at present with no issues and these two J4 apps; I realize J4 is a big change in the codebse. For the record all my permissions are at normal defaults.
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Import Does Not Work
Are you able to somehow fix the first "Uncaught TypeError". It can cause (but does not have to) not working of the AJAX
Jan
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Member
- Posts: 28
- Joined: 07 Mar 2022, 20:30
Re: Import Does Not Work
I have no idea how to do that. Considering that this has happened on two different sites, I think I'm at the end of the road trying to solve this unless you have something more specific to suggest that I can do.
- Jan
- Phoca Hero
- Posts: 48402
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Import Does Not Work
As this errors comes from Atum template, maybe try to ask on forum.oomlacode.org if there is someone who can help with this error
Because now we really need to know what happens when this error ( Uncaught TypeError: Cannot read properties of undefined (reading 'split') ) does not exist. This error can influence it.
Because now we really need to know what happens when this error ( Uncaught TypeError: Cannot read properties of undefined (reading 'split') ) does not exist. This error can influence it.
If you find Phoca extensions useful, please support the project