解决wiki和知乎图片无法加载的方法

解决wiki和知乎图片无法加载的方法

Windows10

修改hosts文件权限

  1. 打开文件夹C:\WINDOWS\system32\drivers\etc

  2. 右击hosts文件,单击属性

    Win10怎么修改hosts文件 Win10系统hosts修改不了解决办法

  3. 切换至安全选项卡,选择你的用户名,在选先下勾选修改和写入,单击确认

    Win10怎么修改hosts文件 Win10系统hosts修改不了解决办法

    Win10怎么修改hosts文件 Win10系统hosts修改不了解决办法

修改hosts文件

  1. 使用记事本打开hosts文件

    Win10怎么修改hosts文件 Win10系统hosts修改不了解决办法

  2. 将以下内容粘贴至文件末尾

    208.80.153.224 wikimedia.org
    208.80.153.240 upload.wikimedia.org
    122.225.214.242 pic1.zhimg.com
    
     
    # Github Hosts
    
    # domain: github.com
    140.82.112.4 github.com
    140.82.112.10 nodeload.github.com
    140.82.114.5 api.github.com
    140.82.113.10 codeload.github.com
    185.199.108.133 raw.github.com
    185.199.108.153 training.github.com
    185.199.108.153 assets-cdn.github.com
    185.199.108.153 documentcloud.github.com
    185.199.108.154 help.github.com
    
    # domain: githubstatus.com
    185.199.108.153 githubstatus.com
    
    # domain: fastly.net
    199.232.69.194 github.global.ssl.fastly.net
    
    # domain: githubusercontent.com
    185.199.108.133 raw.githubusercontent.com
    185.199.108.154 pkg-containers.githubusercontent.com
    185.199.108.133 cloud.githubusercontent.com
    185.199.108.133 gist.githubusercontent.com
    185.199.108.133 marketplace-screenshots.githubusercontent.com
    185.199.108.133 repository-images.githubusercontent.com
    185.199.108.133 user-images.githubusercontent.com
    185.199.108.133 desktop.githubusercontent.com
    185.199.108.133 avatars.githubusercontent.com
    185.199.108.133 avatars0.githubusercontent.com
    185.199.108.133 avatars1.githubusercontent.com
    185.199.108.133 avatars2.githubusercontent.com
    185.199.108.133 avatars3.githubusercontent.com
    185.199.108.133 avatars4.githubusercontent.com
    185.199.108.133 avatars5.githubusercontent.com
    185.199.108.133 avatars6.githubusercontent.com
    185.199.108.133 avatars7.githubusercontent.com
    185.199.108.133 avatars8.githubusercontent.com
    # End of the section
    # GitHub End
    

    Win10怎么修改hosts文件 Win10系统hosts修改不了解决办法

  3. 尝试打开wiki,若不能打开重启后重试。

Linux

  1. 打开Terminal,输入sudo vim /etc/hostssudo nano /etc/hostssudo gedit /etc/hosts
  2. 将以下内容写入hosts文件末尾并保存
208.80.153.224 wikimedia.org
208.80.153.240 upload.wikimedia.org
122.225.214.242 pic1.zhimg.com

 
# Github Hosts

# domain: github.com
140.82.112.4 github.com
140.82.112.10 nodeload.github.com
140.82.114.5 api.github.com
140.82.113.10 codeload.github.com
185.199.108.133 raw.github.com
185.199.108.153 training.github.com
185.199.108.153 assets-cdn.github.com
185.199.108.153 documentcloud.github.com
185.199.108.154 help.github.com

# domain: githubstatus.com
185.199.108.153 githubstatus.com

# domain: fastly.net
199.232.69.194 github.global.ssl.fastly.net

# domain: githubusercontent.com
185.199.108.133 raw.githubusercontent.com
185.199.108.154 pkg-containers.githubusercontent.com
185.199.108.133 cloud.githubusercontent.com
185.199.108.133 gist.githubusercontent.com
185.199.108.133 marketplace-screenshots.githubusercontent.com
185.199.108.133 repository-images.githubusercontent.com
185.199.108.133 user-images.githubusercontent.com
185.199.108.133 desktop.githubusercontent.com
185.199.108.133 avatars.githubusercontent.com
185.199.108.133 avatars0.githubusercontent.com
185.199.108.133 avatars1.githubusercontent.com
185.199.108.133 avatars2.githubusercontent.com
185.199.108.133 avatars3.githubusercontent.com
185.199.108.133 avatars4.githubusercontent.com
185.199.108.133 avatars5.githubusercontent.com
185.199.108.133 avatars6.githubusercontent.com
185.199.108.133 avatars7.githubusercontent.com
185.199.108.133 avatars8.githubusercontent.com
# End of the section
# GitHub End
  1. 尝试打开wiki,若不能打开重启后重试。
  • 8
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 8
    评论
JSP(JavaServer Pages)是一种在HTML页面中嵌入Java代码的技术。当用户访问一个JSP页面时,服务器会将其转换为一个Servlet,然后执行Java代码并生成最终的HTML页面返回给用户。 在JSP进入后方法方面,可以使用以下几个途径来实现: 1. JSP指令:可以在JSP页面的开头使用指令 `<%@ page import="com.example.MyClass" %>`,该指令用于导入类和包。在这里,可以根据需要导入需要在页面中使用的类和方法。 2. Servlet的init方法:当JSP被服务器转换为Servlet时,会生成对应的Servlet类。我们可以在Servlet类中重写init方法,并在其中编写需要在JSP进入后立即的代码。例如: ```java public class MyServlet extends HttpServlet { @Override public void init() throws ServletException { // 执行需要在JSP进入后立即的代码 // ... } // ... } ``` 在web.xml文件中,将这个Servlet类配置为JSP的servlet-class。 3. JSP页面的静态代码块:在JSP页面中,可以使用静态代码块来实现页面进入后立即的代码。例如: ```jsp <%! static { // 执行需要在JSP进入后立即的代码 // ... } %> ``` 无论采用哪种方式,进入JSP页面后方法都可以用来进行一些初始化操作,例如获取数据、设置一些初始状态等。这些操作可以在页面完成后立即执行,以便页面得到正确的初始化数据和状态,并提高用户体验。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 8
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值