Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Xporter: Error with images and wiki render

Yanet Morales
Contributor
July 16, 2020

I'm having this same issue with images in Description and trying to render the content using wiki. I tried to replace the size of images without success. I'm trying this

 

${wiki%{'${escape:JQLIssues[j].Description}'.replace(new RegExp('width=\d+,height=\d+!','g'),'width=200,height=200!')}}

 

I noticed that the image tag is coming like this: 

!image-20200417-132307.png|width=1801,height=561!

I tried to remove the whole image and try to change the size without success.

 

Any thoughts?

3 comments

Comment

Log in or Sign up to comment
Brigitte Bedard January 15, 2021 edited

I have the same problem and submitted a ticket.  I want to remove the image completely.  Did you succeed?  I notice that you are missing the ':' after wiki.  

I tried this and it is not working.

${wiki:%{'${TestExecutions[n].TestRuns[a].TestSteps[r].Action}'.replace(/\!.*?\!/,'')}}
Yanet Morales
Contributor
March 30, 2021

Hi, Brigitte. Nice catch with the :! I did not have any success on this and, after expend almost one week trying different things I just gave up and decide to not use wiki....now the exported info is comming with all the tags. I just decided to give another try in a few months and see if there is any update on this.....

Yanet Morales
Contributor
March 30, 2021

Also, sorry for my late response, :(

Nicolás Figueroa
Contributor
October 21, 2022

Hello, I was dealing with the same problem.

I tried many different possibilities to try to resize or delelte the image from the wiki format but is like it's not working with javascript.

So I achive a solution with a workarround, using a property that delete all the images from wiki fields and then I add it with a iteration.

${prop(document.wiki.process.images,false)}

https://confluence.getxray.app/display/public/XPORTERCLOUD/Props#Props-ProcessWikiImage

 

And then in the same iteration of the Description field I use:

#{for images}

${Images[n].Image|maxwidth=600|maxheight=550}

#{end}

 

The problem is this will populate with all the images that the issue/issues have.

 

I was trying to find a way to create a if that take the value images value from the Description and apply it in the #{for images} but no success at the momment.

 

Xporter support is very slow and at the end of the day I gave them the solutions....

Manuel Ersch
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 12, 2024

Probably does not help you any more and maybe there is even a better way now to do it. But as this thread was one of the first hits and it helped me to find a solution that worked for me eventually, I want to share with those that still struggle with this.

${wiki:%{'${TestSteps[n].Action}'.replace(/width=\d+,height=\d+/g, 'width=150,height=150')}}

 

Like • Nicolás Figueroa likes this
Nicolás Figueroa
Contributor
February 18, 2025

Hi Manual,  I'm very interested in your solution, I tried many ways and for me it was not possible to achieve what you say.

Do you tried it in jira cloud or dc/server?

I'm doing it also for the Action test section, but it's always empty.

TAGS
atlassian, confluence administration certification, atlassian certified professional, confluence admin for cloud, atlassian learning, confluence training, confluence certification exam, confluence cloud admin, admin credential, atlassian certification

Become a certified Confluence admin today! 📖

Stand out as a skilled Confluence Cloud administrator. The Confluence Administration for Cloud certification proves you can configure permissions, manage site and space settings, and monitor activity—ensuring secure, effective collaboration for your team.

Start here
AUG Leaders

Atlassian Community Events