• Resolved edit4ever

    (@edit4ever)


    Currently printfriendly is changing inline style code which causes issues with printing some elements.

    It changes this:
    <span style="width: 80%"></span>

    Into this:
    <span orig-style="width: 80%"></span>

    By changing style= to orig-style= the items do not get styled properly for printing.

    Please fix or add option to leave inline style code in place.

    Thank you!

    • This topic was modified 6 years, 1 month ago by edit4ever.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Print & PDF by PrintFriendly

    (@printfriendly)

    Currently we don’t support inline styles. We’re looking into ways to support. To solve now, use the custom CSS feature.

    Use CSS specificity or add a class to the span.

    Add a class to the element.

    <span style="width: 80%" class="myWidth"></span>

    Use this in your custom CSS

    #printfriendly .myWidth{
      width:80%;
    }
    Thread Starter edit4ever

    (@edit4ever)

    Thank you for looking into ways to support this!

    Unfortunately the span width I am referring to is generated by quiz results and is different for every span and every user based on test answers. That is why it can’t be a hard code in the custom css. It has to remain as inline styling.

    Hopefully you are able to find a solution.

    Plugin Author Print & PDF by PrintFriendly

    (@printfriendly)

    @edit4ever We’re going to fix this. We will stop removing inline styles for WordPress. Give us 7-10 days to get it live. You will not need to update the plugin, the change happens on our side.

    If you have a minute, please give us a review on WordPress. https://www.ads-software.com/plugins/printfriendly/

    Thread Starter edit4ever

    (@edit4ever)

    Thanks for this! Hope it helps others as well. I’ll be sure to review…and thanks for the quick responses.

    P.S. another suggestion is to add the custom css into the settings section so we don’t have to edit a file on the server.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘inline style error’ is closed to new replies.