function Question( Bark, URL )
{
	
		if ( confirm( Bark ) )
		{
				
				window.location = URL;
				
		}
		
}

function CreateBookmarkLink( title, url )
{
		
		if ( window.sidebar )
		{
				
				window.sidebar.addPanel( title, url, "" );
				
		}
		else if( document.all )
		{
				
				window.external.AddFavorite( url, title );
				
		}
		else
		{
				
				alert( 'Uw webbrowser wordt helaas niet ondersteund..' );
				
		}
		
}

function limitText( textArea, countDown, Limit )
{
		
		if ( textArea.value.length > Limit )
		{
				
				textArea.value = textArea.value.substring( 0, Limit );
				
		}
		else
		{
				
				countDown.innerHTML = Limit - textArea.value.length;
				
		}
		
}

function FocusBlur( Type, Field, Value ) {
	
		if ( Type == 'focus' ) {
				
				if ( Field.value == Value ) {
						
						Field.value = '';
						
				}
				
		} else {
				
				if ( Field.value == '' ) {
						
						Field.value = Value;
						
				}
				
		}
		
}

function clearInput( textPrice, Value ) {
		
		if ( Value != 0 ) {
				
				document.getElementById( textPrice ).value = '';
				
		}
		
}


var count	= 0;
var id		= 0;

function addRow( elementId ) {
	if (count >= 15) {
		alert( 'U heeft het maximaal aantal velden berijkt.' );
	} else {
		element = document.getElementById( elementId );
		element.innerHTML += '<input type="text" name="url_titles[]" style="width: 38%;" value="" id="title_' + id + '" /> <input type="text" name="urls[]" style="width: 59%;" value="http://" id="url_' + id + '" /> <input type="button" value="X" onclick="javascript:delRow(\'' + elementId + '\', \'' + id + '\');" id="button_' + id + '" /><br id="br_' + id + '" />' + "\n";

		count++;
		id++;
	}
}

function delRow(elementId, rowId) {
	if ( count == 1 ) {
		alert( 'U kunt niet alle velden verwijderen, er blijft er 1 staan.' );
	} else {
		element = document.getElementById( elementId );
		element.removeChild(document.getElementById('title_' + rowId));
		element.removeChild(document.getElementById('url_' + rowId));
		element.removeChild(document.getElementById('button_' + rowId));
		element.removeChild(document.getElementById('br_' + rowId));

		count--;
	}
}