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

Help: Export products with html in fields
 
raul 78
Jr. Member
 
Total Posts:  17
Joined:  2008-12-03
 

i’ve the same problem have u resolved? tnks

 
Magento Community Magento Community
Magento Community
Magento Community
 
studio2f
Member
 
Total Posts:  43
Joined:  2008-11-19
 

Unfortunately I don’t have a solution yet… you can import products with HTML into Magento you just can’t export them… so I guess I need to parse the export to convert the entities back into HTML with something like Perl… I wish there was an easier way.

 
Magento Community Magento Community
Magento Community
Magento Community
 
raul 78
Jr. Member
 
Total Posts:  17
Joined:  2008-12-03
 

is there any solution by webservices?

 
Magento Community Magento Community
Magento Community
Magento Community
 
jsamedi
Jr. Member
 
Total Posts:  24
Joined:  2007-08-31
 

I’m interested too if there is any solution

 
Magento Community Magento Community
Magento Community
Magento Community
 
studio2f
Member
 
Total Posts:  43
Joined:  2008-11-19
 

Anyone have a fix yet?

 
Magento Community Magento Community
Magento Community
Magento Community
 
jsamedi
Jr. Member
 
Total Posts:  24
Joined:  2007-08-31
 

No fix. But what i do to avoid the problem is to delete the descriptions columns when updating prices for instance ...

I guess Varien is now more into the enterprise version. I’m starting to think that migrating to Magento was not such a good idea .. there is a clear lack of support ...

 
Magento Community Magento Community
Magento Community
Magento Community
 
mpikounis
Member
 
Total Posts:  67
Joined:  2009-01-26
Athens, Greece
 

What you can do is export to XML and then before editing the file with Excel open it with notepad and replace all occurrences of

&

with

&

Then save and open with Excel. All your HTML is preserved and you can import back to magento.

 
Magento Community Magento Community
Magento Community
Magento Community
 
merchantguru
Sr. Member
 
Avatar
Total Posts:  133
Joined:  2008-10-05
San Francisco
 

Checking to see if anyone has come up with a new solution in the past year. 1.4.1 has the same issue.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Alexander Pervak
Jr. Member
 
Total Posts:  24
Joined:  2009-09-15
Kiev
 

Magento guys, are you here? We really need this feature.

 
Magento Community Magento Community
Magento Community
Magento Community
 
merchantguru
Sr. Member
 
Avatar
Total Posts:  133
Joined:  2008-10-05
San Francisco
 

What I do now is to export the file into csv, using backticks ( ` )to enclose fields and commas to separate fields. The backticks help avoid breaking the file when there’s html attributes enclosed in quotes. I then import into Access and do all my work from there. Then, export with the same settings (encoding as UTF-8).

Offhand, I don’t recall if this fixes the html entity issue, but since I’ve been doing the above, I haven’t had (as many) html issues.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Alexander Pervak
Jr. Member
 
Total Posts:  24
Joined:  2009-09-15
Kiev
 

I have made a simple VB Macros for Excel to clear all stuff, but it isn’t very good and simple soultion.

Attribute VB_Name "Module1"
Sub ClearMagentoSpecialChars()
Attribute ClearMagentoSpecialChars.VB_ProcData.VB_Invoke_Func " \n14"
'
ClearMagentoSpecialChars ÐœÐ°ÐºÑ€Ð¾Ñ
'

'
    
Cells.Replace What:="<"Replacement:="<"LookAt:=xlPart_
        SearchOrder
:=xlByRowsMatchCase:=FalseSearchFormat:=False_
        ReplaceFormat
:=False
    Cells
.Replace What:=">"Replacement:=">"LookAt:=xlPart_
        SearchOrder
:=xlByRowsMatchCase:=FalseSearchFormat:=False_
        ReplaceFormat
:=False
    Cells
.Replace What:="&quot;"Replacement:=""""LookAt:=xlPart_
        SearchOrder
:=xlByRowsMatchCase:=FalseSearchFormat:=False_
        ReplaceFormat
:=False
    Cells
.Replace What:="&quot;"Replacement:=""""LookAt:=xlPart_
        SearchOrder
:=xlByRowsMatchCase:=FalseSearchFormat:=False_
        ReplaceFormat
:=False
    Cells
.Replace What:="&amp;"Replacement:="&"LookAt:=xlPart_
        SearchOrder
:=xlByRowsMatchCase:=FalseSearchFormat:=False_
        ReplaceFormat
:=False
End Sub
 
Magento Community Magento Community
Magento Community
Magento Community
 
Alexander Pervak
Jr. Member
 
Total Posts:  24
Joined:  2009-09-15
Kiev
 

YES! I have found the solution!

You need to find the file app/code/core/Mage/Dataflow/Model/Convert/Parser/Xml/Excel.php and replace the line

$this->_xmlElement->row htmlspecialchars($value);
with
$this->_xmlElement->row $value;

The best way is to place the modified file into app/code/local/Mage/Dataflow/Model/Convert/Parser/Xml/Excel.php , then it wouldn’t erased after upgrade.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Javier Garcia
Jr. Member
 
Avatar
Total Posts:  7
Joined:  2010-05-04
Spain
 

Hello.

There is a free module of Rudi@Omikron that is a extension of Dataflow to export products in XML and expandig export settings. It can remove line breaks, html tags, add category field and add the absolute product and image link. It works correctly for 1.4 version and earlier.
http://www.magentocommerce.com/extension/specs/753/dataflow-extension

To learn more about how to use the extension see this link
http://www.magentocommerce.com/boards/viewthread/60113/

I hope have been helpful.

 
Magento Community Magento Community
Magento Community
Magento Community
 
mkk_kashif
Jr. Member
 
Total Posts:  25
Joined:  2010-12-22
 

Solution:

Go to Module -> Controller, e.g.: app/code/local/google/events/controllers/adminhtml/EventsController

Find, and replace following Method:
Only one line added and commented in code.

protected function _sendUploadResponse($fileName$content$contentType='application/octet-stream'{
        $content 
str_replace('&amp;''&'$content); /*Only this new line added*/
        
$response $this->getResponse();
        
$response->setHeader('HTTP/1.1 200 OK''');
        
$response->setHeader('Pragma''public'true);
        
$response->setHeader('Cache-Control''must-revalidate, post-check=0, pre-check=0'true);
        
$response->setHeader('Content-Disposition''attachment; filename=' $fileName);
        
$response->setHeader('Last-Modified'date('r'));
        
$response->setHeader('Accept-Ranges''bytes');
        
$response->setHeader('Content-Length'strlen($content));
        
$response->setHeader('Content-type'$contentType'text/xml; charset=UTF-8');
        
$response->setBody($content);     
        
$response->sendResponse();
        die;
    
}

Thanks,

Kashif

 
Magento Community Magento Community
Magento Community
Magento Community
 
viniciusrtf
Jr. Member
 
Total Posts:  17
Joined:  2011-08-10
 
Alexander Pervak - 10 May 2010 10:26 AM

YES! I have found the solution!

You need to find the file app/code/core/Mage/Dataflow/Model/Convert/Parser/Xml/Excel.php and replace the line

$this->_xmlElement->row htmlspecialchars($value);
with
$this->_xmlElement->row $value;

The best way is to place the modified file into app/code/local/Mage/Dataflow/Model/Convert/Parser/Xml/Excel.php , then it wouldn’t erased after upgrade.

This breaks the Import tool. Tried also with htmlspecialchars_decode and the result is that the import feature doesn’t work at all.

I’ve been searching for some free and open solution but everyone tries to sell an extension.

It seems to be an old problem.

Anyone?

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