开发者

to remove href attr from all the anchor tags using Reg Ex

开发者 https://www.devze.com 2022-12-08 21:17 出处:网络
i am trying to removehref attr from all the anchor tags using Reg Ex,for print page. Although i need the text value in anchors.开发者_开发知识库Couldn\'t you just style your links using CSS? You could

i am trying to remove href attr from all the anchor tags using Reg Ex,for print page. Although i need the text value in anchors.开发者_开发知识库


Couldn't you just style your links using CSS? You could create two separate styles: one for "normal" web visits, and one for print. In the print-style, you don't visually enhance the links.


Never parse markup with regular expressions. BAD!

http://htmlparsing.icenine.ca

0

精彩评论

暂无评论...
验证码 换一张
取 消