Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Export/import doesn’t work
 
benruco
Jr. Member
 
Total Posts:  2
Joined:  2007-11-14
 

tried the same thing with xml and it doesn’t work either..

Warning: DOMDocument::loadXML() [function.DOMDocument-loadXML]: Opening and ending tag mismatch: br line 6 and Data in Entity, line: 9 in /homepages/0/d89499280/htdocs/bark/mail/magento/lib/Varien/Convert/Parser/Xml/Excel.php on line 35
[0] in DOMDocument->loadXML(”
/homepages/0/d89499280/htdocs/bark/mail/magento/lib/Varien/Convert/Parser/Xml/Excel.php on line 35
[1] in Varien_Convert_Parser_Xml_Excel->parse() in /homepages/0/d89499280/htdocs/bark/mail/magento/lib/Varien/Convert/Action/Abstract.php on line 181
[2] in Varien_Convert_Action_Abstract->run() in /homepages/0/d89499280/htdocs/bark/mail/magento/lib/Varien/Convert/Profile/Abstract.php on line 110
[3] in Varien_Convert_Profile_Abstract->run() in /homepages/0/d89499280/htdocs/bark/mail/magento/app/code/core/Mage/Core/Model/Convert/Profile.php on line 78
[4] in Mage_Core_Model_Convert_Profile->run() in /homepages/0/d89499280/htdocs/bark/mail/magento/app/code/core/Mage/Adminhtml/Block/System/Convert/Profile/Run.php on line 64
[5] in Mage_Adminhtml_Block_System_Convert_Profile_Run->toHtml() in /homepages/0/d89499280/htdocs/bark/mail/magento/app/code/core/Mage/Adminhtml/controllers/System/Convert/ProfileController.php on line 182
[6] in Mage_Adminhtml_System_Convert_ProfileController->runAction() in /homepages/0/d89499280/htdocs/bark/mail/magento/app/code/core/Mage/Core/Controller/Varien/Action.php on line 336
[7] in Mage_Core_Controller_Varien_Action->dispatch("run") in /homepages/0/d89499280/htdocs/bark/mail/magento/app/code/core/Mage/Core/Controller/Varien/Router/Admin.php on line 141
[8] in Mage_Core_Controller_Varien_Router_Admin->match(Mage_Core_Controller_Request_Http) in /homepages/0/d89499280/htdocs/bark/mail/magento/app/code/core/Mage/Core/Controller/Varien/Front.php on line 147
[9] in Mage_Core_Controller_Varien_Front->dispatch() in /homepages/0/d89499280/htdocs/bark/mail/magento/app/Mage.php on line 379
[10] in Mage::run("base") in /homepages/0/d89499280/htdocs/bark/mail/magento/index.php on line 29

 
Magento Community Magento Community
Magento Community
Magento Community
 
jeanlucb
Member
 
Total Posts:  60
Joined:  2008-02-10
 

same problem !

 
Magento Community Magento Community
Magento Community
Magento Community
 
Hunor
Jr. Member
 
Total Posts:  1
Joined:  2008-04-04
 

I want to export all my products and I get :

Warning: is_dir() [function.is-dir]: open_basedir restriction in effect. File(/home) is not within the allowed path(s): (/home/itdepo/:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/itdepo/public_html/magento/magento/lib/Varien/Io/File.php on line 443
[0] in is_dir("/home") in /home/itdepo/public_html/magento/magento/lib/Varien/Io/File.php on line 443
[1] in Varien_Io_File->_createDestinationFolder("/home/itdepo/public_html/magento/magento/var/tmp/") in /home/itdepo/public_html/magento/magento/lib/Varien/Io/File.php on line 205
[2] in Varien_Io_File->open(Array[1]) in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Dataflow/Model/Batch/Io.php on line 134
[3] in Mage_Dataflow_Model_Batch_Io->open() in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Dataflow/Model/Convert/Parser/Xml/Excel.php on line 343
[4] in Mage_Dataflow_Model_Convert_Parser_Xml_Excel->unparse(Array[0]) in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Dataflow/Model/Convert/Action/Abstract.php on line 235
[5] in Mage_Dataflow_Model_Convert_Action_Abstract->run() in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Dataflow/Model/Convert/Profile/Abstract.php on line 132
[6] in Mage_Dataflow_Model_Convert_Profile_Abstract->run() in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Dataflow/Model/Profile.php on line 142
[7] in Mage_Dataflow_Model_Profile->run() in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Adminhtml/Block/System/Convert/Profile/Run.php on line 73
[8] in Mage_Adminhtml_Block_System_Convert_Profile_Run->_toHtml() in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Core/Block/Abstract.php on line 553
[9] in Mage_Core_Block_Abstract->toHtml() in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Adminhtml/controllers/System/Convert/ProfileController.php on line 189
[10] in Mage_Adminhtml_System_Convert_ProfileController->runAction() in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Core/Controller/Varien/Action.php on line 341
[11] in Mage_Core_Controller_Varien_Action->dispatch("run") in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Core/Controller/Varien/Router/Admin.php on line 141
[12] in Mage_Core_Controller_Varien_Router_Admin->match(Mage_Core_Controller_Request_Http) in /home/itdepo/public_html/magento/magento/app/code/core/Mage/Core/Controller/Varien/Front.php on line 147
[13] in Mage_Core_Controller_Varien_Front->dispatch() in /home/itdepo/public_html/magento/magento/app/Mage.php on line 424
[14] in Mage::run("default") in /home/itdepo/public_html/magento/magento/index.php on line 40

Unable to create directory ‘/home’. Access forbidden.

Any ideeas? I get this error when I try to export it on a remote ftp server. :(

 
Magento Community Magento Community
Magento Community
Magento Community
 
MunchyMonster
Member
 
Avatar
Total Posts:  71
Joined:  2008-02-05
New Hampshire, USA
 

Alright so I did a little digging around to see what I could figure out. If someone more familiar with PHP and/or web servers could pipe in with some explanations to fill in the holes I’d much appreciate it.

Fortunately when things go awry you get a nice neat call stack. I dug around and used one of the oldest tricks in the book… I put a bunch of print statements all over the code following the call stack that I had from the error that was being reported. Now I can’t imagine how checking to see if the string “/home” is a directory or not would cause a security breach, but apparently open_basedir just won’t let you do anything with it at all.

For some reason (which may make perfect sense to a PHP coder) a function (_createDestinationFolder) in lib/varien/io/file.php takes the path that is passed into the open command and tries to take it apart then put it back together again bit by bit. Like I said I don’t get why but this is what it is doing. So A path like /home/my_dir/public_html/my_magento_dir/var/export is ripped into and array (home, my_dir,public_html,my_magento_dir,var,export) and then it rebuilds the path starting with the string “/” and tacking on each piece of the array until it can actually open the directory or make the directory it needs. It all seems rather silly. The problem is that the /home directory is typically not open to the general public on a server. The lowest level directory open to a user on the server is /home/my_dir.

So I added a check to see if we are trying to take a peek at /home. If we are I simply tell the code to move along nothing to see here and try again. Since the next loop slaps on the my_dir to the /home, making /home/my_dir we are back to a happy place (at least on my server) and we can continue.

Add this code around line 442 in the function _createDestinationFolder in the file lib/varien/io/file.php:

if($newPath === "/home"{
$oldPath 
$newPath;
continue; 
}

That allowed me to export products and customers. It’s late again and I’m going to bed. I’ll tackle import tomorrow.  Hope this info helps someone.

MunchyMonster

 
Magento Community Magento Community
Magento Community
Magento Community
 
Spek
Sr. Member
 
Total Posts:  77
Joined:  2007-11-28
 

Nice Munchy! The problem will be resolved in the new version coming out this/next week though.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Rich
Jr. Member
 
Avatar
Total Posts:  21
Joined:  2008-01-29
London
 

Thanks for sharing that work-around MunchyMonster - nice one.

 
Magento Community Magento Community
Magento Community
Magento Community
 
sdb
Sr. Member
 
Avatar
Total Posts:  223
Joined:  2007-11-13
coastal California, USA
 

that workaround doesn’t work for me, as my host has a different directory structure, something like this
/home(restricted directory)/someone(user)/domains/straightdown2.com/public_html/shop/lib/Varien/Io/File.php

any thoughts?

 
Magento Community Magento Community
Magento Community
Magento Community
 
Spek
Sr. Member
 
Total Posts:  77
Joined:  2007-11-28
 

That bug should be fixed in the latest release sdb, are you still using 1.0?

 
Magento Community Magento Community
Magento Community
Magento Community
 
DerekHJ
Jr. Member
 
Total Posts:  3
Joined:  2008-05-03
 

Export Error

Hoping some one can help,

I have read many of the posts on this subject but still can’t find a resolution to my export problem. I have the latest install as of 08 May 2008. I have set up my category, and a test product, yet when I try to export it i receive the following:-

Starting profile execution, please wait…
Warning: Please don’t close window during importing/exporting data
Starting Mage_Catalog_Model_Convert_Adapter_Product :: load
Loaded 1 records
Starting Mage_Catalog_Model_Convert_Parser_Product :: unparse
Starting Mage_Dataflow_Model_Convert_Mapper_Column :: map
Starting Mage_Dataflow_Model_Convert_Parser_Xml_Excel :: unparse
Error write to file batch_10.tmp
Finished profile execution

and nothing happens I’m really not keen on changing security settings which appears to be an option, but don’t think I can do it anyway and would imagine that my host is not to keen either.

I have checked all of the read/write permission and everything seems ok there

I am really hoping I am just missing something and not going to have to wait for the next update.....

thanks in advance for any help…

 
Magento Community Magento Community
Magento Community
Magento Community
 
magpieradio
Jr. Member
 
Total Posts:  30
Joined:  2008-04-27
 

I too have the same error.

I re-installed from scratch and not only is the export F***ed up but
now none of the catalog images are showing up.

All the banner images, icons are all t here, just the catalog
product images are not displaying.

I must say I have tried dozens of e-commerce packages and the
fault of EVERY one including Magento is basically too many features
and not enough testing.

Wouldn’t it be a revelation if ONE of these products actually worked?

 
Magento Community Magento Community
Magento Community
Magento Community
 
bmanwithab
Jr. Member
 
Avatar
Total Posts:  5
Joined:  2008-08-06
Dallas, Texas
 

I am having issues exporting ANYTHING.  I don’t get any errors, the status bar in both IE and Firefox both just say transferring then DONE after about 1 minute.  I go and check the var/export folder and no new file.  However, when I use the same profile and put anything in the sku filter at the bottom, i get an export then.  I need ALL the products, not just a few at a time.  I have 1000+ products on there.  I am using Magento 1.1.2 on 1and1 servers.  I have done this a few weeks ago but now it doesn’t want to work.  I need to export to change prices in a large qty at a time.  If anyone has a better idea it would be much appreciated.  Thanks.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Hodgejr
Jr. Member
 
Total Posts:  12
Joined:  2008-08-18
 

Bump - export not working for me at all either.  Do I have to set permissions for this work? 
I’m using 755 for folders, 644 for all files.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Tonitobleroni
Member
 
Total Posts:  40
Joined:  2008-10-17
 
DerekHJ - 09 May 2008 11:43 AM

Export Error


Hoping some one can help,

I have read many of the posts on this subject but still can’t find a resolution to my export problem. I have the latest install as of 08 May 2008. I have set up my category, and a test product, yet when I try to export it i receive the following:-

Starting profile execution, please wait…
Warning: Please don’t close window during importing/exporting data
Starting Mage_Catalog_Model_Convert_Adapter_Product :: load
Loaded 1 records
Starting Mage_Catalog_Model_Convert_Parser_Product :: unparse
Starting Mage_Dataflow_Model_Convert_Mapper_Column :: map
Starting Mage_Dataflow_Model_Convert_Parser_Xml_Excel :: unparse
Error write to file batch_10.tmp
Finished profile execution

and nothing happens I’m really not keen on changing security settings which appears to be an option, but don’t think I can do it anyway and would imagine that my host is not to keen either.

I have checked all of the read/write permission and everything seems ok there

I am really hoping I am just missing something and not going to have to wait for the next update.....


thanks in advance for any help…

Did you solve this problem by now? I read elsewhere in this topic a user filled in SKU and then had success. This appeared to work for me as well. I still have some problems with the export, but this particular error disappeared and at least I found a file in the export folder.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Tonitobleroni
Member
 
Total Posts:  40
Joined:  2008-10-17
 
Hodgejr - 05 September 2008 11:50 AM

Bump - export not working for me at all either.  Do I have to set permissions for this work? 
I’m using 755 for folders, 644 for all files.

Yes you need permissions. I think you should CHmod the var folder and everything in it to 777.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Tonitobleroni
Member
 
Total Posts:  40
Joined:  2008-10-17
 

BTW: The problems I encountered when trying to export and imports files, did not disappear by setting permissions to 777 or 755. Finally, with kind help from a member, I discovered it had to do with the host having enabled Safe Mode on the server. As soon as the host disabled Safe Mode, all the errors I encountered before (such as when trying to use Downloader and uploading images) disappeared. BTW: I deleted all my Magento files first and did a fresh re-install.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top