原网址:http://blog.csdn.net/ssy_shandong/article/details/9328985
1.从一个jsp页面跳转到另一个jsp页面时的参数传递
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <form action="getinfo.jsp">
- <input type="text" name="name">
- <input type="submit" value="Enter" name="submit">
- </form>
- </body>
- </html>
getinfo.jsp页面代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <p>获取文本框提交的信息:
- <%
- String textContent = request.getParameter("name");
- %>
- <br/>
- <%=textContent%>
- </p>获取按钮的名字:
- <%
- String buttonName = request.getParameter("submit");
- %>
- <br/>
- <%=buttonName%>
- </body>
- </html>
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <form action="session2.jsp" method="post">
- 请输入您的姓名:
- <input type="text" name="thename">
- <input type="submit" value="submit">
- </form>
- </body>
- </html>
session2.jsp通过request对象提取session1.jsp表单中的thename值,并将其保存到session对象中,session2.jsp代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- String name = request.getParameter("thename");
- session.setAttribute("thename",name);
- %>
- 您的姓名是:<%=name%>
- <p>
- <form action="session3.jsp?pwd=123456" method="post">
- 您喜欢吃什么?
- <input type="text" name="food"/>
- <p>
- <input type="submit" value="submit">
- </form>
- </body>
- </html>
session3.jsp的主要任务是显示结果,它从session对象提取thename的值并显示它,以证明在多个页面中可以通过session对象存储和维持信息,session3.jsp代码如下:
- <pre name="code" class="java"><%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- String food = request.getParameter("food");
- String name = (String)session.getAttribute("thename");
- String pwd = request.getParameter("pwd");
- %>
- 您的姓名是:<%=name%>
- <p>
- 您喜欢吃:<%=food%>
- <p>
- 您的密码是:<%=pwd%>
- </body>
- </html></pre>
- <pre></pre>
- <pre></pre>
- <pre></pre>
- <pre></pre>
- <pre></pre>
- <pre></pre>
- <pre></pre>
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <form action="hidden.jsp" method="post" name="form1">
- <!-- 隐藏字段,系统时间,并转换为毫秒数 -->
- <input type="hidden" name="time" value="<%=new java.util.Date()%>">
- <p>
- 请输入您的姓名:<input type="text" name="name">
- </p>
- <input type="submit" name="submit" value="submit">
- </form>
- </body>
- </html>
显示隐藏空间信息的hidden.jsp代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- String name = request.getParameter("name");
- String date = request.getParameter("time");
- %>
- <p>您的姓名是:
- <%=name %>
- </p>
- <p>提交时的系统时间为:
- <%=date %>
- </p>
- </body>
- </html>
程序运行结果如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <%
- int PageCount = 15;
- %>
- <html>
- <body>
- <table>
- <tr>
- <td>
- <a href=showpage.jsp?ToPage=<%=1%>>到第1页</a>
- </td>
- <td>
- <a href=showpage.jsp?ToPage=<%=PageCount%>>到最后一页</a>
- </td>
- </tr>
- </table>
- </body>
- </html>
接收显示分页showpage.jsp代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- String toPage = request.getParameter("ToPage");
- out.println("第" + toPage + "页");
- %>
- </body>
- </html>
运行结果如下:
2.jsp页面传递参数给servlet
- package com.shi.servlet;
- import java.io.IOException;
- import javax.servlet.ServletException;
- import javax.servlet.http.HttpServlet;
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpServletResponse;
- /**
- * 本类用来获得表单请求信息,并根据请求信息转发页面
- */
- public class ForwardServlet extends HttpServlet
- {
- private static final long serialVersionUID = 1L;
- /**
- * 构造函数
- */
- public ForwardServlet()
- {
- super();
- }
- /**
- * 初始化
- */
- public void init() throws ServletException
- {}
- /**
- * doGet()方法
- */
- public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- doPost(request, response);
- }
- /**
- * doPost()方法
- */
- public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- String name = request.getParameter("name");
- String pwd = request.getParameter("pwd");
- if((name!=null && !name.equals("")) && (pwd!=null && !pwd.equals("")))
- {
- if(name.equals("mr")&&pwd.equals("123"))
- {
- request.getRequestDispatcher("success.jsp").forward(request, response);
- }
- else
- {
- request.getRequestDispatcher("error.jsp").forward(request, response);
- }
- }
- }
- /**
- * 销毁
- */
- public void destroy()
- {
- super.destroy();
- }
- }
在web.xml中配置ForwardServlet类,代码如下:
- <?xml version="1.0" encoding="GB2312"?>
- <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
- http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
- <!-- 配置servlet -->
- <servlet>
- <servlet-name>ForwardServlet</servlet-name>
- <servlet-class>com.shi.servlet.ForwardServlet</servlet-class>
- </servlet>
- <servlet-mapping>
- <servlet-name>ForwardServlet</servlet-name>
- <url-pattern>/forward</url-pattern>
- </servlet-mapping>
- <welcome-file-list>
- <welcome-file>index.jsp</welcome-file>
- </welcome-file-list>
- </web-app>
新建index.jsp,其中<form>中的action属性值为Servlet类在web.xml中配置的url,提交方式为post,代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <form action="forward" method="post">
- <table align="center">
- <tr>
- <td>用户名:</td>
- <td>
- <input type="text" name="name"/>
- </td>
- </tr>
- <tr>
- <td>密码:</td>
- <td>
- <input type="password" name="pwd"/>
- </td>
- </tr>
- <tr>
- <td colspan="2">
- <input type="submit" value="登录"/>
- </td>
- </tr>
- </table>
- </form>
- </body>
- </html>
登录成功页面success.jsp,代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- 欢迎<%=request.getParameter("name") %>,登录成功!
- </body>
- </html>
程序的运行结果图5所示:
(2)使用session对象,url,form表单传递参数
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- session.setAttribute("testSession","Hello session");
- request.setAttribute("testRequest","Hello request");
- %>
- <a href="http://localhost:8080/086/jsp2servlet?hrefAction=toServlet">单击此处</a>
- <form action="jsp2servlet?action=toServlet" method="post" name="form1">
- <input type="text" name="username"/>
- <input type="submit" value="submit"/>
- </form>
- </body>
- </html>
在Jsp2Servlet中接收jsp页面中传递的参数并将其显示,代码如下:
- package com.shi.servlet;
- import java.io.IOException;
- import java.io.PrintWriter;
- import javax.servlet.ServletException;
- import javax.servlet.http.HttpServlet;
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpServletResponse;
- public class Jsp2Servlet extends HttpServlet
- {
- /**
- * 自动生成
- */
- private static final long serialVersionUID = 1L;
- /**
- * 构造函数
- */
- public Jsp2Servlet()
- {
- super();
- }
- /**
- * 初始化
- */
- public void init()
- {}
- /**
- * doGet()
- */
- public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- doPost(request, response);
- }
- /**
- * doPost()
- */
- public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- String strSession = (String)request.getSession().getAttribute("testSession");
- String strRequest = (String)request.getAttribute("testRequest");
- String strHref = request.getParameter("hrefAction");
- String strForm = request.getParameter("action");
- String username = request.getParameter("username");
- PrintWriter out = response.getWriter();
- out.println("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">");
- out.println("<html>");
- out.println("<body>");
- out.println("保存到session中的内容: " + strSession + "<br>");
- out.println("保存到request中的内容:" + strRequest + "<br>");
- out.println("超链接中传递的参数值为:" + strHref + "<br>");
- out.println("form表单中传递的action值为:" + strForm + "<br>");
- out.println("form表单内input标签中username的值: " + username + "<br>");
- out.println("</body>");
- out.println("</html>");
- }
- /**
- * 销毁
- */
- public void destroy()
- {
- super.destroy();
- }
- }
程序运行结果如图6所示:
3.从servlet到jsp页面中传递参数
- package com.shi.servlet;
- import java.io.IOException;
- import javax.servlet.ServletException;
- import javax.servlet.http.HttpServlet;
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpServletResponse;
- public class Servlet2Jsp extends HttpServlet
- {
- /**
- * 自动生成
- */
- private static final long serialVersionUID = 1L;
- /**
- * 构造函数
- */
- public Servlet2Jsp()
- {
- super();
- }
- /**
- * 初始化
- */
- public void init()
- {}
- /**
- * doGet()
- */
- public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- doPost(request, response);
- }
- /**
- * doPost()
- */
- public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- String url = "result.jsp?first=传递第一个参数&second=传递第二个参数";
- String strRequest = "request传值";
- String strSession = "session传值";
- request.setAttribute("strRequest", strRequest);
- request.getSession().setAttribute("strSession", strSession);
- /**
- * 客户端跳转:效率低
- * session范围属性,url中的参数会传递下去,request范围属性不传递
- */
- //response.sendRedirect(url);
- /**
- * 服务器端跳转:常用,效率高
- * request范围属性,session范围属性,url中的参数会传递
- */
- request.getRequestDispatcher(url).forward(request, response);
- }
- /**
- * 销毁
- */
- public void destroy()
- {
- super.destroy();
- }
- }
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- String strURL = request.getParameter("first");
- String strRequest = (String)request.getAttribute("strRequest");
- String strSession = (String)request.getSession().getAttribute("strSession");
- %>
- <p>
- URL中取得的属性值为:<%=strURL%>
- </p>
- <p>
- request中取得的属性值为:<%=strRequest%>
- </p>
- <p>
- session中取得的属性值为:<%=strSession%>
- </p>
- </body>
- </html>
程序的运行结果如图7所示:
4.从一个servlet到另一个servlet时的参数传递
- package com.shi.servlet;
- import java.io.IOException;
- import java.io.PrintWriter;
- import javax.servlet.ServletException;
- import javax.servlet.http.HttpServlet;
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpServletResponse;
- public class ServletA extends HttpServlet
- {
- /**
- * 自动生成
- */
- private static final long serialVersionUID = 1L;
- /**
- * 构造函数
- */
- public ServletA()
- {
- super();
- }
- /**
- * 初始化
- */
- public void init()
- {}
- /**
- * doGet()
- */
- public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- doPost(request, response);
- }
- /**
- * doPost()
- */
- public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- response.setContentType("text/html");
- PrintWriter out = response.getWriter();
- String name = "hello, servlet";
- out.println("<html>");
- out.println("<body>");
- /**
- * 超链接
- */
- out.println("<a href='ServletB?name="+name+"'>this is a test</a>");
- /**
- * 表单
- */
- out.println("<form action='ServletB' method='post'>");
- out.println("用户名:");
- out.println("<input type='text' name='username'>");
- out.println("<input type='submit' vlue='提交'>");
- out.println("</form>");
- out.println("</body>");
- out.println("</html>");
- out.flush();
- }
- /**
- * 销毁
- */
- public void destroy()
- {
- super.destroy();
- }
- }
接收servlet中传递参数的代码如下:
- package com.shi.servlet;
- import java.io.IOException;
- import java.io.PrintWriter;
- import javax.servlet.ServletException;
- import javax.servlet.http.HttpServlet;
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpServletResponse;
- public class ServletB extends HttpServlet
- {
- /**
- * 自动生成
- */
- private static final long serialVersionUID = 1L;
- /**
- * 构造函数
- */
- public ServletB()
- {
- super();
- }
- /**
- * 初始化
- */
- public void init()
- {}
- /**
- * doGet()
- */
- public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- doPost(request, response);
- }
- /**
- * doPost()
- */
- public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- String name = request.getParameter("name");
- String username = request.getParameter("username");
- response.setContentType("text/html;charset=gb2312");
- PrintWriter out = response.getWriter();
- out.println("<html>");
- out.println("<body>");
- out.println("超链接传递的参数值为:" + name);
- out.println("form表单中提交的用户名为:" + username);
- out.println("</body>");
- out.println("</html>");
- out.flush();
- }
- /**
- * 销毁
- */
- public void destroy()
- {
- super.destroy();
- }
- }
程序运行结果如图8所示:
(2)使用setAttribute()和getAttribute()方法传递参数
- package com.shi.servlet;
- import java.io.IOException;
- import java.io.PrintWriter;
- import javax.servlet.ServletException;
- import javax.servlet.http.HttpServlet;
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpServletResponse;
- public class ServletA extends HttpServlet
- {
- /**
- * 自动生成
- */
- private static final long serialVersionUID = 1L;
- /**
- * 构造函数
- */
- public ServletA()
- {
- super();
- }
- /**
- * 初始化
- */
- public void init()
- {}
- /**
- * doGet()
- */
- public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- doPost(request, response);
- }
- /**
- * doPost()
- */
- public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- /**
- * setAttribute()和getAttribute()
- */
- String data = "This is a test, we need more test for this";
- request.setAttribute("strAtt", data);
- request.getRequestDispatcher("/ServletB").forward(request, response);
- }
- /**
- * 销毁
- */
- public void destroy()
- {
- super.destroy();
- }
- }
获取参数的ServletB代码如下:
- package com.shi.servlet;
- import java.io.IOException;
- import java.io.PrintWriter;
- import javax.servlet.ServletException;
- import javax.servlet.http.HttpServlet;
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpServletResponse;
- public class ServletB extends HttpServlet
- {
- /**
- * 自动生成
- */
- private static final long serialVersionUID = 1L;
- /**
- * 构造函数
- */
- public ServletB()
- {
- super();
- }
- /**
- * 初始化
- */
- public void init()
- {}
- /**
- * doGet()
- */
- public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- doPost(request, response);
- }
- /**
- * doPost()
- */
- public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
- {
- String strAtt = (String)request.getAttribute("strAtt");
- response.setContentType("text/html;charset=gb2312");
- PrintWriter out = response.getWriter();
- out.println("<html>");
- out.println("<body>");
- out.println("getAttribute()得到的数据值为:" + strAtt);
- out.println("</body>");
- out.println("</html>");
- out.flush();
- }
- /**
- * 销毁
- */
- public void destroy()
- {
- super.destroy();
- }
- }
程序的运行结果如图9所示:
- <%@ page language="java" import="java.util.*" pageEncoding="gb2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <head>
- <link rel="stylesheet" type="text/css" href="css/style.css">
- </head>
- <body>
- <jsp:forward page="UpdateServlet">
- <jsp:param value="list" name="action" />
- </jsp:forward>
- </body>
- </html>
程序运行结果如图10所示:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- response.setStatus(HttpServletResponse.SC_MOVED_PERMANENTLY);
- String newLocn = "2.jsp";
- response.setHeader("Location",newLocn);
- %>
- </body>
- </html>
转向页2.jsp代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- 从1.jsp跳转至此页
- </body>
- </html>
程序运行结果如图11所示:
- <meta http-equiv="refresh" content="5; url=target.jsp"
含义是:在5秒后正在浏览的页面将会自动变为target.jsp页。代码中5为刷新的延迟时间,以秒为单位。target.jsp为你想转向的目标页,若为本页则自动刷新本页。
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- <%
- String content = "5; url=5_2.jsp";
- response.setHeader("REFRESH",content);
- %>
- 5_1.jsp页面,5秒后转向5_2.jsp页面。
- </body>
- </html>
转向页5_2.jsp代码如下:
- <%@ page language="java" import="java.util.*" pageEncoding="GB2312"%>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
- <html>
- <body>
- 从5_1.jsp转到的页面
- </body>
- </html>
程序运行结果如下:
Jsp与servlet之间页面跳转及参数传递实例(转)的更多相关文章
-
【转】(超详细)jsp与servlet之间页面跳转及参数传递实例
初步学习JavaEE,对其中jsp与Servlet之间的传值没弄清楚,查看网上资料,发现一篇超详细的文章,收获大大,特此记录下来.具体链接:http://blog.csdn.net/ssy_shand ...
-
jsp与servlet之间的参数传递【转】
JSP与 servlet之间的传值有两种情况:JSP -> servlet, servlet -> JSP. 通过对象 request和 session (不考虑 application) ...
-
Servlet——提交表单信息,Servlet之间的跳转
HTML表单标签:<form></form> 属性: actoion: 提交到的地址,默认为当前页面 method: 表单提交方式 有get和post两种方式,默认为get ...
-
JSP与Servlet之间传值
Jsp与Servlet之间的传值有两种,一种是Jsp传值给Sevlet,另一种是Servlet传值给Jsp:使用request.response对象完成传值,具体实现如下: 1.JSP传值给Servl ...
-
JSP与Servlet之间传值的一般方法,适合新手做练习
#JSP与Servlet之间传值 Jsp与Servlet之间的传值有两种,一种是Jsp传值给Sevlet,另一种是Servlet传值给Jsp:使用request.response对象完成传值,具体实现 ...
-
Web jsp开发学习——实现页面跳转和传参
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletExcepti ...
-
Java开发之Servlet之间的跳转
一.转向(Forward) 1.要点说明 转向是通过RequestDispatcher对象的forward()方法来实现的.RequestDispatcher可以通过HttpServletReques ...
-
js、JSP、servlet之间的传递小结
@ JS 与 JSP :JSP无法直接获取JS的值,只能通过隐藏表单或者dom节点设置. JSP中设置隐藏表单input,或者设置任意一个隐藏或者不隐藏的节点比如div, 而JS就通过document ...
-
JSP和servlet之间的传值(总结的很全面)
转自:http://blog.csdn.net/ssy_shandong/article/details/9328985 1.从一个jsp页面跳转到另一个jsp页面时的参数传递 (1)使用re ...
随机推荐
-
rqnoj378 约会计划
题目描述 cc是个超级帅哥,口才又好,rp极高(这句话似乎降rp),又非常的幽默,所以很多mm都跟他关系不错.然而,最关键的是,cc能够很好的调解各各妹妹间的关系.mm之间的关系及其复杂,cc必须严格 ...
-
堪称最好的A*算法
原文地址:http://theory.stanford.edu/~amitp/GameProgramming/ 相关链接:http://www-cs-students.stanford.edu/%7E ...
-
android窗体动画:activity启动从底部向上滑动出现,关闭的时候从顶部向下滑动消失的动画实现
在IOS系统里,我们打开app都是有启动动画的,这样子在打开一个新窗体,用户感觉有个过渡动画,体验效果很好,不会觉得很突然就冒出一个窗体,下面就实现一个android 的activity启动和关闭动画 ...
-
利用java解压,并重命名
由于工作需要,写了一个小工具,利用java来解压文件然后对文件进行重命名 主要针对三种格式,分别是zip,rar,7z,经过我的多次实践我发现网上的类库并不能解压最新的压缩格式 对于zip格式: ma ...
-
IWMS后台上传文章,嵌入视频,调用优酷通用代码
<a href="http://player.youku.com/player.php/sid/XODcxNjM3OTYw/v.swf " target="_bla ...
-
Windows常用命令实例
熟练使用DOS常用命令有助于提高工作效率. 1.windows+R:打开运行程序窗口 2.cmd:调用DOS命令窗口 3.mstsc:调用远程桌面命令窗口.mstsc -v 192.168..0.1 ...
-
8.mysql-基础.md
目录 数据库管理 查看当前软件中的数据库 工具 创建数据库 删除数据 查看字符集 修改数据库 表管理 进入数据库 查看表 创建表 查看表结构 删除表 修改表 添加字段 删除字段 修改字段名称 修改字段 ...
-
Gitlab-通过API管理问题
1. 首先获取想要创建问题的project_id字段. 2. 现在获取到了project_id字段, 现在可以通过API创建新的问题,该终端节点请求几个字段,project_id字段和问题的标题. 3 ...
-
ambari删除脚本
#.删除hdp.repo和hdp-util.repo cd /etc/yum.repos.d/ rm -rf hdp* rm -rf HDP* #rm -rf ambari* #.删除安装包 #用yu ...
-
IE7、IE8下使用escape、encodeURI传递中文参数乱码的问题及解决方案
js跳转到指定页面,一旦escape()中文数据,浏览器就会终止和没有反应.上网搜了半天始终不得解.一种说法是,escape中文之后,url中出现了%u,IE7和IE8拒绝执行.目前看来差不多是这样的 ...