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

Word2007 Reader : Read hyperlingks in headings #2433

Merged
merged 2 commits into from
Aug 12, 2023

Conversation

hannesdorn
Copy link
Contributor

@hannesdorn hannesdorn commented Aug 2, 2023

Description

PHPWord is ignoring hyperlinks in headings.
In src\PhpWord\Reader\Word2007\AbstractPart.php only w:r elements are read.

Fixes #1792

Checklist:

  • I have run composer run-script check --timeout=0 and no errors were reported
  • The new code is covered by unit tests (check build/coverage for coverage report)
  • I have updated the documentation to describe the changes

Copy link
Member

@Progi1984 Progi1984 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A small comment

src/PhpWord/Reader/Word2007/AbstractPart.php Outdated Show resolved Hide resolved
@Progi1984 Progi1984 merged commit 85d200a into PHPOffice:master Aug 12, 2023
9 checks passed
@Progi1984 Progi1984 changed the title Hotfix: In headings hyperlinks are ignored. Added w:hyperlink to xpath filter Word2007 Reader : Read hyperlingks in headings Aug 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Reading docx with <h?> containing anchors the ancors just get removed.
2 participants