微波EDA网,见证研发工程师的成长!
首页 > 研发问答 > 微波和射频技术 > 电磁仿真讨论 > Ho w to create cookie using js in notepad?

Ho w to create cookie using js in notepad?

时间:03-30 整理:3721RD 点击:
Hi,
I tried creating cookies online..the same code is not working when I did in a notepad..What could be the issue?
please verify the code below!

Code HTML - [expand]
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<!DOCTYPE html>
<html>
<head>
<script>
function view(){
document.cookie="username=hello";
document.write(document.cookie);
 
}
</script></head>
 
<body">
 
<button type="button" onclick="view()">view</button>
 
</body></html>

Copyright © 2017-2020 微波EDA网 版权所有

网站地图

Top