Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa PHP get method

Have Programming Question? Ask it here!
 
 
 


dodhiya imran s
get method
2 Answer(s)      2 years and 11 months ago
Posted in : PHP


how to use get method: secure method is post method and most of use post method why use a get method.


Advertisement
View Answers

May 26, 2011 at 11:48 AM


When using HTML forms you can set the form method parameter to either "GET" (default) or "POST". So, which one to use?

When working with GET method you can access all form variables with the $GET array in PHP and when using POST you can access the variables using $POST as shown in our PHP forms tutorial. No matter which method used you can also access all variables using $_REQUEST array.

When using GET all the submitted information is displayed in the address bar as part of the URL. You will see that as information shown after ? (called a query string), something like:

http://domain.com/script.php?name1=value1&name2=value2

This can be useful for example where you want to be able to bookmark a page with specific query string values. However, the GET method is limited by the length of the URL (2083 characters in Internet Explorer according to Microsoft) and each of the input values must not exceed 100 chars. Obviously you also don't want to use GET when submitting sensitive information like passwords or credit card details as they would show up in the address bar.

The POST method can send a lot of data (usually limited by the server settings) and should be used for every form unless the specific application benefits from the query string in the URL when using GET. No submitted data is shown in the address bar so most browser cannot correctly bookmark pages shown after a HTTP POST method.

There you have it. Unless you need the query string that you get when using the GET method (and aren't effected by it's limits) you should use POST for your forms. If you are submitting any sensitive information that should not be displayed in the address bar the only way to go is with the POST method.



May 26, 2011 at 12:08 PM


The get method is a SEO friendly method. It makes easier to set up for small, non-secure data. The variables get passed through the URL string, so you don't have to try to attach it to headers or worry about forms.

Request of get method can be bookmarked, can be cached, are faster and have known consequences, so visiting them multiple times is not a problem.



