Navigating eBay's Listing Filter Minefield
eBay's page formatseBay has two formats for presenting the item page, and your template may perform differently in those two formats.
- The first format places your code inline within their page code. That means your code could modify eBay's code.
- The second format places your code inside its own iframe window so that it is isolated from eBay's code.
eBay delivers one format or the other depending on the visitor's browser.
eBay has a policy against site interference, where your template code is not allowed to modify the look or functionality of eBay's part of the page. A problem is more likely to occur if your page is presented in the first format and less likely to occur in the second format.
TroubleeBay's list of forbidden terms has been gleaned from their error reporting in actual listings. The online
AuctionTester can scan your code and report any that will likely cause problems with eBay.
HTML tagseBay doesn't allow these HTML terms and will prevent the listing from uploading
base
frame
frameset
iframe
ilayer
eBay discourages these tags and they may be stripped during listing. These are tags that already appear in eBay's page structure and are likely to be ignored by the browser when they appear a second time in the page.
html
head
title
meta
link
body
doctype <-- this tells the browser which HTML standards to use,
but it must be the very first line on the page and your listing
template will never own the first line. Thus you can't set the
doctype and should erase it from your code when testing to
see if your template still looks acceptable.
ScriptsThe following script terms are forbidden because they can be used maliciously. eBay will prevent the listing from uploading. Many of the scripts available for web pages will fail here. A large selection of eBay-safe scripts can be found on my
ME page.
cookie(
.cookie
open(
createPopup(
location=
.location
navigate(
replace(
expression(
onerror
eval(
The above phrases can often be found in normal text and will trigger a false positive when trying to upload a listing. In such a case, add an extra character or punctuation somewhere in the text term. The online
AuctionTester can help you locate blocked scripts or mistaken text.
CSS stylingThe following CSS can overwrite eBay's content or can interfere with eBay's styles. Care should be taken to understand the scope of the CSS you are using and prevent globally modifying all page styles.
Don't use a stylesheet to modify an element globally:
body { } <-- never style the body tag - it belongs to eBay.
h1 { }
h2 { }
p { }
a { }
a:link { }
a:hover { }
Instead, style elements within the scope of your own template by wrapping your template in a container and applying styles to only those elements inside your page. Or give each element that you want to style a class or id and style that class or id. In essence, when you use a stylesheet on eBay, each selector in the list must have a dot (
.) for a class or a hash (#) for an element id.
h1.mytitle { }
p.auction { }
.auctioncontent a:link { }
.auctioncontent a:hover { }
div#mycontent { }
Or you can add CSS styles directly to the tags in your page to be sure that your styles don't modify eBay and that eBay's styles don't modify your page.
PositioningWhen using CSS, be careful if your page includes
position:absoluteSince your template will be inserted into eBay's page, an element that has absolute coordinates may appear in the wrong location on the page and may overlay eBay's content. That doesn't mean you have to totally avoid absolute positioning, but it does mean that you should first define a container that will hold those elements within bounds.
If you don't use CSS and use plain old HTML attributes, one that often trips up designers is
align=left in a table. Avoid using that sort of table alignment unless you are skilled and can test the results (it's ok to use it in a TD cell). Since the rest of the page will wrap to the right of a table thus aligned, the content often gets lost off to the right of the screen or may end up in strange places on the page.