<< < 1 2 3 4 5 6 7 8 9 > >>   Sort: Rank

How To Pass an Argument to a Function
How To Pass an Argument to a Function? - PHP Script Tips - Creating Your Own Functions To pass an argument to a function, you need to: Add an argument definition in the function definition. Add a value as an argument when invoking the function. Here is a PHP script on how to use arguments in a funct...
2007-04-24, 4701👍, 0💬

In Which Does File FireFox Store Persistent Cookies
In Which Does File FireFox Store Persistent Cookies? - PHP Script Tips - Understanding and Managing Cookies If you change FireFox to keep cookies "until they expire", FireFox will store persistent cookies from all Web servers in a single file at: \Documents and Settings\$user\Application Data\Mozill...
2007-04-24, 5048👍, 0💬

How Many Cookies Can You Set
How Many Cookies Can You Set? - PHP Script Tips - Understanding and Managing Cookies How many cookies can you set in your PHP page? The answer is depending what is the Web browser your visitor is using. Each browser has its own limit: Internet Explorere (IE): 20 Mozilla FireFox: 50 If you want to te...
2007-04-24, 5119👍, 0💬

How To Define a User Function
How To Define a User Function? - PHP Script Tips - Creating Your Own Functions You can define a user function anywhere in a PHP script using the function statement like this: "function name() {...}". Here is a PHP script example on how to define a user function: &lt;?php function msg() { print("...
2007-04-24, 4833👍, 0💬

How To Invoke a User Function
How To Invoke a User Function? - PHP Script Tips - Creating Your Own Functions You can invoke a function by entering the function name followed by a pair of parentheses. If needed, function arguments can be specified as a list of expressions enclosed in parentheses. Here is a PHP script example on h...
2007-04-24, 5690👍, 0💬

How Large Can a Single Cookie Be
How Large Can a Single Cookie Be? - PHP Script Tips - Understanding and Managing Cookies How large can a single cookie be? The answer is depending what is the Web browser your visitor is using. Each browser has its own limit: Internet Explorere (IE): about 3904 bytes Mozilla FireFox: about 3136 byte...
2007-04-24, 8453👍, 0💬

How Are Cookies Encoded During Transportation
How Are Cookies Encoded During Transportation? - PHP Script Tips - Understanding and Managing Cookies When cookies are transported from servers to browsers and from browsers back to servers, Cookies values are always encoded using the URL encoding standard to ensure that they are transported accurat...
2007-04-24, 4991👍, 0💬

How To Get the Directory Name out of a File Path Name
How To Get the Directory Name out of a File Path Name? - PHP Script Tips - Working with Directoris and Files If you have the full path name of a file, and want to get the directory name portion of the path name, you can use the dirname() function. It breaks the full path name at the last directory p...
2007-04-23, 5029👍, 0💬

How To Break a File Path Name into Parts
How To Break a File Path Name into Parts? - PHP Script Tips - Working with Directoris and Files If you have a file name, and want to get different parts of the file name, you can use the pathinfo() function. It breaks the file name into 3 parts: directory name, file base name and file extension; and...
2007-04-23, 5048👍, 0💬

How Can Other Webmaster Steal Your Cookies
How Can Other Webmaster Steal Your Cookies? - PHP Script Tips - Understanding and Managing Cookies All browsers are following the security rule that your cookies are sent back only to your Web servers. They will not be sent to other Webmaster's Web server directly. However, other Webmaster may desig...
2007-04-23, 5330👍, 0💬

How To Create a Web Form
How To Create a Web Form? - PHP Script Tips - Processing Web Forms If you take input data from visitors on your Web site, you can create a Web form with input fields to allow visitors to fill in data and submit the data to your server for processing. A Web form can be created with the &lt;FORM> ...
2007-04-23, 5032👍, 0💬

How To Dump the Contents of a Directory into an Array
How To Dump the Contents of a Directory into an Array? - PHP Script Tips - Working with Directoris and Files If you want to get the contents of a directory into an array, you can use the scandir() function. It gets a list of all the files and sub directories of the specified directory and returns th...
2007-04-23, 6953👍, 0💬

How To Read a Directory One Entry at a Time
How To Read a Directory One Entry at a Time? - PHP Script Tips - Working with Directoris and Files If you want to read a directory one entry at a time, you can use opendir() to open the specified directory to create a directory handle, then use readdir() to read the directory contents through the di...
2007-04-23, 4799👍, 0💬

What Are Form Input HTML Tags
What Are Form Input HTML Tags? - PHP Script Tips - Processing Web Forms HTML tags that can be used in a form to collect input data are: &lt;SUBMIT ...> - Displayed as a button allow users to submit the form. &lt;INPUT TYPE=TEXT ...> - Displayed as an input field to take an input string. &...
2007-04-23, 5269👍, 0💬

How To Generate a Form
How To Generate a Form? - PHP Script Tips - Processing Web Forms Generating a form seems to be easy. You can use PHP output statements to generate the required &lt;FORM> tag and other input tags. But you should consider to organized your input fields in a table to make your form looks good on th...
2007-04-23, 5101👍, 0💬

How To Remove a File
How To Remove a File? - PHP Script Tips - Working with Directoris and Files If you want to remove an existing file, you can use the unlink() function. Here is a PHP script example on how to use unlink(): &lt;?php if (file_exists("/temp/todo.txt") ){ unlink("/temp/todo.txt"); print("File removed....
2007-04-23, 4854👍, 0💬

How To Copy a File
How To Copy a File? - PHP Script Tips - Working with Directoris and Files If you have a file and want to make a copy to create a new file, you can use the copy() function. Here is a PHP script example on how to use copy(): &lt;?php unlink("/temp/myPing.exe"); copy("/windows/system32/ping.e xe","...
2007-04-23, 4833👍, 0💬

Where Is the Submitted Form Data Stored
Where Is the Submitted Form Data Stored? - PHP Script Tips - Processing Web Forms When a user submit a form on your Web server, user entered data will be transferred to the PHP engine, which will make the submitted data available to your PHP script for processing in pre-defined arrays: $_GET - An as...
2007-04-23, 6987👍, 0💬

How To Retrieve the Submitted Form Data
How To Retrieve the Submitted Form Data? - PHP Script Tips - Processing Web Forms The best way to retrieve the form data submitted by your visitor is to use the $_REQUEST array. The keys in this array will be the field names defined in form. The values in this array will be the values entered by you...
2007-04-23, 5112👍, 0💬

How To Remove an Empty Directory
How To Remove an Empty Directory? - PHP Script Tips - Working with Directoris and Files If you have an empty existing directory and you want to remove it, you can use the rmdir(). Here is a PHP script example on how to use rmdir(): &lt;?php if (file_exists("/temp/download") ){ rmdir("/temp/downl...
2007-04-23, 4780👍, 0💬

How To Create a Directory
How To Create a Directory? - PHP Script Tips - Working with Directoris and Files You can use the mkdir() function to create a directory. Here is a PHP script example on how to use mkdir(): &lt;?php if (file_exists("/temp/download") ){ print("Directory already exists.\n"); } else { mkdir("/temp/d...
2007-04-23, 4717👍, 0💬

What Happens If an Expected Input Field Was Not Submitted
What Happens If an Expected Input Field Was Not Submitted? - PHP Script Tips - Processing Web Forms Obviously, if an expected input field was not submitted, there will no entry in the $_REQUEST array for that field. You may get an execution error, if you are not checking the existence of the expecte...
2007-04-23, 5255👍, 0💬

How To Avoid the Undefined Index Error
How To Avoid the Undefined Index Error? - PHP Script Tips - Processing Web Forms If you don't want your PHP page to give out errors as shown in the previous exercise, you should consider checking all expected input fields in $_REQUEST with the isset() function as shown in the example script below: &...
2007-04-23, 11886👍, 0💬

How To Read Data from Keyborad (Standard Input)
How To Read Data from Keyborad (Standard Input)? - PHP Script Tips - Reading and Writing Files If you want to read data from the standard input, usually the keyboard, you can use the fopen("php://stdin") function. It creates a special file handle linking to the standard input, and returns the file h...
2007-04-23, 4825👍, 0💬

<< < 1 2 3 4 5 6 7 8 9 > >>   Sort: Rank