Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update cloneBlock and replaceBlock to use XML api instead of string search/replace #541

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

chervaliery
Copy link

Implements the fonction gave by @brad-jones on the issue :
#341 (comment)

Implements the fonction gave by brad-jones on the issue :
PHPOffice#341 (comment)
Take lot of time and not necessary if you well form your template
@Kertudex
Copy link

Kertudex commented Sep 8, 2015

Hello,

Do we have a chance to get the PR merged ? What is needed to go ahead ?

@sivaram-blr
Copy link

This fix helped me lot. But not understanding why this is not yet merged.

johnnymallie added a commit to webadev/PHPWord that referenced this pull request Mar 14, 2017
@FBnil
Copy link

FBnil commented Oct 21, 2017

Love the code, it uses SimpleXMLElement/xpath however, how does findBlock do it when there are multiple blocks named the same? would it get the first open and last close block?

Also, why not implement it as a subclass of TemplateProcessor, this way, it can live side-by-side with the original TemplateProcessor.

You also need some testcases to make the code maintainable later on. You should update your code to force Scrutinizer/Travis do a recheck. As it is now, red, you make less chance to merge it in.

@troosan troosan changed the base branch from master to develop December 27, 2018 20:20
@troosan troosan changed the title Update cloneBlock and replaceBlock Update cloneBlock and replaceBlock to use XML api instead of string search/replace Dec 27, 2018
@PowerKiKi PowerKiKi changed the base branch from develop to master November 16, 2022 21:11
@Progi1984 Progi1984 force-pushed the master branch 3 times, most recently from 2d9f999 to e458249 Compare August 30, 2023 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

None yet

5 participants