Outputs a single website comment in the form of an array, a single array
In the original library function, the method for displaying a single comment is not obtained. Add the following:
Public static function single ($ id) {global $ db; return $ db-> query ("SELECT * FROM '{$ db-> prefix} comment 'where' =' {$ id} '", 1 );}
Output array, which can be called in the template
Assign values to array a and output the elements in all arrays in the form of five data entries per row.
# Include "stdio. h"
Main ()
{
Int a [20], I; // assume that the array is 20 elements.
For (I = 0; I <20; I ++)
Scanf ("% d", & a [I]); // The array elements are input by the keyboard.
For (I = 0; I <20; I ++)
{
Printf ("% 5d", a [I]);
If (I % 5 = 0)
Printf ("/n"); // if the number is 5, a line break is output.
}
}
How to output an array
I don't know the specific request function, but it's easy to use js.