Jump to content

Parse Error in T_Return


BillyBoB

Recommended Posts

what?

 

lol ive never wseen that short code before, if your assigning a variable depending on a true or false if statement try this:

 

$variable = ($var1 == $var2)? "var1 == var2" : "var1 != var2";

 

 

hope this helps :P

 

(T_RETURN means the string "return" after the ? symbol in your syntax btw. its fine with the ? but not anything after that...

beat me but oh well ill post this anyway:

 

hmm, try:

<?php
function checkit($arg){
return ($arg == null)? "lkas45n87x02xhy" : $arg;
}

$o027asdf04qvnola = "test";
echo checkit($o027asdf04qvnola);

echo("<br>");

$o027asdf04qvnola = "";
echo checkit($o027asdf04qvnola);

// echoes: 
// test<br> 
// lkas45n87x02xhy

?>

this function, you want to "return" the string so im assuming this is inside a function, just take the return .... line and put it instead of the return in your function.... im sure you wil understand it ;)

are you going to be realeasing your source code? if so it wont really matter what you do with it php is extremely easy to hack if they have the source code...

 

if your going to compile this script into a .exe then it will still be reasonably easy to decompile/dissasemble and hack,

 

for serial-key validation i would use c++ or visual basic, and add a lot of routines to throw them off... for more information look into assembly language and how it works (extremely complicated for beginners).

 

maybe someone has some more ideas about serial-key validation in php... (maybe store a list of known serial-keys in a secure db),

-------

what is this serial0key for? a php script? or a windows program?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.