04-20-2021 10:43 AM
Hello everyone, I am trying to put html code as product description when generating CSV file for File Exchange, but it breaks at one point and it looks like it can not fit whole html code in description. Nothing is written in file after that break. This is how my file looks:
https://drive.google.com/file/d/1elMf6jWoVkC9nmJ9drHJYSLqXZFfImRD/view?usp=sharing
Thanks everyone in advance.
04-20-2021 04:47 PM
Hi @borisa_krstic,
Thanks for posting, I'm sorry to hear you're having issues with your description HTML.
In my experience, when HTML breaks into other cells like that, it's due to the data being over the character limit of a cell. For example, Excel has a character limit per cell of 32,767. It could also be caused by the source it's being copied from, you could try pasting into Notepad, then copying/pasting from there into your file. Or, you could run it through our description utility to clean it up a bit: http://pics.ebay.com/aw/pics/pdf/us/file_exchange/FileExchangeDescriptionUtility.zip
Hope this helps!
04-20-2021 05:22 PM
I agree with @Anonymous about the 32K limit on cell size because I have that issue with my older version of Excel. If I download a file that has cell data larger than 32K, it wraps onto a new line when displaying in Excel, but remains fine in the file itself if I don't edit further in Excel.
However, that is not your problem. I downloaded your CSV and the truncated portion is at the beginning and is only a few hundred characters at most. And the breaks are occurring where the commas appear in the HTML code.
I don't know how you are adding the description. I'm guessing this might happen when the content is pasted directly in a cell on the spreadsheet. So, instead of pasting into the cell, click the cell and paste the code into the text line at the top of the spreadsheet to see if that will solve the problem.
04-21-2021 12:06 AM
I am doing it automatically, I have made application that generates csv files using Javascript, when I add regular description it all works , but there is problem with longer HTML
04-21-2021 10:34 AM
I would recommend taking a closer look at your Javascript.
These are the first three cells of your split description
<font rwr='1' style='font-family: Arial' size='4'><meta charset='utf-8' /><meta name='viewport' content='width=device-width
initial-scale=1
shrink-to-fit=no' /><title>Free eBay listing template designed by dewiso.com</title><link href='https://dewiso.com/css/bootstrap.min.css' rel='stylesheet' /><style type='text/css'>.element{background-image:url('https://dewiso.com/images/f0f0f0_background.png');background-size:cover}</style><div style='background
Notice that there would have been a comma after device-width in the first cell and after scale=1 in the second cell. I don't know what character follows background in the third cell, but that character has split the row, so I suspect there was a line-end at that location.
When scripting a CSV file, rather than when typing directly into a spreadsheet, the description text must be quoted and any embedded quotes must be doubled. So your script should first look for line-ends (\r\n and \r and \n) and remove or convert to a space (I prefer converting to a space), then look for internal quotes (") and double each one (""), and finally, wrap the entire description in quotes. The quoted description can then be added to the other data in that row or array.
File Exchange will accept data that is comma-delimited, semicolon-delimited, or tab-delimited, but make sure the script is using the same delimiter throughout, particularly if using a premade CSV conversion function.
04-21-2021 10:45 PM
Hello shipscript,
Thank you for your response, my HTML was already formatted to go into one line without breaks and now I have tried to wrap it into "" instead of `` but it still breaks. Do you have some other suggestion? Thank you in advance.
This is how my html looks:
<font rwr='1' style='font-family: Arial' size='4'><meta charset='utf-8' /><meta name='viewport' content='width=device-width, initial-scale=1, shrink-to-fit=no' /><title>Free eBay listing template designed by dewiso.com</title><link href='https://dewiso.com/css/bootstrap.min.css' rel='stylesheet' /><style type='text/css'>.element{background-image:url('https://dewiso.com/images/f0f0f0_background.png');background-size:cover}</style><div style='background #fdfefe; border-left: 1px solid #cbd4c2; border-right: 1px solid #cbd4c2; border-top: 1px solid #cbd4c2; color: #353535; line-height: 45px; ' > <div class='container' style='padding: 40px 0 40px 0'><div class='col-12 col-md-12'><hr style='background: #273c2c; height: 1px; width: 10%' align='center' /></div></div></div><div class='element' style=' border-left: 1px solid #cbd4c2; border-right: 1px solid #cbd4c2; color: #353535; line-height: 25px; ' ><div class='container' style='padding-bottom: 20px; padding-top: 50px'><div class='row'><div class='col-12 col-md-4' style='padding-bottom: 20px'> <font style='color: #353535' face='Arial' ><img alt='Product' class='mx-auto d-block img-fluid' src='https://img.icons8.com/material-sharp/96/000000/auction.png' style='width: 20%' title='Product' /></font><h2 style='text-align: center; line-height: 45px'> <strong><span style='font-size: 28px'>Bid</span></strong></h2><p> <span style='font-size: 16px' ><strong>Save up to 80% off Retail Price</strong> on your item! Coats, suits, dresses and many more ? in auction, you decide the price you pay. Grab yourself a great fashion bargain!</span ></p></div><div class='col-12 col-md-4' style='padding-bottom: 20px'> <span style='font-size: 16px' ><font style='color: #353535' face='Arial' ><img alt='Shipping' class='mx-auto d-block img-fluid' src='https://img.icons8.com/ios-filled/96/000000/winner.png' style='width: 20%' title='Shipping' /></font ></span><h2 style='text-align: center; line-height: 45px'> <strong ><span style='font-size: 28px' ><font style='color: #353535' face='Arial'>Win</font></span ></strong ></h2><p style='font-size: 14px; text-align: justify'> <span style='font-size: 16px' >Bid today and help save the planet while you save some pennies!</span ></p></div><div class='col-12 col-md-4' style='padding-bottom: 20px'> <span style='font-size: 16px' ><font style='color: #353535' face='Arial' ><img alt='Contact' class='mx-auto d-block img-fluid' src='https://img.icons8.com/pastel-glyph/128/000000/truck.png' style='width: 20%' title='Contact' /></font ></span><h2 style='text-align: center; line-height: 45px'> <strong ><span style='font-size: 28px' ><font style='color: #353535' face='Arial'>Receive</font></span ></strong ></h2><div class='vc_row wpb_row vc_row-fluid'><div class='wpb_column vc_column_container vc_col-sm-12'><div class='vc_column-inner'><div class='wpb_wrapper'><div class='wpb_text_column wpb_content_element'><div class='wpb_wrapper'><p style='font-size: 14px; text-align: justify'> <span style='font-size: 16px' ><strong>UK wide home delivery available</strong>! Your parcel will be securely packaged with a tracking details provided, and insurance cover included. </span></p></div></div></div></div></div></div></div></div></div></div><div style=' border-left: 1px solid #cbd4c2; border-right: 1px solid #cbd4c2; color: #353535; line-height: 25px; ' ><div class='container' style='padding: 40px 0 40px 0'><div class='col-12 col-md-12'><div typeof='Product' vocab='https://schema.org/'><ul><li> <strong>Condition: </strong>This and any other item are sold as pre-owned, but in good, very good or like new condition (please read item condition part of this listing). This and any other item have not been washed so please do so after you receive it if required by your self (to make starting bid as low as 0.01GBP we don't have this possibility).</li></ul></div></div></div></div><div style=' background: #fdfefe; border-left: 1px solid #cbd4c2; border-right: 1px solid #cbd4c2; color: #353535; line-height: 25px; ' ><div class='container' style='border-top: 1px solid #cbd4c2; padding: 40px 0 40px 0' ><div class='col-12 col-md-12'><h2 style='line-height: 45px'> <font style='color: #353535' face='Arial' >Features and further details</font ></h2><hr style='background: #353535; height: 1px; width: 10%' align='left' /><ul style=' color: #353535; line-height: 25px; font-size: 16px; margin-top: 30px; ' ><li> <font style='color: #353535' face='Arial' ><b>Cancelation and Returns:</b></font > As a consumer buyer you have the right to cancel/return this purchase without giving any reason at all within 14 days but you are resposible to pay for postage.</li><li> <font style='color: #353535' face='Arial'><b>Package: </b></font >Grey mailing sacks.</li><li> <strong>Postage</strong>: item dispatched within same working day if paid before 6:00PM (excludes weekends and holidays). Immediate paymement required for this item. Delivered in 3-5day with a standart other delivery courier company (due to current situation).</li></ul></div></div></div><div style=' border-left: 1px solid #cbd4c2; border-right: 1px solid #cbd4c2; border-bottom: 1px solid #cbd4c2; color: #353535; line-height: 25px; ' ><div class='col-12 col-md-12 element' style='color: #353535'><div class='container' style='padding: 20px 0 20px 0; font-size: 80%; text-align: center' ><p> </p></div></div></div></font >
04-23-2021 09:51 AM
I think the problem may be with the script that creates the spreadsheet. Can you provide one record (one row of data) from the CSV file that is created from your data?
04-25-2021 11:17 PM
Hi,
This is one record from file I generate. When I put regular text as description as seen here: "Perfect dress for everyone" everything works, but when I try to put HTML as mentioned it breaks
https://drive.google.com/file/d/1OCn_nPHF0MkLdJ6ZFp52QmwJcAczqaCl/view?usp=sharing
04-25-2021 11:42 PM
Hello shipscript,
I have removed all color codes that start with #, that was the problem regarding HTML, but now I get this response when I try to upload
04-26-2021 06:56 AM
I wanted to see the file with the broken HTML in it. Can you change your spreadsheet file suffix from "CSV" to "TXT" and share that one with the original HTML?
Your current BAF.error.7 is due to quotes not surrounding some of your data. I suspect that is the general problem with your HTML file, but I would like to see that file as txt to confirm. In your earlier post, I did see a problem with the color codes in your HTML and I would like to see those in the original format as well.
Welcome to the Seller Tools board! You can chat with other members about seller tools and best practices in using them.
Tools related questions? Learn more about:
Videos: