
var domains = "http://jek4.s137.coreserver.jp/kxs/"; // 最後にスラッシュ入れる
var cartdir = "cart";

function sender(name, pid, price, urls, w, h)
{	
	name = name.replace("&amp;","&");
	name = name.replace("&","＆");
	name = name.replace(",","");
	pid = pid.replace("&amp;","&");
	pid = pid.replace("&","＆");
	pid = pid.replace(",","");
	urls = urls.replace("&amp;","&");
	urls = urls.replace("&","＆");
	urls = urls.replace(",","");
	price = price.replace("&amp;","&");
	price = price.replace("&","＆");
	price = price.replace(",","");
	/* カートの場所（最後にスラッシュを入れる） */
	var flapath = domains + cartdir + "/";
	document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="'+ w +'" height="'+ h +'">');
	document.write('<param name="movie" value="'+ flapath +'sender.swf" />');
	document.write('<param name="quality" value="high" />');
	//document.write('<param name="allowScriptAccess" value="sameDomain" />');
	document.write('<param name="flashvars" value="name='+ name +'&amp;pid='+ pid +'&amp;price='+ price +'&amp;urls='+ urls +'&amp;core='+ flapath +'"/>');
	document.write('<embed src="'+ flapath +'sender.swf" flashvars="name='+ name +'&amp;pid='+ pid +'&amp;price='+ price +'&amp;urls='+ urls +'&amp;core='+ flapath +'" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="'+ w +'" height="'+ h +'"></embed>');
	document.write('</object>');
}
function receiver(w,h)
{
	var domain  = domains;
	var cart = cartdir + "/";
	document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="'+ w +'" height="'+ h +'">');
	document.write('<param name="movie" value="'+ domain + cart +'receiver.swf" />');
	document.write('<param name="quality" value="high" />');
	//document.write('<param name="allowScriptAccess" value="sameDomain" />');
	document.write('<param name="flashvars" value="core='+ domain +'&amp;core3='+ cart +'"/>');
	document.write('<embed src="'+ domain + cart +'receiver.swf" flashvars="core='+ domain +'&amp;core3='+ cart +'" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="'+ w +'" height="'+ h +'"></embed>');
	document.write('</object>');
}
function contact(name,itemid,w,h)
{	
	
	var path = domains + cartdir + "/";
	document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="'+ w +'" height="'+ h +'">');
	document.write('<param name="movie" value="'+ path +'flacont.swf" />');
	document.write('<param name="quality" value="high" />');
	//document.write('<param name="allowScriptAccess" value="sameDomain" />');
	document.write('<param name="flashvars" value="core='+ path +'&amp;core2='+ name +'&amp;core3='+ itemid +'"/>');
	document.write('<embed src="'+ path +'/flacont.swf" flashvars="core='+ path +'&amp;core2='+ name +'&amp;core3='+ itemid +'" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="'+ w +'" height="'+ h +'"></embed>');
	document.write('</object>');
	
}

function test(){
	document.write('ok');
}
