• Resolved compvis

    (@compvis)


    Hi,

    I just install Docxpresso and load ODT file into page. But the document is always at left side of page. How can i set so that it is at center of page?

    Thanks

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author docxpresso

    (@docxpersso)

    Have you tried to include the shortcode within a centered div?

    Best regards,

    Eduardo

    Thread Starter compvis

    (@compvis)

    Yes, my code is:

    `<div style=”text-align: center;”>[docxpresso file=”https://www.thigiacmay.vn/wp-content/uploads/2017/05/Technologies.odt&#8221; comments=”true”]</div>

    • This reply was modified 7 years, 10 months ago by compvis.
    Plugin Author docxpresso

    (@docxpersso)

    You need somthing like:

    <div style="margin: 0 auto; width: 200px; border: 1px solid red;">
    [docxpresso file="https://localhost/wordpress/wp-content/uploads/2017/05/hola.odt" comments="true"]
    </div>

    Notice that:
    1. You need to use margin: 0 auto to center the containing div
    2. Give it a width otherwise it will be centered but occupy the whole available width
    3. I just put a border to visually check that it was properly centered

    If you also want your text to be center aligned within the document (although I believe that is not your purpose) you should do it within Word (or Libre/Open Office) editor.

    Best regards,

    Eduardo

    Thread Starter compvis

    (@compvis)

    Yes, it works but the content is shifted at left side. you can see at these images:

    Word document:
    Document in MS Word

    Document loaded by Docxpresso:
    Document loaded by Docxpresso

    I also use some fonts and it lost when i upload it on web. Could you point me some hints ?

    Thank you in advance,

    Plugin Author docxpresso

    (@docxpersso)

    I do not understand: they look identical.

    If you want any changes within the document contents: alignment, color, fonts …you should change it in Word…is the whole point of the plugin ??

    If you want the fonts to be preserved you should use fonts that are web safe, i.e. that you are sure they will be in any users system like Arial, Verdana, Times, etcetera.

    If you use fonts in your document that are only available in certain systems the browser will try to replace them by a “a reasonable guess”.

    Best regards,

    Eduardo

    Thread Starter compvis

    (@compvis)

    I solved font problem.

    In MS word document, you can see left and right margin but in doc loaded by docxpresso the left margin disappears. The left border of table in two images are not the same. My icon inside the table of second image lost a part

    Plugin Author docxpresso

    (@docxpersso)

    You can add left padding to teh container div if you wish.

    Remove the red border and teh table border will show fine ??

    Thread Starter compvis

    (@compvis)

    Thanks, it works ! Great plugin, great support !

    Plugin Author docxpresso

    (@docxpersso)

    You are welcome ??

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘How to center page?’ is closed to new replies.