/*
 * For Simple Modal Script
 *
 * Copyright (c) 2009 PAV - http://ipav.ru
 *
 * Licensed under the MIT license:
 *   http://www.opensource.org/licenses/mit-license.php
 *
 * Revision: $Id: fullsizecbox.js 1 2009-11-09 03:39 (UTC+3) PAV $
 *
 */

$(document).ready(function () {
if (window.navigator.appVersion.indexOf('Chrome') == -1) {
	$('#fullsizecbox input.basic, #fullsizecbox a.basic').click(function (e) {
		e.preventDefault();
		$('#fullsizecbox-content').modal({
			containerCss:{
				height:530
			},
			onShow: function (dialog) {
				dialog.data.html($('#cboxdiv').html());
				$('#cboxdiv').html('<img src="/theme/images/full_size_cbox.png" style="width:215px;height:510px;text-align:center;" alt="" />');
			},
			onClose: function (dialog) {
				$('#cboxdiv').html(dialog.data.html());
				dialog.data.html('');
				$.modal.close();
			}
		});
	});
} else {
	$('#fullsizecbox').hide();
}
if (window.navigator.appVersion.indexOf('Chrome') == -1) {
	$('#fullsizecbox input.basic, #fullsizecbox a.basic').click(function (e) {
		e.preventDefault();
		$('#fullsizecbox-content').modal({
			containerCss:{
				height:530
			},
			onShow: function (dialog) {
				dialog.data.html($('#cboxdiv').html());
				$('#cboxdiv').html('<img src="/theme/images/full_size_cbox.png" style="width:215px;height:510px;text-align:center;" alt="" />');
			},
			onClose: function (dialog) {
				$('#cboxdiv').html(dialog.data.html());
				dialog.data.html('');
				$.modal.close();
			}
		});
	});
} else {
	$('#fullsizecbox').hide();
}

  $('#feedbox input.basic, #feedbox a.basic').click(function (e) {
    e.preventDefault();
    $('#feedbox-content').modal({
    		containerCss:{
    			width:520,
				height:376
			},
			onShow: function (dialog) {
				dialog.data.html('<iframe src="/feedbox/feedbox.php" width="510" height="376" frameborder="0" marginheight="0" marginwidth="0" scrolling="auto" allowtransparency="yes" name="cboxmain" id="cboxmain"></iframe> ');
			},
			onClose: function (dialog) {
				dialog.data.html('');
				$.modal.close();
			}
    });
  });
});
