[wp-hackers] HTMLArea Integration

Curtis Steckel fmxsteckel at yahoo.com
Fri Oct 8 05:58:30 UTC 2004


I have implemented a costomized version of the free open source one found at http://www.kevinroth.com/rte/demo.htm ... anyone seen this one or want to help me costomize it? i changed the color pallette to be more like the one offered in dreamweaver and added an emoticon list...
 
 

Jason Trommetter <jasontromm at gmail.com> wrote:
Has anyone ever considered integrating a WYSIWYG editor like HTMLArea
into the base WP code? I had to modify just one core file to get it
to work, admin-header.php.


   _editor_url = "/htmlarea/";
   _editor_lang = "en";





require_once('../wp-config.php');
require_once(ABSPATH . '/wp-admin/auth.php');
require(ABSPATH . '/wp-admin/admin-functions.php');

$dogs = $wpdb->get_results("SELECT * FROM $wpdb->categories");
foreach ($dogs as $catt) {
$cache_categories[$catt->cat_ID] = $catt;
}

get_currentuserinfo();

$posts_per_page = get_settings('posts_per_page');
$what_to_show = get_settings('what_to_show');
$date_format = get_settings('date_format');
$time_format = get_settings('time_format');

$wpvarstoreset = array('profile','standalone','redirect','redirect_url','a','popuptitle','popupurl','text', 'trackback', 'pingback');
for ($i=0; $i $wpvar = $wpvarstoreset[$i];
if (!isset($$wpvar)) {
if (empty($_POST["$wpvar"])) {
if (empty($_GET["$wpvar"])) {
$$wpvar = '';
} else {
$$wpvar = $_GET["$wpvar"];
}
} else {
$$wpvar = $_POST["$wpvar"];
}
}
}

if ($standalone == 0) :

?>








if ($redirect==1) {
?>

function redirect() {
  window.location = "";
}
setTimeout("redirect();", 600);
//-->

} // redirect
?>



//
function GetElementsWithClassName(elementName, className) {
	var allElements = document.getElementsByTagName(elementName);
	var elemColl = new Array();
	for (i = 0; i 		if (allElements[i].className == className) {
			elemColl[elemColl.length] = allElements[i];
		}
	}
	return elemColl;
}

function blurry() {
	if (!document.getElementById) return;
	
	var aInputs = document.getElementsByTagName('input');
	
	for (var i = 0; i 		aInputs[i].onclick = function() {
			var inputColl = GetElementsWithClassName('input','valinp');
			var rel = document.getElementById('rel');
			var inputs = '';
			for (i = 0; i  [input] 				if (inputColl[i].checked) {
				if (inputColl[i].value != '') inputs += inputColl[i].value + ' ';
				}
			}
			inputs = inputs.substr(0,inputs.length - 1);
			if (rel != null) {
				rel.value = inputs;
			}
		}
		
		aInputs[i].onkeyup = function() {
			var inputColl = GetElementsWithClassName('input','valinp');
			var rel = document.getElementById('rel');
			var inputs = '';
			for (i = 0; i  [input] 				if (inputColl[i].checked) {
					inputs += inputColl[i].value + ' ';
				}
			}
			inputs = inputs.substr(0,inputs.length - 1);
			if (rel != null) {
				rel.value = inputs;
			}
		}
		
	}
}

window.onload = blurry;
//]]>








("> »)



require('./menu.php');
endif;
?>_______________________________________________
hackers mailing list
hackers at wordpress.org
http://wordpress.org/mailman/listinfo/hackers_wordpress.org


-ǵ®†î$ §†è¢kèl
__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: /pipermail/hackers_wordpress.org/attachments/20041007/73eca6c1/attachment.htm


More information about the hackers mailing list