Jump to content
php.lv forumi

$a = $a + 1;


jonass

Recommended Posts

vareetu buut apmeeram, idejiski shaaadi:

<code><font color="#000000">

<font color="#0000CC"><?
</font><font color="#006600">function </font><font color="#0000CC">check_checksum</font><font color="#006600">(</font><font color="#0000CC">$a</font><font color="#006600">, </font><font color="#0000CC">$b</font><font color="#006600">, </font><font color="#0000CC">$ab</font><font color="#006600">){
  </font><font color="#0000CC">$slepenaa_veertiiba </font><font color="#006600">= </font><font color="#CC0000">"kgahjlghqewlirelourgewiogfregf"</font><font color="#006600">;
  return (</font><font color="#0000CC">[url=http://lv.php.net/md5]md5[/url]</font><font color="#006600">(</font><font color="#0000CC">$a </font><font color="#006600">. </font><font color="#0000CC">$slepenaa_veertiiba </font><font color="#006600">. </font><font color="#0000CC">[url=http://lv.php.net/session_id]session_id[/url]</font><font color="#006600">() . </font><font color="#0000CC">$b</font><font color="#006600">) == </font><font color="#0000CC">$ab</font><font color="#006600">);
}
function </font><font color="#0000CC">set_checksum</font><font color="#006600">(</font><font color="#0000CC">$a</font><font color="#006600">, </font><font color="#0000CC">$b</font><font color="#006600">){
  </font><font color="#0000CC">$slepenaa_veertiiba </font><font color="#006600">= </font><font color="#CC0000">"kgahjlghqewlirelourgewiogfregf"</font><font color="#006600">;
  return </font><font color="#0000CC">[url=http://lv.php.net/md5]md5[/url]</font><font color="#006600">(</font><font color="#0000CC">$a </font><font color="#006600">. </font><font color="#0000CC">$slepenaa_veertiiba </font><font color="#006600">. </font><font color="#0000CC">[url=http://lv.php.net/session_id]session_id[/url]</font><font color="#006600">() . </font><font color="#0000CC">$b</font><font color="#006600">);
}
</font><font color="#0000CC">$pareizie </font><font color="#006600">= </font><font color="#0000CC">$_POST</font><font color="#006600">[</font><font color="#CC0000">'PHP_PAREIZIE'</font><font color="#006600">];
</font><font color="#0000CC">$nepareizie </font><font color="#006600">= </font><font color="#0000CC">$_POST</font><font color="#006600">[</font><font color="#CC0000">'PHP_NEPAREIZIE'</font><font color="#006600">];
</font><font color="#0000CC">$checksumma </font><font color="#006600">= </font><font color="#0000CC">$_POST</font><font color="#006600">[</font><font color="#CC0000">'PHP_SUMMA'</font><font color="#006600">];
if </font><font color="#0000CC">check_checksum</font><font color="#006600">(</font><font color="#0000CC">$pareizie</font><font color="#006600">, </font><font color="#0000CC">$nepareizie</font><font color="#006600">, </font><font color="#0000CC">$checksumma</font><font color="#006600">){
 </font><font color="#FF9900">//darbiibas, kas jaaveic tavaa programmaa (tiek izmainiiti mainiigie $pareizie un $nepareizie)
 </font><font color="#0000CC">$checksumma </font><font color="#006600">= </font><font color="#0000CC">set_checksum</font><font color="#006600">(</font><font color="#0000CC">$pareizie</font><font color="#006600">, </font><font color="#0000CC">$nepareizie</font><font color="#006600">);
}
else {
 </font><font color="#0000CC">$pareizie </font><font color="#006600">= </font><font color="#0000CC">0</font><font color="#006600">;
 </font><font color="#0000CC">$nepareizie </font><font color="#006600">= </font><font color="#0000CC">0</font><font color="#006600">;
 </font><font color="#0000CC">$checksumma </font><font color="#006600">= </font><font color="#0000CC">set_checksum</font><font color="#006600">(</font><font color="#0000CC">$pareizie</font><font color="#006600">, </font><font color="#0000CC">$nepareizie</font><font color="#006600">);
}
</font><font color="#0000CC">?>
</font>...
<input type=hidden name=PHP_PAREIZIE value=$pareizie>
<input type=hidden name=PHP_NEPAREIZIE value=$nepareizie>
<input type=hidden name=PHP_SUMMA value=$checksumma>
...
</font>
</code>

Link to comment
Share on other sites

×
×
  • Create New...