Current time: 01-27-2013, 07:20 PM    Register | Lost Password?

Contest #1- First member to have 5 referals will get VIP status. You can find your referal link in your UserCP


Post Reply 
Whats Wrong whit this code
Author Message
jomasaco Offline
Respected Member


Posts: 17
Joined: May 2010
Post: #1
Whats Wrong whit this code
PHP Code: (Select All)
<?php
include "funcs.php";

if(isset(
$_POST) && !empty($_POST)) {
$site=$_POST['site'];
$site=str_replace("http://","",$site);
$site=str_replace("www.","",$site);

$query mysql_query("SELECT * FROM wcddl_sites WHERE url = '".$site."'");
        
$numR mysql_num_rows($query);
        if(
$numR==0) echo 'Site not found';
        else {
            
$row mysql_fetch_assoc($query);
            if(
$pass!=$row['password']) echo ' Password is incorrect.';
            else {
                echo 
' Welcome '.$site.' owner';
            }
        }
}
else {
    echo 
'<form name="login" target="$self" id="login" method="post">
Site: <input type="text" name="site">
Pass: <input type="password" name="pass">
<input type="submit" value="Submit" />
</form>'
;
}        
?>
02-08-2011 03:03 PM
Find all posts by this user Quote this message in a reply
jomasaco Offline
Respected Member


Posts: 17
Joined: May 2010
Post: #2
Whats Wrong whit this code
No one?
This are only an test do not use such code on your site or your database can be erased.
An hint never trust in input data.
02-12-2011 04:11 PM
Find all posts by this user Quote this message in a reply
c0rrupt Offline
Administrator


Posts: 276
Joined: Mar 2010
Post: #3
Whats Wrong whit this code
thanks for feed back on this mate!! Smile
02-13-2011 12:11 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)

Affiliates
PhazeDDL WarezUNION WarezOrder Free Full Downloads SuppaDDL CafeDDL-Serves Premium Downloads! free porn downloads @ PornDDL.me
This forum uses Lukasz Tkacz MyBB addons.