Project

General

Profile

« Previous | Next » 

Revision 232

Added by ryan about 19 years ago

Added support for mailto: links in the menu link mod

View differences:

trunk/wb/framework/class.frontend.php
250 250
	}
251 251
	
252 252
	function page_link($link){
253
		// Check for :// in the link (used in URL's)
254
		if(strstr($link, '://') == '') {
253
		// Check for :// in the link (used in URL's) as well as mailto:
254
		if(strstr($link, '://') == '' AND substr($link, 0, 7) != 'mailto:') {
255 255
			return WB_URL.PAGES_DIRECTORY.$link.PAGE_EXTENSION;
256 256
		} else {
257 257
			return $link;
trunk/wb/framework/functions.php
405 405
// Function to work out a page link
406 406
if(!function_exists('page_link')) {
407 407
	function page_link($link) {
408
		// Check for :// in the link (used in URL's)
409
		if(strstr($link, '://') == '') {
408
		// Check for :// in the link (used in URL's) as well as mailto:
409
		if(strstr($link, '://') == '' AND substr($link, 0, 7) != 'mailto:') {
410 410
			return WB_URL.PAGES_DIRECTORY.$link.PAGE_EXTENSION;
411 411
		} else {
412 412
			return $link;

Also available in: Unified diff