vngx
August 3, 2016, 1:00pm
1
Hi there
I want to send anchor between text in JSON How can I do this?
Like Example
“TextTextTextTextTextTextTextTextTextTextTextTextTextTextTextTextTextTextTextTextTextLink TextTextTextTextTextTextTextText”
although I can send data in this format but problem is extracting hyperlink from it in receving client.(android,iOS)
(Don’t know where to post so posted in PHP category,moderator if I have posted in wrong category then please move it to proper category)
chorn
August 3, 2016, 2:11pm
2
send url (href) and label in seperate JSON nodes. Let the client choose how to deal with it.
1 Like
vngx
August 3, 2016, 4:17pm
3
in my case I have to send anchor between text
chorn
August 4, 2016, 6:02am
4
and what did you try to extract the link within your application? regex may match that.
This statement quite contradicts with the task description. And with common sense too.
Besides, any reason you cannot send the same link in the additional field?
vngx
August 4, 2016, 11:31am
6
I am sending REST web service of a blog that contain html links anchor,images,strong,bold etc…
client will parse them as per their requirement
Do I need to explain it more?
sounds like you just need to treat the whole lot as plain text then if the client is going to parse any tags contained in that text as they require.
vngx
August 5, 2016, 5:07am
8
yes this is my requirement
vngx:
this is my requirement
so what is the problem?
Where is the text with embedded link coming from - there is no issue with it once you have the text in a variable so is the problem getting the text into a variable without breaking the link?
vngx
August 8, 2016, 6:56am
10
yes this is problem to get href attribute of anchor tag.
I can get tag sepration easily
system
Closed
November 7, 2016, 1:56pm
11
This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.