Jump to content


Tool for printing the complete file


  • You cannot reply to this topic
No replies to this topic

#1 Jeroen

    Likes Etomite Forums!

  • Member
  • PipPip
  • 178 posts

Posted 26 January 2005 - 10:28 PM

In order to export all the entries to MS Word or the like for some 'spelling and grammer'. I modified Baath's code to something that prints the value for every key in $_lang. You can copy-paste that output to your text editor and watch all the red lines appear....

<?php
$file = $_GET['file'];
if ( empty( $file ) || strpos( $file, '/' ) > 0 || !file_exists( "$file.inc.php" ) ) die( "It's no good Cap'n!" );
require( "$file.inc.php" );

function print_values($my_array){
	reset($my_array);
	echo "These are all the entries:<br><dl>";
	while($array_cell = each($my_array)){
  $current = $array_cell['value'];
  echo "<dd>$current</dd>";
	}
	echo "</dl>";
}
print_values($_lang);
?>

usage: place the file in your manager/includes/lang/
and call a file with printfile?file=nederlands

Attached Files







1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users