Proof converts symbols (>,<,- etc.) into character sets
When I use xpath in developers tool, it returns me text string with proper text and symbols "<", ">", "-". But when I use same xpath in proof, i get a textual value including character sets such as (<, &ndash etc.) instead of "<", ">", "-". I tried HTML Tag and String types while was creating the object but still getting those character set symbols.
Is there a way to return textual value exactly as it is displayed on the page when these kinda symbols are included?
The page i was using is not public. But you can use this page for testing which is public and also giving me same issue: https://data.hrsa.gov/data/reports/datagrid?gridName=FinancialAssistance
This page will give you similar problem with quotation marks
Hi Vitaly,
Thank you for sending the site. Would it be possible to send us part of the DOM with the value you are looking for (including parent tags) from the site you used initially and the XPath you used with Get_Web_Value ?
For example:
<tag1><tag2>text containing symbols </tag2></tag1>
Regards,
Subject7 Team
This issue creates a big problem with my automation script at this moment and i have to apply tooo many hacks to compare it with DB results. Please, investigate and provide some kinda solution.
Just fyi, Proof tool reads short dashes "-" with no issues, but long dashes "–" it converts to "–"
Hi Vitaly,
I tested Get_Web_Value on the website using the provided XPath (//p[contains(@class,"lead")])[1] with (Html Tag + Text) and this is the result I have for quotation marks:
Could you please confirm that this is what you have as well? Per your post, you said (HTML Tag) did not work, so I am just making sure.
Regards,
Subject7 Team
I verified and looks like provided xpath returns correct value while (HTML Tag) is selected. For my scenario though, I'm using "String" because Proof tool can't identify the text i'm looking for if I use (HTML Tag). Is it expected to get those characters when "String" option is selected. I can provide my xpath but you can't really use it because application is not public.
Below is the error message i get when I use (HTML Tag) option.
concat((normalize-space(((//table[@class="table table-striped table-bordered"])[1]//tr)[2]/td[1]))," ",translate((((//table[@class="table table-striped table-bordered"])[1]//tr)[2]/td[2])," ","")," ",translate((((//table[@class="table table-striped table-bordered"])[1]//tr)[2]/td[3])," ","")," ",translate((((//table[@class="table table-striped table-bordered"])[1]//tr)[2]/td[4])," ",""))
Please sign in to leave a comment.