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

Remove XML format when Decoding #15

Open
andrespadron98 opened this issue Jun 20, 2019 · 4 comments
Open

Remove XML format when Decoding #15

andrespadron98 opened this issue Jun 20, 2019 · 4 comments
Assignees

Comments

@andrespadron98
Copy link

I am decoding a bar code that is in XML format and when decoding it removes the <> plus what is inside the <>, what can be done?

Thank you!

@dsiddharth2
Copy link
Owner

Can I know how are you encoding the data into image?

Is there any example or any link that I can refer to?

@andrespadron98
Copy link
Author

I discovered that since I was showing it in XML, the tags I hid it, it was my mistake, but now when I decorate it, it does not show it completely, I try to decode this image:
1 (2)

and it does not give me the same information as here https://zxing.org/w/decode.jspx

it gives me less information

@alvaro-donoso
Copy link

alvaro-donoso commented Sep 5, 2019

Same for me...when I use XML format text or tags (<>) inside the PDF-417 codebar, the script return the plain text with no tags.

I realized that the use of exec($command, $script_output); in PHPZxingDecoder.php make this behavior. I know this because I put the same command generated in the $command variable inside the terminal and it returned me the real value with tags (xml format).

So i suppose its something in the return of the value using the exec method.

EDIT: I solved it changing for $imageValue = htmlentities($output[$key + 2], ENT_XHTML); in the createImages() method from PHPZxingDecoder.php

@dsiddharth2
Copy link
Owner

@Alvoxdns Hello, Can you fix and Raise a Pull Request, I will test and merge the fix. Thank you :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants