Support » Fixing WordPress » How do I change this code?

  • How do I change this code so that text %file_display_name% appears on the left side centered and image on the right?

    Right now text appears on top left.

    %file_display_name%
    <style type="text/css" media="screen">
    	.wpfb-dlbtn div { width:215px; height:40px; margin:0; padding:0; background:transparent url('%wpfb_url%/images/dl_btn.png') no-repeat  right;}
    	.wpfb-dlbtn div:hover { background-image: url(%wpfb_url%/images/dl_btn_hover.png); }
    </style>
    <div style="text-align:right; width:20px; margin: auto; font-size:smaller;"><a href="%file_url%" class="wpfb-dlbtn"><div></div></a>
    
    </div>
Viewing 7 replies - 1 through 7 (of 7 total)
  • Appears where? Where did you add this. Generally, CSS should be added to a CSS file (typically style.css) – though modifications should be done in a child theme or custom CSS section so that the changes are not lost when the theme is updated.

    Thread Starter jim333

    (@jim333)

    This is actually template on one of the plugins that I’m using.
    So pretty much make a custom template how the plugin appears on my site.
    No changes to my theme.

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    Which plugin? That will help other people assist you.

    Thread Starter jim333

    (@jim333)

    WP Filebase

    Generally, the answer is still the same – to add CSS code to an external style.css file (child theme) or custom CSS section. Where is this code right now? Where did you get it?

    A link to a site makes CSS help MUCH easier.

    Thread Starter jim333

    (@jim333)

    Site is not live.
    How did I get the code? I installed WP Plugin went on templates section of plugin, there is 6 options how you want to display your downloadable file I clicked on edit where it lets you move things around and it creates a new code for you. Press save and you have a new custom template.
    I go on any page (body) click on the icon to add a downloadable file add a file and choose my new custom template as how I want file to appear on my page.

    I really hope that this answers your question.

    Yes, indeed it does, but unfortunately, it doesn’t really make an answer easy to come by – as it’s next to impossible to help with CSS without seeing the page/site live.

    Are you familiar with how CSS works? That’s going to be your best bet longer term :). A browser tool like Firebug will be immensely useful. Also this site:

    http://www.w3schools.com/css/default.asp

    In the meantime, we can try to use CSSDesk if you want to do that – which might work. You’ll need to copy the rendered HTML (use View Source in a browser) and the CSS to the site and post a link here to it.

    (I’m also about to get off for a bit, but will check back…)

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘How do I change this code?’ is closed to new replies.