Jump to content

viewScripts.php


cdog5000

Recommended Posts

 

<?php
mysql_connect('lalala', 'lalalala', 'lalala') or die(mysql_error());
mysql_select_db('lalalalal') or die(mysql_error());
$selected_radio = $_GET['name'];

if ($selected_radio == 'RSBot') {
    $Botid = 0;
} else
    if ($selected_radio == 'Nexus') {
        $Botid = 1;
    }
echo "<div align = center>you are viewing scripts from the bot " . $selected_radio .
    "</div><br/><br/>";
$skill = $_GET['skill'];
$Botid = $_GET['bot'];
$query = "SELECT * FROM ScriptDatabase WHERE botname  = " . $selected_radio .
    " ";
$information = mysql_query($query);
while ($row == mysql_fetch_assoc($information)) {
    echo "
<br/>
Username: " . $row['username'] . "  <t><t>     Script ID:" . $row['id'] . "
<br/>
<br/>
<div align = center> <b>Script Name:</b>" . $row['scriptname'] . " <div/>
<br/>
How to use:" . $row['tutorial'] . "
<br/>
Information:" . $row['information'] . "
<br/>
Script:" . $row['script'] . "
<br/>
<br/>
>-------------------------------------------------------------------------------------<";
    if ($row['username'] == null) {
        echo "No Scripts In Database";
    }
}

?>

 

ok lol now it shows like 50,000

Username:  Script ID:

 

Script Name:

 

How to use:

Information:

Script:

 

>-------------------------------------------------------------------------------------

Link to comment
https://forums.phpfreaks.com/topic/111622-viewscriptsphp/
Share on other sites

$row cant be exactly equalled to the db rows, because $row is being defined inside the while, you aren't comparing $row and mysql_fetch_assoc

 

change

while ($row == mysql_fetch_assoc($information)) {

to

while ($row = mysql_fetch_assoc($information)) {

 

Put this at the bottom of your page to

 

echo mysql_error();

Link to comment
https://forums.phpfreaks.com/topic/111622-viewscriptsphp/#findComment-572980
Share on other sites

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.