WordPress.org

Ready to get started?Download WordPress

Forums

Add padding to text around amazon widget (7 posts)

  1. stevem802002
    Member
    Posted 2 years ago #

    I'd like to add some padding around the amazon widget used in this post.

    http://renight.com/blog/tritonal-interview

    dummies guide please!

  2. vtxyzzy
    Member
    Posted 2 years ago #

    The widget does not have a class or id that allows you to add styling unique to it.

    It does have a hard-coded style of 'float: left;'. If you can find that div, either give it a class and put the styling in style.css, or add 'padding-right: 5px;' to the hard-coded style.

    If you cannot locate the div, try adding this to the end of style.css, but be aware that it might affect more than the one widget:

    div.entry > div { padding-right: 5px; }

  3. stevem802002
    Member
    Posted 2 years ago #

    is this in 'custom.css' ?

  4. vtxyzzy
    Member
    Posted 2 years ago #

    It may work there, but the only place I tried it was style.css.

    It would be better if you can find the code where the widget is created and change it there. Otherwise, there may be undesired effects on other items.

  5. stevem802002
    Member
    Posted 2 years ago #

    ah ok - within the widget code when i post it in html view? Im guessing near the top┬┐ padding-right

    <div style="float: left;"><object id="Player_c02" width="160px" height="300px" classid="clsid:d27cdb6e-ae6d-11cf-96b8-0" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="quality" value="high" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://ws.amazon.co.uk/widgets/q?rt=tf_w_Operation=GetDisplayTemplate" /><embed id="Player_42" width="160px" height="300px" type="application/x-shockwave-flash" src="http://ws.amazon.co.uk/widgets/q?rt=tf_w_mpw&ServiceVersion=2&MarketPlace=GB&ID=B%2F-2ed6-d7-e41mp;Operation=GetDisplayTemplate" quality="high" allowscriptaccess="always" /></object>

  6. vtxyzzy
    Member
    Posted 2 years ago #

    Try changing this:

    <div style="float: left;">

    to this:

    <div style="float: left; padding-right: 5px;">

  7. stevem802002
    Member
    Posted 2 years ago #

    it worked! thanks !

Topic Closed

This topic has been closed to new replies.

About this Topic