Ⅰ php 在新頁面打開鏈接自動彈出新頁面代碼如何寫
打開結束時調用方法 可以用window.onload
打開新頁面用 window.open
Ⅱ 求php彈出登錄對話框的代碼
Asp的彈窗登錄代碼應該可以放到php代碼里吧,你可以試試,你可以到到網路搜索asp彈登錄窗代碼就ok了。
Ⅲ php中這個彈窗怎麼做
<inputtype="button"onclick="alert('我跟我的小夥伴努力開發中');"value="這是按鈕"/>
像這樣 Html代碼即可
Ⅳ PHP實現JS彈窗
這個不關PHP的事吧,只是服務端語言,如果你是要PHP處理JS的POST還行
Ⅳ php中信息發布成功跳出JS提示框代碼
PHP 彈出JS 提示框示例代碼:
<?php
header("Content-type:text/html;charset=utf-8;");
$conn=mysql_connect("localhost","root","root");
if(!$conn){
die("資料庫連接出錯。".mysql_error());
}
mysql_select_db("test");
$sql="insertintotable(id,name)values(1,'chinawinxp')";
$int=mysql_query($sql);
//信息添加或者發布成功
if($int){
$msg="信息發布成功!";
echo("<scripttype='text/javascript'>");
echo("alert('{$msg}');");
//url跳轉
echo("location.href='test.php';");
echo("</script>");
}
?>
運行效果:
Ⅵ 求php或html點擊鏈接彈出小窗口的代碼!
functionpopup(msg,timer){
var
h=$(document).scrollTop()+$(window).height();
w=$(window).width();
lw=Math.floor(w/2-200/2);
varht=
'<divid="popup"style="display:none;position:absolute;top:100%;left:'+
lw+
'px;text-align:center;background:#f6f9cc;border:1pxsolid#999;width:200px;z-index:1200;box-shadow:005pxrgba(0,0,0,.4)">'+
'<divclass="popup-content"style="padding:15px"></div>'+
'<ahref="javascript:;"class="close-popup"style="display:inline-block;line-height:20px;position:absolute;right:5px;top:5px;width:20px;text-decoration:none;height:20px;font-family:Arial;font-size:28px;font-weight:bold;text-align:center;color:#777;border-radius:50px;">×</a>'+
'</div>';
$('#popup').remove();
$('body').append(ht);
vart;
functionpopout(){
$('#popup').animate({
top:'100%'
},500,function(){
$('#popup').hide();
});
}
$('#popup.close-popup').click(function(){
clearTimeout(t);
popout();
}).hover(function(){
$(this).css({
color:'#000'
})
},function(){
$(this).css({
color:'#777'
})
});
$('#popup.popup-content').html(msg);
$('#popup').show().animate({
top:h/2
},500,function(){
t=setTimeout(function(){
popout();
},timer?parseInt(timer):5500)
});
}
把這段代碼寫在jquery後面,然後直接調用:
popup('內容',3000);//彈出「內容」,3000毫秒後自動關閉
Ⅶ 怎麼在自己指定的網站使用彈窗代碼
在自己的主頁inedx.htm inedx.asp inedx.php上加個JS彈窗代碼就行了,
Ⅷ php點擊鏈接彈出窗口並顯示相應的信息
你那個表格中的數據和你要div彈出的數據一模一樣, 豈不是畫蛇添足?
表格中都看到了, 再點彈個div出來,再看一次???
如果你真需要這樣做, 建議使用jQuery庫和jQuery相關的彈窗插件!
比如:layer(這個可以網路一下就有啊)
使用方法他們網站有介紹
至於彈出的div中的內容, 方法就很多了, 可以ajax請求其他頁面, 也可以獲取當前頁面的內容!
Ⅸ 在PHP頁面中怎樣添加彈出廣告代碼是什麼
PHP網頁打開自動彈出廣告,五秒後自動關閉的網頁代碼如下:
新建網頁寫入代碼即可
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>網頁彈出廣告窗口 boaer.com</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style type="text/css">
body,html{margin:0;padding:0;font-size:12px;font-family:Arial;font:12px/1 Helvetica, Tahoma, Arial, \5b8b\4f53, sans-serif;}
.fixedMask{position:fixed; display:none;top:0; left:0; z-index:999; width:100%; height:100%; background:#000; filter:alpha(opacity=30); opacity:0.3; }
* html { background:url(*) fixed; }
* html body { margin:0; height:100%; }
* html .fixedMask{ position: absolute; left: expression(documentElement.scrollLeft + documentElement.clientWidth - this.offsetWidth); top: expression(documentElement.scrollTop + documentElement.clientHeight - this.offsetHeight); }
#ad{width:570px;height:345px;border:1px solid #333;border-top-width:5px;position:absolute;z-index:9999;left:50%;margin-left:-290px;top:50%;margin-top:-175px;display:none;}
#ad a{display:block;position:absolute;text-decoration:none;right:0;top:0px;font: 12px/1.5 arial;background:#B50000;padding:2px 5px;color:#fff;}
#ad a:hover{background:red;}
</style>
</head>
<body>
<iframe scrolling="no" src="http://boaer.com" style="width:100%;height:1000px"></iframe>
<div id="ad">
<a href="#1" >關閉</a>
<img src="http://home.blueidea.com/attachment/201006/4/194782_1275642410qVBm_m.jpg" alt="" />
</div>
</body>
<script type="text/javascript">
//<![CDATA[
alert('5秒後自動關掉!');
function Mask() {
if (Mask.instance) return Mask.instance;
this.el = document.body.appendChild(document.createElement('DIV'));
this.el.className = 'fixedMask';
Mask.instance = this;
};
Mask.prototype = {
show: function(fn) {
this.el.style.display = 'block';
fn&&fn();
},
hide: function(fn) {
this.el.style.display = 'none';
fn&&fn()
}
};
var x=new Mask();
var AD=document.getElementById('ad');
AD.getElementsByTagName('A')[0].onclick=hide;
x.show(function (){
AD.style.display='block';
});
setTimeout(hide,5000);
function hide(){
x.hide(function (){
AD.style.display='none';
})
}
//]]>
</script>
</html>
Ⅹ PHP如何輸出彈窗
$hello='hello,php';
echo"<script>alert('{$hello}')</script>";