function RandomAd(x) {
              f =23;  //fは掲載する広告数

              var Num = new Array(f - 1);
              var Chk = new Array(f - 1);
              var Mess = new Array(f - 1);

//***ここに広告表示HTMLの配列作成




Mess[0] = '<table bgcolor=#996666 border=0><tr><td><table bgcolor=#FFFFFF border=0 cellpadding=7 width=500><tr><td valign=top width=360><span style="font-size: 10pt;"><b><a href="http://px.a8.net/svt/ejp?a8mat=1C89HU+OESKY+5WS+C1DUQ&a8ejpredirect=http%3A%2F%2Fwww.rakuten.co.jp%2Fosharewalker%2Findex.html" target="_blank">osharewalker</a><img border="0" width="1" height="1" src="http://www10.a8.net/0.gif?a8mat=1C89HU+OESKY+5WS+C1DUQ" alt=""><br></b><img src="http://net-shop.web.infoseek.co.jp/img/good.gif"><img src="http://net-shop.web.infoseek.co.jp/cgi-bin/netshop/img/m1.gif"><font color="#777777"><br><br>今日からオシャレスタート♪あなたのオシャレサポーター☆<br>こだわりセレクトショップ<br></td><td valign="bottom" width="130"><span style="font-size: 8pt;"><a href="http://px.a8.net/svt/ejp?a8mat=1C89HU+OESKY+5WS+BWVTD&a8ejpredirect=http%3A%2F%2Fwww.rakuten.co.jp%2Fosharewalker%2F" target="_blank"><img border="0" alt="" src="http://thumbnail.image.rakuten.co.jp/@0_mall/osharewalker/cabinet/image4/img55721116.jpg?_ex=120x120"></a><img border="0" width="1" height="1" src="http://www12.a8.net/0.gif?a8mat=1C89HU+OESKY+5WS+BWVTD" alt=""></td></tr><tr><td colspan="3"><p align="right"><span style="font-size: 8pt;"> [<a href="http://net-shop.web.infoseek.co.jp/cgi-bin/melmaga/kou0.html#bb" target="_blank">ここに広告を掲載する</a>]</span></p></td></tr></table></td></tr></table>';
Mess[1] = '<table bgcolor=#996666 border=0><tr><td><table bgcolor=#FFFFFF border=0 cellpadding=7 width=500><tr><td valign=top width=360><span style="font-size: 10pt;"><b><a href="http://px.a8.net/svt/ejp?a8mat=1HNB5K+D1R12Q+10CW+1BM8YQ&a8ejpredirect=http%3A%2F%2Fwww.lamaree.jp%2F" target="_blank">オリジナル革製品通販サイト「ラマーレ」</a><img border="0" width="1" height="1" src="http://www11.a8.net/0.gif?a8mat=1HNB5K+D1R12Q+10CW+1BM8YQ" alt=""><br></b><img src="http://net-shop.web.infoseek.co.jp/img/good.gif"><img src="http://net-shop.web.infoseek.co.jp/cgi-bin/netshop/img/m1.gif"><font color="#777777"><br><br>大航海時代の開拓者たちが一つにした地球を舞台に、グローバルな角度から伝統的な革製品を見つめなおし、新しいオリジナル革製品を生み出しています。<br></td><td valign="bottom" width="130"><span style="font-size: 8pt;"><a href="http://px.a8.net/svt/ejp?a8mat=1HNB5K+D1R12Q+10CW+1BMGOH&a8ejpredirect=http%3A%2F%2Fwww.lamaree.jp%2Fpl_wallet_3.htm" target="_blank"><img border="0" alt="" src="http://www.lamaree.jp/img/img-series/l04.jpg" width="100" height="100"></a><img border="0" width="1" height="1" src="http://www17.a8.net/0.gif?a8mat=1HNB5K+D1R12Q+10CW+1BMGOH" alt=""></td></tr><tr><td colspan="3"><p align="right"><span style="font-size: 8pt;"> [<a href="http://net-shop.web.infoseek.co.jp/cgi-bin/melmaga/kou0.html#bb" target="_blank">ここに広告を掲載する</a>]</span></p></td></tr></table></td></tr></table>';
Mess[2] = '<table bgcolor=#996666 border=0><tr><td><table bgcolor=#FFFFFF border=0 cellpadding=7 width=500><tr><td valign=top width=360><span style="font-size: 10pt;"><b><a href="http://px.a8.net/svt/ejp?a8mat=1C89HU+OEU4I+5WS+C1DUQ&a8ejpredirect=http%3A%2F%2Fwww.rakuten.co.jp%2Ffunky-fruit%2F" target="_blank">FUNKY FRUIT</a><img border="0" width="1" height="1" src="http://www10.a8.net/0.gif?a8mat=1C89HU+OEU4I+5WS+C1DUQ" alt=""><br></b><img src="http://net-shop.web.infoseek.co.jp/img/good.gif"><img src="http://net-shop.web.infoseek.co.jp/cgi-bin/netshop/img/m1.gif"><font color="#777777"><br><br>ガーリーカジュアルと古着テイストをMIXさせたボーダレスな品揃え<br></td><td valign="bottom" width="130"><span style="font-size: 8pt;"><a href="http://px.a8.net/svt/ejp?a8mat=1C89HU+OEU4I+5WS+BWVTD&a8ejpredirect=http%3A%2F%2Fwww.rakuten.co.jp%2Ffunky-fruit%2F" target="_blank"><img border="0" width="120" height="120" alt="" src="https://thumbnail.image.rakuten.co.jp/@0_mall/funky-fruit/cabinet/00889540/img55703070.jpg?_ex=138x138&s=2&r=1"></a><img border="0" width="1" height="1" src="http://www16.a8.net/0.gif?a8mat=1C89HU+OEU4I+5WS+BWVTD" alt=""></td></tr><tr><td colspan="3"><p align="right"><span style="font-size: 8pt;"> [<a href="http://net-shop.web.infoseek.co.jp/cgi-bin/melmaga/kou0.html#bb" target="_blank">ここに広告を掲載する</a>]</span></p></td></tr></table></td></tr></table>';
Mess[3] = '<table bgcolor=#996666 border=0><tr><td><table bgcolor=#FFFFFF border=0 cellpadding=7 width=500><tr><td valign=top width=360><span style="font-size: 10pt;"><b><a href="http://px.a8.net/svt/ejp?a8mat=1C89HU+OEU4I+5WS+C1DUQ&a8ejpredirect=http%3A%2F%2Fwww.rakuten.ne.jp%2Fgold%2Fsalus%2F" target="_blank">salus</a><img border="0" width="1" height="1" src="http://www10.a8.net/0.gif?a8mat=1C89HU+OEU4I+5WS+C1DUQ" alt=""><br></b><img src="http://net-shop.web.infoseek.co.jp/img/good.gif"><img src="http://net-shop.web.infoseek.co.jp/cgi-bin/netshop/img/m1.gif"><font color="#777777"><br><br>最新ファッションアイテム満載です。パンプス、サンダル、ワンピース、ブーツ、財布、アクセサリー、雑貨まで、激安価格にて販売中！SCawaii、ViVi、JJ、PINKY、Rayなどの雑誌掲載商品も多数で、米本さやか等有名読者モデルが愛用するショッピングサイトです。<br></td><td valign="bottom" width="130"><span style="font-size: 8pt;"><a href="http://px.a8.net/svt/ejp?a8mat=1C89HU+OEU4I+5WS+BWVTD&a8ejpredirect=http%3A%2F%2Fwww.rakuten.ne.jp%2Fgold%2Fsalus%2F" target="_blank"><img border="0" width="120" height="120" alt="" src="https://thumbnail.image.rakuten.co.jp/@0_mall/salus/cabinet/sk/sk-21-54-l9003966-00.jpg?_ex=130x130&s=0&r=1"></a><img border="0" width="1" height="1" src="http://www19.a8.net/0.gif?a8mat=1C89HU+OEU4I+5WS+BWVTD" alt=""></td></tr><tr><td colspan="3"><p align="right"><span style="font-size: 8pt;"> [<a href="http://net-shop.web.infoseek.co.jp/cgi-bin/melmaga/kou0.html#bb" target="_blank">ここに広告を掲載する</a>]</span></p></td></tr></table></td></tr></table>';
Mess[4] = '<a href="http://hb.afl.rakuten.co.jp/hsc/0a82ca41.75becc46.0a5a06ae.183b28d0/" target="_blank"><img src="http://hbb.afl.rakuten.co.jp/hsb/0a82ca41.75becc46.0a5a06ae.183b28d0/" border="0"></a>';
Mess[5] = '<a href="http://hb.afl.rakuten.co.jp/hsc/0a5a06a8.46fb79f6.0a5a06ae.183b28d0/" target="_blank"><img src="http://hbb.afl.rakuten.co.jp/hsb/0a5a06a8.46fb79f6.0a5a06ae.183b28d0/" border="0"></a>';
Mess[6] = '<a href="http://hb.afl.rakuten.co.jp/hsc/0ad959f9.d467eeb4.0a5a06ae.183b28d0/" target="_blank"><img src="http://hbb.afl.rakuten.co.jp/hsb/0ad959f9.d467eeb4.0a5a06ae.183b28d0/" border="0"></a>';
Mess[7] = '<a href="http://hb.afl.rakuten.co.jp/hsc/0a82cb07.9f1ac92d.0a5a06ae.183b28d0/" target="_blank"><img src="http://hbb.afl.rakuten.co.jp/hsb/0a82cb07.9f1ac92d.0a5a06ae.183b28d0/" border="0"></a>';
Mess[8] = '<a href="http://hb.afl.rakuten.co.jp/hsc/0a82caed.73c33d11.0a5a06ae.183b28d0/" target="_blank"><img src="http://hbb.afl.rakuten.co.jp/hsb/0a82caed.73c33d11.0a5a06ae.183b28d0/" border="0"></a>';
Mess[9] = '<a href="http://hb.afl.rakuten.co.jp/hsc/0a7f0018.c65578dd.0a5a06ae.183b28d0/" target="_blank"><img src="http://hbb.afl.rakuten.co.jp/hsb/0a7f0018.c65578dd.0a5a06ae.183b28d0/" border="0"></a>';
Mess[10] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=100695.10000349&type=4&subid=0"><IMG alt="スタイライフ" border="0" src="http://www.stylife.co.jp/mail-mag/banner/090317_468x60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=100695.10000349&type=4&subid=0"><br><br><a href="http://px.a8.net/svt/ejp?a8mat=1I4U6Q+2OG8S2+5GO+TVYKH" target="_blank"><img border="0" width="468" height="60" alt="" src="http://www29.a8.net/svt/bgt?aid=090925010162&wid=001&eno=01&mid=s00000000708005020000&mc=1"></a><img border="0" width="1" height="1" src="http://www10.a8.net/0.gif?a8mat=1I4U6Q+2OG8S2+5GO+TVYKH" alt="">';
Mess[11] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=100695.10000208&type=4&subid=0"><IMG alt="スタイライフ" border="0" src="http://www.stylife.co.jp/mail-mag/banner/081105_468x60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=100695.10000208&type=4&subid=0"><br><br><a href="http://px.a8.net/svt/ejp?a8mat=1I4U6Q+3B2PRM+1W5M+5YZ75" target="_blank"><img border="0" width="468" height="60" alt="" src="http://www28.a8.net/svt/bgt?aid=090925010200&wid=001&eno=01&mid=s00000008833001003000&mc=1"></a><img border="0" width="1" height="1" src="http://www14.a8.net/0.gif?a8mat=1I4U6Q+3B2PRM+1W5M+5YZ75" alt="">';
Mess[12] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=100695.10000442&type=4&subid=0"><IMG alt="スタイライフ" border="0" src="http://www.stylife.co.jp/mail-mag/banner/090831_468x60.jpg "></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=100695.10000442&type=4&subid=0"><br><br><a href="http://px.a8.net/svt/ejp?a8mat=1I4U6Q+3CV0KY+LNG+15R4NL" target="_blank"><img border="0" width="467" height="60" alt="" src="http://www26.a8.net/svt/bgt?aid=090925010203&wid=001&eno=01&mid=s00000002806007013000&mc=1"></a><img border="0" width="1" height="1" src="http://www11.a8.net/0.gif?a8mat=1I4U6Q+3CV0KY+LNG+15R4NL" alt="">';
Mess[13] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=100695.10000442&type=4&subid=0"><IMG alt="スタイライフ" border="0" src="http://www.stylife.co.jp/mail-mag/banner/090831_468x60.jpg "></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=100695.10000442&type=4&subid=0"><br><br><a href="http://px.a8.net/svt/ejp?a8mat=1I4U6Q+3C9KZ6+REE+NZROH" target="_blank"><img border="0" width="468" height="60" alt="" src="http://www27.a8.net/svt/bgt?aid=090925010202&wid=001&eno=01&mid=s00000003551004030000&mc=1"></a><img border="0" width="1" height="1" src="http://www15.a8.net/0.gif?a8mat=1I4U6Q+3C9KZ6+REE+NZROH" alt="">';
Mess[14] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=130577.10002856&type=4&subid=0"><IMG alt="ニッセン" border="0" src="http://www.nissen.co.jp/other_site/banner/2007fal/inner_kyoukasyo_b.gif"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=130577.10002856&type=4&subid=0"><br><br><a href="http://px.a8.net/svt/ejp?a8mat=1I4U6Q+2XZ6GI+XIY+ZRIB5" target="_blank"><img border="0" width="468" height="60" alt="" src="http://www21.a8.net/svt/bgt?aid=090925010178&wid=001&eno=01&mid=s00000004345006007000&mc=1"></a><img border="0" width="1" height="1" src="http://www16.a8.net/0.gif?a8mat=1I4U6Q+2XZ6GI+XIY+ZRIB5" alt="">';
Mess[15] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=130577.10002024&type=4&subid=0"><IMG alt="ニッセン" border="0" src="http://www.nissen.co.jp/other_site/banner/2007_mid/iifood/iifood_sale_b.gif"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=130577.10002024&type=4&subid=0"><br><br><a href="http://px.a8.net/svt/ejp?a8mat=1I4U6Q+3AHA5U+1HKW+4YNBS1" target="_blank"><img border="0" width="468" height="60" alt="" src="http://www29.a8.net/svt/bgt?aid=090925010199&wid=001&eno=01&mid=s00000006944030006000&mc=1"></a><img border="0" width="1" height="1" src="http://www13.a8.net/0.gif?a8mat=1I4U6Q+3AHA5U+1HKW+4YNBS1" alt="">';
Mess[16] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=130577.10001034&type=4&subid=0"><IMG alt="ニッセン" border="0" src="http://www.nissen.co.jp/other_site/banner/corner/sale_b.gif"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=130577.10001034&type=4&subid=0"><br><br><a href="http://px.a8.net/svt/ejp?a8mat=1I4U6Q+2UEKTU+1WFW+5ZMCH" target="_blank"><img border="0" width="468" height="60" alt="" src="http://www28.a8.net/svt/bgt?aid=090925010172&wid=001&eno=01&mid=s00000008870001006000&mc=1"></a><img border="0" width="1" height="1" src="http://www10.a8.net/0.gif?a8mat=1I4U6Q+2UEKTU+1WFW+5ZMCH" alt="">';
Mess[17] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=125782.10000315&type=4&subid=0"><IMG alt="IMAGEnet" border="0" src="http://pic.st-image.com/affiliate/linkshare/banner/outer/498_100.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=125782.10000315&type=4&subid=0">';
Mess[18] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=101174.10001611&type=4&subid=0"><IMG alt="セシール - ふっくらさんのおしゃれブランドplump" border="0" src="http://www.cecile.co.jp/aff/lsimg/0807plump_468_60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=101174.10001611&type=4&subid=0"><br><br><a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=125782.10000456&type=4&subid=0"><IMG alt="IMAGEnet" border="0" src="http://pic.image-net.info/affiliate/linkshare/banner/ranking/468_60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=125782.10000456&type=4&subid=0">';
Mess[19] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=101174.10001793&type=4&subid=0"><IMG alt="セシール" border="0" src="http://www.cecile.co.jp/aff/lsimg/0811cecile_camp_468_60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=101174.10001793&type=4&subid=0"><br><br><a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=125782.10000413&type=4&subid=0"><IMG alt="IMAGEnet" border="0" src="http://pic.image-net.info/affiliate/linkshare/banner/onepiece/468_60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=125782.10000413&type=4&subid=0">';
Mess[20] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=101174.10001787&type=4&subid=0"><IMG alt="セシール - マタニティ＆ベビー" border="0" src="http://www.cecile.co.jp/aff/lsimg/0810baby_468_60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=101174.10001787&type=4&subid=0"><br><br><a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=125782.10000335&type=4&subid=0"><IMG alt="IMAGEnet" border="0" src="http://pic.st-image.com/affiliate/linkshare/banner/onepiece/498_100.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=125782.10000335&type=4&subid=0">';
Mess[21] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=101174.10001325&type=4&subid=0"><IMG alt="セシール - シークレットセール" border="0" src="http://www.cecile.co.jp/aff/lsimg/0712secret_468_60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=101174.10001325&type=4&subid=0"><br><br><a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=125782.10000177&type=4&subid=0"><IMG alt="IMAGEnet" border="0" src="http://pic.st-image.com/affiliate/linkshare/banner/web_gentei/468_60.jpg"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=125782.10000177&type=4&subid=0">';
Mess[22] = '<a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=101174.10000354&type=4&subid=0"><IMG alt="セシール" border="0" src="http://www.cecile.co.jp/aff/lsimg/sale_468_60.gif"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=101174.10000354&type=4&subid=0"><br><br><a target= new  href="http://click.linksynergy.com/fs-bin/click?id=MbWXNJtm4J4&offerid=101174.10001989&type=4&subid=0"><IMG alt="セシール - バーゲンセール" border="0" src="http://www.cecile.co.jp/aff/lsimg/sale2_468_60.gif"></a><IMG border="0" width="1" height="1" src="http://ad.linksynergy.com/fs-bin/show?id=MbWXNJtm4J4&bids=101174.10001989&type=4&subid=0">';



//5-8***09月20日まで掲載



//<table bgcolor=#996666 border=0><tr><td><table bgcolor=#FFFFFF border=0 cellpadding=7 width=500><tr><td valign=top width=360><span style="font-size: 10pt;"><b>
//サイト名
//<br></b><img src="http://net-shop.web.infoseek.co.jp/img/good.gif"><img src="http://net-shop.web.infoseek.co.jp/cgi-bin/netshop/img/m1.gif"><font color="#777777"><br><br>
//コメント
//<br></td><td valign="bottom" width="130"><span style="font-size: 8pt;">
//画像
//</td></tr><tr><td colspan="3"><p align="right"><span style="font-size: 8pt;"> [<a href="http://net-shop.web.infoseek.co.jp/cgi-bin/melmaga/kou0.html#bb" target="_blank">ここに広告を掲載する</a>]</span></p></td></tr></table></td></tr></table>';









       //***ランダムで０〜ｆ−１の値を並べ替え
              for (i=0;i<f;i++) //
              {
              Num[i] = Math.floor(Math.random()*f);
              if (Chk[Num[i]] == 1){
              while(Chk[Num[i]] == 1){
              Num[i] = Math.floor(Math.random()*f);
              }
              Chk[Num[i]] = 1;
              }
              else {
              Chk[Num[i]] = 1;
              }
              }
              
              //ＨＴＭＬ作成部分
              document.write('<font size="-1">');
              for (i=0;i<x;i++) //
              {
              document.write(Mess[Num[i]]);
              document.write('<!---->');
              document.write("<!---->");
              }

              document.write('</font>');
}
