External Link validated with XHTML strict (bulk sql change)
Posted: Tue Aug 04, 2009 4:15 pm
I found in wiki this UDT but I think it's not easy to remember (also for average users) its syntax. So, following this thread relative to "External links in new window & XHTML Strict compliant" I was looking for an automation to change all external links from target ="_blank" to class="external".
This post was very interesting, because using a class for an external link, is very easy and fast also in TinyMCE (you can select "external" style in dropdown window style property).
Changing this attribute, all external links are validated XHTML Strict without manually changing all links in my pages.
Here following SQL statement used for this task:
Here some little improvements applied to the original script:
regards
blast
This post was very interesting, because using a class for an external link, is very easy and fast also in TinyMCE (you can select "external" style in dropdown window style property).
Changing this attribute, all external links are validated XHTML Strict without manually changing all links in my pages.
Here following SQL statement used for this task:
Code: Select all
UPDATE `cms_content_props` SET `content` = REPLACE(`content`,"target="_blank"","class="external"") where `prop_name` = "content_en"
Hope it helps{literal}
{/literal}
regards
blast