打开带有网址的新窗口

打开带有网址的新窗口

本文介绍了如何使用javascript ...打开带有网址的新窗口?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好朋友,我想在我的链接按钮上单击,使用javascript打开一个新窗口..


我用了它,它会很好用的..

.......
window.open(``http://www.google.com'',``mywindow'',``width=400,height=200'');
.......


但是我想要的是我需要打开一个带有url的窗口,但它不包含http://,这意味着它只能以www.google.com开头,如下所示:

.......
window.open(``www.google.com'',``mywindow'',``width = 400,height = 200'');
.......


请帮我...


谢谢... !!!!
Tejas Vaishnav

Hello friend i want to open a new window on my link button click using javascript..


i used this and it will work well..

.......
window.open(''http://www.google.com'',''mywindow'',''width=400,height=200'');
.......


but what i want is that i need to open a window with url but it will not contain http:// means it will be start with only www.google.com as shown under

.......
window.open(''www.google.com'',''mywindow'',''width=400,height=200'');
.......


please help me...


thank you...!!!!
Tejas Vaishnav

推荐答案



window.open('http://blahblah.com/mypage.aspx', target='new');



编辑=====================

告诉我为什么这是错误的,我将对其进行修复或删除,但不要只是在没有任何解释的情况下将其投票1.



EDIT =======================

Tell me why this is wrong, and I''ll either fix it or delete it, but don''t just vote it 1 without an explanation.


这篇关于如何使用javascript ...打开带有网址的新窗口?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-30 23:25