diff --git a/include/functions.php b/include/functions.php new file mode 100644 index 0000000..c14e21d --- /dev/null +++ b/include/functions.php @@ -0,0 +1,31 @@ + $value){ + if($i == 0) $result .= "?"; + else $result .= "&"; + + $result .= $key . "=" . $value; + $i++; + } + } + + return($result); +} + +?> diff --git a/user.php b/user.php index 34ae4f3..25499c9 100644 --- a/user.php +++ b/user.php @@ -73,13 +73,8 @@ if(isset($_GET["p"])){ echo($h_user["name"]); } else{ - echo("" . $h_user["name"] ."\n"); + $new_get["q"] = $h_user["name"]; + echo("" . $h_user["name"] ."\n"); } echo(" asked:

"); @@ -152,6 +147,7 @@ if(isset($_GET["p"])){ $time = new DateTime("@0"); + $tmp_get = $_GET; while($current = $qs->fetchArray(SQLITE3_ASSOC)){ // Execute prepared statement @@ -168,13 +164,8 @@ if(isset($_GET["p"])){ echo($q_user["name"]); } else{ - echo("" . $q_user["name"] .""); + $new_get["q"] = $q_user["name"]; + echo("" . $q_user["name"] .""); } echo("

\n"); @@ -200,8 +191,8 @@ if(isset($_GET["p"])){ // Time $time->settimestamp($current["q_date"]); echo("\t\t\t\t\t"); - $_GET["p"] = $current["id"]; - echo(''); + $tmp_get["p"] = $current["id"]; + echo(''); echo("

" . $time->format("Y-m-d h:i:s") . "

"); echo("
\n"); @@ -250,12 +241,9 @@ if(isset($_GET["p"])){ $ps_item = ""; if($link){ - $link_init = ""; + $tmp_get = $_GET; + $tmp_get["page"] = $link; + $link_init = ""; $label = $link_init . $label . ""; }