Is there a better way to code this??
// The below are globals because they pass through functions and methods
$GLOBALS['HTMLSpacingType'] = "\\x20";
$GLOBALS['HTMLSpacing'] = 5;
for ($i=0; $i < $GLOBALS['HTMLSpacing']; $i++) {
print($GLOBALS['HTMLSpacingType']);
}
What I would like to do is get this into one line of code. What it should do is print $y, $x ammount of times. So if $x is 5 it will print $y 5 times. I'm doing this for HTML output formatting (how many spaces to output befor the HTML tag). Any ideas would be great. Thanks!