OZONE Asylum
Forums
DHTML/Javascript
need a way to seacrh and move html tags in a string....
This page's ID:
29174
Search
QuickChanges
Forums
FAQ
Archives
Register
Edit Post
Who can edit a post?
The poster and administrators may edit a post. The poster can only edit it for a short while after the initial post.
Your User Name:
Your Password:
Login Options:
Remember Me On This Computer
Your Text:
Insert Slimies »
Insert UBB Code »
Close
Last Tag
|
All Tags
UBB Help
What are you trying to do this with? If you're using a language like Perl you would be better off using a loop and a couple of expressions. For example: [code] $leading = ""; $trailing = ""; while ($string =~ s/(<[^>]*>)//) { my $tag = $1; if ($tag =~ /<\//) { $trailing .= $tag } else { $leading .= $tag } } $string = $leading . $string . $trailing; [/code] . -- not necessarily stoned... just beautiful. [url=http://www.hyperbole-software.com/] [img]http://www.hyperbole-software.com/ozone/hyperbole-88x33.gif[/img] [/url] [small](Edited by [url=http://www.ozoneasylum.com/user/388]hyperbole[/url] on 05-01-2007 18:29)[/small]
Loading...
Options:
Enable Slimies
Enable Linkwords
« Backwards
—
Onwards »