Related Tutorials/Questions & Answers:
get method
get method   how to use get method: secure method is post method and most of use post method why use a get method
advantages of get method?
advantages of get method?  php in what is advatages of get methods and how you can use get methods
Advertisements
why get method is used?
why get method is used?  why get method is used in 60% commercial application while using post is more secure
question for "get method"
question for "get method"  when I want make method "get" for name or any char or string ..how I can write the syntax ? and what does it return
get and set method
get and set method  Create a class called Invoice that a hardware... a constructor that initialises the four instance variables. Provide a set and get method for each instance variable. In addition provide a method named
POST AND GET METHOD - JSP-Servlet
POST AND GET METHOD  I AM LITTLE BIT CONFUSED IN GET() AND POST() METHODS. PLZ GIVE ME BREIF INTRODUCTION ABOUT THESE ??:)  Hi Friend...://www.roseindia.net/jsp/how-work-post.shtml http://www.roseindia.net/html/html-get
Get Method of the Form In JSP
Get Method of the Form In JSP       This section provides you the best illustration of the get method of the form in JSP. The HTTP get method sends data to the server. In your JSP
Java Get Method
Java Get Method       In this example you will learn how to use the get method in Java. Java... to use get method in Java.  The example is going to show the date details
What is the difference between GET and POST method?
What is the difference between GET and POST method?  In PHP, both GET and POST method serves the same feature to get the data in variable. Still... it in detail with the case where we can use GET and POST method in PHP.   
GET and POST Method of HTTP
;    GET The Get is one the simplest Http method. Its main job... page, a sound file, a picture file (JPEG) etc. We can say that get method.... In get method the data we send get appended to the URL so whatever you will send
how to send spaces using get method.
how to send spaces using get method.  hi i want to know how to send spaces using get method? for example like http://localhost:8080/Sandeep?name... code: 1)form1.jsp: <html> <form method="get" action="form2.jsp"> <
HTML get Method
HTML get Method       The HTML get Method is used to submit the data of the page as part... helps you to understand an example from HTML get Method. In this Tutorial, we
Using get method in preferences
Using get method in preferences       In this section you will learn how to use the get() method... a simple way for using the get method in preferences. Get is the most useful
HTTP Status 405 - Request method 'GET' not supported. Its urgent
HTTP Status 405 - Request method 'GET' not supported. Its urgent  ...') in onclick method, following error is displaying in new window. "HTTP Status 405 - Request method 'GET' not supported." Anybody reply ASAP, its urgent
Multiple Value initialization and retrieval by put and get method
Multiple Value initialization and retrieval by put and get method... are going to find out the flow of using put and get method of the preferences. After reading, coding, and running you are able to use the get and put method. Here
Get Calling Method
Get Calling Method       In this example we will find the name of the method. Description of the method used in the example: getStackTrace: Provides programmatic access
get
get ( ) Method in PHP  what is get method in PHP   Please visit the following link: http://www.roseindia.net/php/php-Get-Post.shtml
Hibernate get
In this section, you will learn about get method of Hibernate
Hibernate Session Get
This part of discussion contain description of Hibernate session get () method
Java Servlet : Difference between GET and POST
Java Servlet : Difference between GET and POST In this section, we  will differentiate the GET and POST method of servlet. GET - It is HTTP method, asks to get thing at the requested URL. POST - It is HTTP method, asks
method
method   how and where, we can define methods ? can u explain me with full programme and using comments
method
method  can you tell me how to write an abstract method called ucapan() for B2 class class A2{ void hello(){ system.out.println("hello from A2"); }} class B2 extends A2{ void hello(){ system.out.println("hello from B2
HTML Get Radio Button
;  HTML Get  method in HTML is used to send the data as part of the URL. The get method is used for retrieving the data. In Get Method, the amount of data can be sent with a limited URL. Get method is used for sort forms
String indexOf() Method
of the method. Description of the code: Here, you will get to know about the indexOf... String indexOf() Method       In this section, you will get the detailed explanation about
JavaScript getAttribute method
JavaScript getAttribute method       JavaScript method getAttribute() is used to get... with the document.getElementById() method.          Syntax
charAt() Method In Java
charAt() Method In Java       In this section, you will get the detailed explanation about the charAt() method of String class. We are going for using charAt() method
How to work with POST method in jsp page
POST method instead of GET method in jsp page. GET is default method for sending... than using GET method as request method in JSP. For this we just need to set... How to work with POST method in jsp page
JSP Get URL
JSP Get URL          JSP Get URL is used to get the url of the current JSP page. The HttpServletRequest interface has a method getRequestURL
FTPClient : Get System Type
This section explain how to get system type by using method of FTPClient class in java
get and post
get and post  what is php and get   PHP get and post method
String indexOf() method in Java
String indexOf() method in Java In this tutorial we will discuss about indexOf() method in java. indexOf() method which is of string class,  used to locate a character or string.  The String class provide two method
Java example program to get the environment variable
Java example program to get the environment variable       java get environment variable The getenv() method of the java.lang.System provide us the functionality to get
POST or GET
to ULR that's why POST is faster then GET method...POST or GET  hello, Which will execute faster on php POST or GET?   hii, The POST metod is much more faster then GET ..because in GET
Java Get Class path
Java Get Class path       In this section, you will learn how to get the class path. The method System.getProperties() determines the current system properties. 
Get Environment Variable Java
(key): This method is used to get the key values from a map class... Get Environment Variable Java       In this example we are getting environment variable. To get
Java get Free Memory
to get the memory left of being allocated, the method getruntime() returns the runtime object associated with the Java application. freeMemory- This method returns... Java get Free Memory      
service method in servlet
service method in servlet In this tutorial you will learn about the service method in servlet that how can it be defined, how to get information from requests , and how the response can be constructed. service method is a method
charAt() method in java
charAt() method in java In this section you will get detail about charAt() in java. This method comes in java.lang.String package. charAt() return.... This method return the character at the specified index in the string. Syntax: public
Example of size() method of HashMap.
Example of size() method of HashMap. A HashMap is class of collection framwork. It stores data in the form of name value pair. It provides number of methods. The size() is also a method of HashMap class. It returns the size of HashMap
post get
post get  what is post and get
method inside the method??
method inside the method??  can't we declare a method inside a method in java?? for eg: public class One { public static void main(String[] args) { One obj=new One(); One.add(); private static void add
init method
init method  why init method used in servlet?   The init() method is called only once by the servlet container throughout the life of a servlet. By this init() method the servlet get to know that it has been placed
JavaScript getData method
JavaScript getData method       JavaScript method getData is used to get data... for getDataExample method as follows : <html> <script>
Method
Method       In this section, we will explore the concept of method in the reference of object oriented... and behaviors are defined by methods. Method : An brief introduction Methods
$_get php example - PHP
$_get php example  Explain the $_get method in php with a simple example. m a beginner
get Blob
get Blob   how i can display a Blob in XHTML (i developpe with hbernate
Java get default Locale
Java get default Locale     ..., or cultural region. We can get and set our default locale through the java programs. For setting or getting default Locale we need to call static method getDefault
property in javascript get set
get(val) { this.nval = val; } } Tutorial : JavaScript getAttribute method...property in javascript get set  How to create the get and set property in JavaScript?   Creating Get and Set properties in JavaScript
Get Class Name
Get Class Name       In the example given below we will learn how to get name of the particular class with package name. getName() method returns fully qualified name
method question
method question  How do I figure out the difference in a method heading, a method body, and a method definition
 

 

 

DMCA.com