Name

output_add_rewrite_var

Synopsis

bool output_add_rewrite_var(string name, string value)

Begins using the value rewriting output handler by appending the name and value to all HTML anchor elements and forms. For example:

output_add_rewrite_var('sender', 'php');

echo "<a href=\"foo.php\">\n";
echo '<form action="bar.php"></form>';

// outputs:
// <a href="foo.php?sender=php">
// <form action="bar.php"><input type="hidden" name="sender" value="php" /></form>

Get Programming PHP, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.