[\S\s]*?\<\/code\>)!ims', array('AWP_protecttags','returnblocks'), $content); $content = preg_replace_callback('!(\
[\S\s]*?\<\/blockquote\>)!ims', array('AWP_protecttags','returnblocks'), $content);
$content = preg_replace_callback('!(\[\S\s]*?\<\/pre\>)!ims', array('AWP_protecttags','returnblocks'), $content);
return $content;
}
function return_tags($blocks){
global $id, $aWP;
return $aWP[blocks][$id][$blocks[2]];
}
function findblocks($output){
global $id, $aWP;
if(is_array($aWP[blocks][$id])){
for($c = 0; $c
Protect tags?
When posts are split based on paragraphs or words, this module will protect blockquotes, code and pre blocks from being included in the counts and insert them back into the pages. This may mean that a long code segment etc may go over the specified length; however, this is probably preferable to users only getting a partial segment.
block;
AWP_admin::admin_panel($menu);
}
function awp_get_options($i){
$i[checkboxes][] = 'protecttags';
return $i;
}
function set_defaults(){
global $awpall;
$awpall[cache] = 'Enabled';
update_option('awp',$awpall);
}
}
?>