forum

home / developersection / forums / add string after a specified string

Add string after a specified string

Anonymous User 2175 13-May-2013
Hi Guys!

Say I have the following HTML string

<head>
</head>
<body>
<img src="stickman.gif" width="24" height="39" alt="Stickman">
<a href="http://www.mindstick.com">Mindstick</a>
</body> 

I want to add a string in between the <head> tags. So the final HTML string become

<head>
<base href="http://www.minstick.com/images/">
</head>

<body>
<img src="stickman.gif" width="24" height="39" alt="Stickman">
<a href="http://www.mindstick.com">Mindstick</a>
</body> 

So I have to search for the first occurrence of the <head> string then insert <base href="http://www.mindstick.com/images/"> right after.

How do I do this in C#.

Thanks in advance!
Any help will be appreciated! 

c# c# 
Updated on 13-May-2013

I am a content writter !


Message
Can you answer this question?

Answer

1 Answers

Liked By