Php Interview Question and Answers
29. |
Which function would you use to merge two arrays? |
|
You can merge arrays with the array_merge() function. |
|
|
30. |
Which function would you use to open a file for reading or writing? |
|
The fopen() function opens a file. It accepts the path to a file and a character representing the mode. It returns a file resource. |
|
|
31. |
Which function contains the current session’s ID? |
|
You can access the session's ID with the session_id() function. |
|
|
32. |
How would you get a current line number while an XML document is being parsed? |
|
The xml_get_current_line_number() function returns the current line number.
|
|
|