Getting images to show in my document
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 2
- Joined: Wed Jul 22, 2015 12:27 pm
Getting images to show in my document
Hi,
I'm using Author mode and want images to display in the document. They display fine when in the same folder as the XML file but I can't seem to figure out how to display them when they are contained in a neighbouring folder.
Folder structure:
Root
-> OSE (where the XML file is contained and some graphics)
-> Graphics (where most of the other images are)
I don't want to edit the XML attributes for the image tags. And I don't really want to add new tags.
I am using CSS to show the images in the OSE folder
Is there anything I can do with CSS or another kind of transformation I can do?
Thanks in advance
Ian
I'm using Author mode and want images to display in the document. They display fine when in the same folder as the XML file but I can't seem to figure out how to display them when they are contained in a neighbouring folder.
Folder structure:
Root
-> OSE (where the XML file is contained and some graphics)
-> Graphics (where most of the other images are)
I don't want to edit the XML attributes for the image tags. And I don't really want to add new tags.
I am using CSS to show the images in the OSE folder
Code: Select all
figure {
content : attr(xsrc , url) ;
}
Thanks in advance
Ian
-
- Posts: 515
- Joined: Wed May 20, 2009 2:40 pm
Re: Getting images to show in my document
Hi,
The xsrc attribute value contains only the name of the image file? If this is the case I think that you can use the following css to display the images with the same name, located in the Graphics folder:
Here is the documentation for oxy_url() function:
http://www.oxygenxml.com/doc/versions/1 ... ction.html
If this is not your use-case please give us a small xml sample.
Best regards,
Mihaela
The xsrc attribute value contains only the name of the image file? If this is the case I think that you can use the following css to display the images with the same name, located in the Graphics folder:
Code: Select all
figure {
content : oxy_url("../Graphics/", attr(xsrc));
}
http://www.oxygenxml.com/doc/versions/1 ... ction.html
If this is not your use-case please give us a small xml sample.
Best regards,
Mihaela
Mihaela Calotescu
http://www.oxygenxml.com
http://www.oxygenxml.com
-
- Posts: 2
- Joined: Wed Jul 22, 2015 12:27 pm
Re: Getting images to show in my document
Apologies for not posting any of the XML too.
I'm afraid that your solution did not work, however I did find a similar workaround. Yours changed the drive of the file I was working on for some reason.
This is what I found that worked:
thanks for the help
Ian
I'm afraid that your solution did not work, however I did find a similar workaround. Yours changed the drive of the file I was working on for some reason.
This is what I found that worked:
Code: Select all
content: oxy_url(attr(xsrc, url), oxy_replace(attr(xsrc, url), "ose", "graphics"));
Code: Select all
<figure id="fig5" xsrc="filename.tif">
...some other stuff
</figure>
Ian
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service