PHP Questions

2013 年 6 月 29 日5070

PHP Questions

Here we have a range of common PHP related questions and answers. If you want to know how to do something in PHP but aren't sure how, then just view the questions here and if you can't find the answer, Ask A Question.

Arrays

How can I check if a value is already in an array?
How can I create an array of numbers easily?
How can I create an array of the letters of the alphabet?
How can I display a 2 dimensonal array?
How can I display values in a two dimensional array?
How can I easily view all members of an array?
How can I loop through the members of an array?
How can I mix up the order of values in an array?
How can I reset an array in PHP?
How can I reverse sort an array keeping the correlation between the index and value?
How can I sort a multi-dimensional array?
How can I sort an array keeping the correlation between the index and value?
How do I add to the beginning of an array and find the number of elements in it?
How do I add to the end of an array and know how large the array is?
How do I check if a variable is of array type?
How do I count the number of times a value appears in an array?
How do I find if a value is already in an array or not?
How do I find out if a value is already in an array?
How do I find the size of an array?
How do I pick a random value from an array?
How do I remove an element from an array without changing the index values for the rest of the array?
How do I remove and view the last element of an array?
How do I remove the first element from an array?
How do I return all the values in an array?
How do I reverse sort an array by key?
How do I reverse sort the members of an array?
How do I reverse the order of the elements in an array?
How do I sort alphanumeric array data correctly?
How do I sort an array by key?
How do I sort the members of an array by value?
How do I turn an array into a string?
How do I write my own sort function?
How do we sort an array of names taken from a text file, displaying only unique names?
How do you remove duplicate values from an array?
How to point internal pointer to first element of an array?
I am not interested in the values in the arrays, how can I discard them?
I have an array of numbers and many repeat, how to list all items in order of maximum occurence?
I want to invert my array, can I do this?

Errors

I get a parse error - unexpected ; at line x message. What is this?
I get a PHP error - maximum execution time exceeded. What is this?
I get a PHP notice for string to array conversion - help?
I get a PHP warning for array to string conversion - what is this?
I get the error message headers already sent, what does this mean?
Parse error in PHP - unexpected T_variable at line x. What is this error?
PHP error - use of undefined constant at line x... what does this mean?

Files

How can I export data into Word/Excel documents?
How can i upload large files like mp3 songs using php?
How can I view a Word document in a PHP page?
How do I open a file to write content to?
I am trying to find the most recent directory that I am working in.

example

http://http://www.zjjv.com///apples/index.php

how do I get php to find the directory "apples" so I can make it a directory
What does file_get_contents do?
What is the use of file in php?
Where is a text file i created kept?

Forms

Can I use a variable from a .php file to give a value to an HTML FormMail form field thus: ?

Thank you

How can I access information sent through GET on a form?
How can I access information sent through POST on a form?
How can I check a value entered in a field on my form is a number?
How can I check that a data value is alphanumeric?
How do I check for an empty field in a form?
How do I check that a valid email address is entered?
How do I email the contents of a form to me?
How do I escape data that is going into a database?
How do I know if magic quotes is switched on?
How do I make a website field mandatory?
How do I remove escape characters from data?
How do I remove HTML tags from a string?
What are magic quotes?

FPDF

How can I find out more about FPDF?
How do I add a line break to my PDF in FPDF?
How do I add a new font to my PDF with FPDF?
How do I embed a font in FPDF?
How do I output text to a PDF with FPDF?
How do I set and change the font in FPDF?
What is FPDF?

Functions

How can I call online a PHP function. It works local but when I put it online it does nothing.

I call online a php function to load pictures into my flex application.

Thanks

Bart
How do I get a variable in a function to retain its value between calls?
How do I make a variable from outside a function work in that function?
How do I return a value from a function?
PHP Fatal error does not result in HTTP error code 500. When PHP code throws a Fatal error, I would expect Apache to respond with HTTP 500, not a 200?
What is a function?
What is a static variable within a function?

Images

How can I add text to an image?
How can I find the colour of a pixel of an image?
How can I find the width and height of an image resource?
How can I rotate an image?
How to rotate an image using php code?

Mysql

How can I show an image from mysql?
How do I access the current time with mysql?
How do I connect to mySQL from PHP?
How do I delete a row from a table?
How do I find second highest value from a table?
How do I find the ID of a new row added to a table?
How do I find the longest value in my mysql table?
How do I find the number of rows affected by a query?
How do I find the number of rows in a result set?
How do I group the results of a mysql query?
How do I include a conditional in my mysql query?
How do I insert the date into my table?
How do I limit the number of rows returned?
How do I order the results of my query?

Contact us | Privacy

0 0