|
|
Browse by Tags
All Tags » html » find replace
-
I have a CMS which is written to output xhtml. I am trying to write a php script that will convert the system - completely and permanently - to output html instead. The sticking point is creating a regex to find self-closing xhtml tags (e.g., <img /> ) and convert them to non-self-closing html tags (e.g., <img>). I am ...
-
Hi guys,
Sure this is probobly simple but my head just can't get around this issues... I'm trying to parse the HTML to start replacing/removing problem tags to meet W3C AA compliance and various other requirements. The first one i'm working on is removing the 'bgcolor' attribute of any table/tr/td tag. But using the ...
-
OK. Stick with me here. It is going to take me a few to explain this.
I am writing a small application in VB.NET. The ultimate task is to make a web browser, within a web browser. Basically, You open IE, FireFox, Safari, or whatever browser you like and go to the web application I am building. At the top of the web page, I have a tool bar, ...
-
I am working in Coldfusion trying to match CSS items that are NOT listed.
For instance, I have this code to match:
<div style='color:#444444;float:none;'>Test Text</div>
I have the code matched down to:
color:#444444;float:none;
My regular expression to match CSS items ...
-
Give this a shot.
(<[^>]*>)[^<>/]*(padding)[^<>/]*(</[^>]*>)
Same trick as before the middle group is what you want to replace each time. First and Third groups are the html tags around content. Any word you want to find can be put into that middle ...
-
Thanks again Sergei. I found the solution, your regex was perfect, it's just a PHP oddity. This page on php.net:
http://www.php.net/manual/en/function.preg-replace.php
describes pre_replace and c_stewart0a at yahoo dot com had the solution which is:
"you will want to quote your searching expression with /"
This did the job. So ...
-
Hi everyone
I'm very new to regular expressions and currently trying to write a regex to replace all instances of the string " with " inside html tags.
An example string which i am testing with is:
"miaow" said the cat <a href="http://www.something.com" title="hello">this is "not" ...
-
I'm trying to convert all relative paths within a html page into absolute paths. I've searched quite a bit and not found anything that does exactly what I'm trying to do.
I'm using .Net to do the replacement. Here is the pattern I have so ...
-
Hi, I'm working in PHP4, and want to use preg_split() to make a string like:
<span>
On October 17th 2006 at 10:40 am 1710 User 1 wrote:</b>
AIRPORT TERMINAL 1</span>
<span>
On October 17th 2006 at 11:00 am Res Test 1 wrote:</b>
This booking has been accepted.
</span>
<span>
On ...
-
I am writing a web-based rich-text editor (such as the one which you use to write the posts on this forum) in ASP.Net (VB.Net).
The problem is: Mozilla and IE format the HTML in different ways, and I need a common code, as people using different browsers must be able to edit the same text. The problem is specifically with bold, italic and ...
|
|
|