Hello friend ~I want to get content between the first html tag and the second html tag.for example <p>Hello <bold>world</bold>!</p> will return Hello
<p>Hello <bold>world</bold>!</p>
Hello
What should I do in Ruby? Thanks ~
Regex will be: <[^>]*>([^<]*)
<[^>]*>([^<]*)
<[^>]*>
([^<]*)
how to apply it to ruby - i don't know
take a look at http://www.regular-expressions.info/ruby.html
A regular expression that captures eternity between the first and second pair of angle brackets looks like
/<.*?>(.*?)</m
.
, , , HTML JavaScript.
Source: https://habr.com/ru/post/1789004/More articles:How to get proxy settings from IE? - internet-explorerWhat information can I get from the Android JavaScript browser? - javascriptMapPoint Control - adding territories - visual-studio-2010EclipseLink in OSGI Bundle persistence.xml not found - javaNSURLCredential and NSURLConnection - objective-cproblems with iOS.mobi - iosIIS Cannot access the file, but a user registered in the same account can - windowsASP.NET 4.0 GridView OnRowEditing events do not fire when using Unity 2.0 http module - asp.netThe refresh button launches an edit event handler - c #How should I Unit Test WebServiceTemplate (SpringWS) - javaAll Articles