Click here to Skip to main content
15,886,578 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
http://www.youtube.com/embed/IAq5sMjmhsE

How to change above URL format to below URL format using split or anything else.

http://www.youtube.com/v/IAq5sMjmhsE?fs=1&hl=en_US
Posted
Comments
Sergey Alexandrovich Kryukov 25-May-11 15:18pm    
Not clear. Requirements, please.
--SA

1 solution

Try:
string inp = "http://www.youtube.com/embed/IAq5sMjmhsE";
string outp = string.Format("{0}?fs=1&hl=en_US", inp.Replace("/embed/", "/v/"));
 
Share this answer
 
Comments
Orcun Iyigun 25-May-11 15:27pm    
simple solution. 5'ed.
divesh12 25-May-11 15:41pm    
Thanks

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900