在https中无法使用Javascript警报 [英] Not Working Javascript alert in https

查看:72
本文介绍了在https中无法使用Javascript警报的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好我在https中尝试了简单的javascript +表单。但是javascrip警报在某些https中不起作用。任何人都可以知道为什么它不工作


我的示例代码是

Hi I tried simple javascript + form in https. But javascrip alert is not working in some https. Can any one know that why it is not working

My sample code is

展开 | 选择 | 换行 | 行号

推荐答案

您希望它何时提醒?为什么在上一次返回后你的onload返回false?无论如何,onload都不需要返回语句。
When are you expecting it to alert? Why do you have a return false in onload after a previous return? onload doesn''t require a return statement anyway.


有一件事是你正在使用return hi()但是hi函数没有返回任何东西。
well one thing is you are using return hi() but the hi function isn''t returning anything.





不需要任何返回值。只是我想得到警报。为什么这是需要的是我有一个项目,该项目警报在http://工作,而不是在https://

。所以我只是尝试这个简单的例子,我不能成功,可以告诉我为什么这样做?


Am not need any return value. Just i want to get the alert. Why this is need is am have one project , on that project alert is working in http:// and not work in https://
. So am just trying with this simple example and i could not succeed , can tell me why this?


这篇关于在https中无法使用Javascript警报的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