Jump to content
xisto Community

Argoth

Members
  • Content Count

    30
  • Joined

  • Last visited

Posts posted by Argoth


  1. you could do a (this is psuedocode) :

    If % > 10 then Display Img_barIf % > 20 then Display Img_barIf % > 30 then Display Img_barIf % > 40 then Display Img_barIf % > 50 then Display Img_barIf % > 60 then Display Img_barIf % > 70 then Display Img_barIf % > 80 then Display Img_barIf % > 90 then Display Img_barIf % > 100 then Display Img_bar

    So then each 10% is depicted by a bar.

    Don't know if that's what you were looking for.

  2. You have some text being outputted in your config.inc.php file, you can't have that. ANY white space outside of the php tags is considered output.I'm guessing that in this query "SELECT ip_addr FROM banned_ips" either the table or the field doesn't exist. if it doesn't make it, if it does I don?t know what the problem is.Same thing for "SELECT theme_path FROM themes WHERE theme_id = $userstylem"


  3. <?phpsession_cache_limiter('private, must-revalidate');session_name('sid');session_start();$_PAGE['start_time'] = getmicrotime();//// Unset globals//$methods = array('_POST', '_GET', '_COOKIE', '_FILES');isset($_SESSION) ? $methods[] = '_SESSION' : '';foreach ($methods as $method){   foreach ($$method as $var_name => $var_value)   {       unset($$var_name);   }}$_GET['board']   = isset($_GET['board'])   ? intval($_GET['board'])   : null;$_GET['topic']   = isset($_GET['topic'])   ? intval($_GET['topic'])   : null;$_GET['message'] = isset($_GET['message']) ? intval($_GET['message']) : null;$_GET['user']    = isset($_GET['user'])    ? intval($_GET['user'])    : null;    //// User Authentication Function//function auth($username, $password){ $result = mysql_query("SELECT username FROM users WHERE username = '$username' AND userpass = '$password'"); return mysql_num_rows($result) != 0 ? mysql_result($result, 0) : null;}//// SQL Field Fetching Function//function get_field($field, $tbl_name, $condition = 1){ $result = mysql_query("SELECT $field FROM $tbl_name WHERE $condition"); return @mysql_result($result, 0);}//// IP Fetching Function//function fetch_ip(){ $ip = isset($_SERVER['HTTP_X_FORWARDED_FOR']) ? $_SERVER['HTTP_X_FORWARDED_FOR'] : $_SERVER['REMOTE_ADDR']; if (strpos($ip, ',')) {   $ip = explode(',', $ip);   $ip = trim($ip[0]); } return $ip;}//// Get Microtime//function getmicrotime(){ list($usec, $sec) = explode(' ', microtime()); return ((float)$usec + (float)$sec);}function navigator($title, $col = 2, $bor = 1, $spc = 0, $info = 1, $other_links = null, $style = null){ global $q_string, $userlevelm; if (isset($userlevelm)) {   ?>   <table border="<?= $bor ?>" cellspacing="<?= $spc ?>" width="100%"<?= $style ?>>   <tr><td align="center" colspan="<?= $col ?>"><font size="6"><b><?= $title ?></b></font></td></tr>   <tr><td align="center" colspan="<?= $col ?>" class="b"><i>Return to: <a class="menu" href="index.php">Board List</a>   <?php   if (isset($_GET['board']))   {     ?> | <a class="menu" href="gentopic.php?board=<?= $_GET['board'] ?>">Topic List</a><?php   }   if (isset($_GET['topic']))   {     ?> | <a class="menu" href="genmessage.php<?= $q_string['a'] ?>">Message List</a><?php   }   if ($info == 1)   {     ?> | <a class="menu" href="user.php<?= $q_string['a'] ?>">User Info Page</a><?php   }   if (is_array($other_links))   {     foreach ($other_links as $href => $link_title)     {       $href = explode('|', $href);       if ($href[1] == '' || $userlevelm >= $href[1])       {         ?> | <a class="menu" href="<?= $href[0], $q_string['a'] ?>"><?= $link_title ?></a><?php       }     }   }   if ($userlevelm >= 52)   {     ?> | <a class="menu" href="cpanel.php<?= $q_string['a'] ?>">Control Panel</a><?php   }   ?>   </i></td></tr>   <?php } else {   ?>   <table border="<?= $bor ?>" cellspacing="<?= $spc ?>" width="100%"<?= $style ?>>   <tr><td align="center" colspan="<?= $col ?>"><font size="6"><b><?= $title ?></b></font></td></tr>   <tr><td align="center" colspan="<?= $col ?>" class="b">   <a class="menu" href="index.php">Board List</a>   | <a class="menu" href="register.php">Register</a>   | <a class="menu" href="login.php">Log In</a>   | <a class="menu" href="help.php">Help</a>   | <a class="menu" href="tos.php">ToS</a></td></tr>   <?php }}//// Update Counter//mysql_query("UPDATE counters SET count_value=count_value+1 WHERE count_type='boards'");//// IP Banning//if (isset($_COOKIE['zXi7g'])) die;$result = mysql_query('SELECT ip_addr FROM banned_ips');while ($row = mysql_fetch_row($result)){ if (stristr($_SERVER['REMOTE_ADDR'], $row[0]) || stristr($_SERVER['HTTP_REFERER'], $row[0])) {   setcookie('zXi7g', 'o', time()+92275200);   die; }}if (stristr($_SERVER['HTTP_USER_AGENT'], 'anon')) die;//// User Name and Password Retrieval//$uname = isset($_SESSION['username']) ? $_SESSION['username'] : (isset($_COOKIE['uname']) ? $_COOKIE['uname'] : null);$pword = isset($_SESSION['password']) ? $_SESSION['password'] : (isset($_COOKIE['pword']) ? $_COOKIE['pword'] : null);//// Common User Info Retrieval//$row = @mysql_fetch_row(@mysql_query("SELECT userid, level, style, timezone, sidebar FROM users WHERE username='$uname' AND userpass='$pword'"));if (isset($row[0])){ $useridm = $row[0]; $userlevelm = $row[1]; $userstylem = $row[2]; $_PAGE['timezone'] = $row[3]*3600; $_PAGE['sidebar'] = $row[4]; mysql_query("UPDATE users SET lastsec='".time()."', lastacip='{$_SERVER['REMOTE_ADDR']}', last_page='". htmlspecialchars(preg_replace('#sid=[[:alnum:]]+(\&)*#i', '', $_SERVER['REQUEST_URI']), ENT_QUOTES) ."', user_agent='". htmlspecialchars($_SERVER['HTTP_USER_AGENT'], ENT_QUOTES) ."', real_ip = '". fetch_ip() ."' WHERE userid='$useridm'");}//// Spit It All Out//?><html><head><title><?= $_CONFIG['mbsname'] ?>: <?= $title ?></title><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /><?phpswitch ($userstylem){ case 'custom': extract(@mysql_fetch_assoc(mysql_query("SELECT * FROM style WHERE userid='$useridm'"))); echo "<style type=\"text/css\">a:link {color: $n_link; text-decoration: underline}a:visited {color: $n_vlink; text-decoration: underline}a.menu:link {color: $m_link; text-decoration: underline}a.menu:visited {color: $m_vlink; text-decoration: underline}a.menu:hover {color: $m_hlink; text-decoration: underline}a.menu:active {color: $m_alink; text-decoration: underline}body, td {background-color: $main_bg; font-family: $font_face; font-size: 80%;color: $font_color}.a {background-color: $c1_bg; font-size: 95%; color: $c1_fc; font-weight: bold}.b {background-color: $c2_bg; font-size: 95%; color: $c2_fc; font-weight: bold}.c {background-color: $c3_bg}.d {background-color: $c4_bg}.system {background-color: $system_bg}.shade {background-color: $shade_bg}.sidebar {background-color: $sidebar_bg}.large {font-size: 120%; font-weight: bold}.medium {font-size: 90%}.poll_graph {display: block; background-color: $poll_graph; line-height: 25px}</style>\n"; break; default: empty($userstylem) ? $userstylem = 1 : ''; $theme_path = mysql_result(mysql_query("SELECT theme_path FROM themes WHERE theme_id = $userstylem"), 0); echo '<link rel="stylesheet" type="text/css" href="'.$theme_path.'" />' . "\n";}echo $_PAGE['sidebar'] == 1 ? '<link rel="stylesheet" type="text/css" href="styles/margins.css" />' : '';?></head><body><?$_PAGE['sidebar'] == 1 ? include 'sidebar_header.inc.php' : '';if (isset($_GET['message'])) get_field('COUNT(*)', 'messages', "messageid = '{$_GET['message']}'") == 0 ? die('Invalid Message ID') : '';if (isset($_GET['topic'])) get_field('COUNT(*)', 'topics', "topicid = '{$_GET['topic']}' AND board='{$_GET['board']}'") == 0 ? die('Invalid Topic ID') : '';if (isset($_GET['board'])) get_field('COUNT(*)', 'boards', "boardid = '{$_GET['board']}'") == 0 ? die('Invalid Board ID') : '';if (isset($_GET['user'])) get_field('COUNT(*)', 'users', "userid = '{$_GET['user']}'") == 0 ? die('Invalid User ID') : '';if (defined('_FILE_LVL')){ if ($userlevelm < _FILE_LVL) {   echo '<div align="center"><b><font size="6">Error</font></b></div><br /><div align="left">You have to be at least level <b>\'.52.\'</b> to view this page. Return to the <a href="javascript:window.history.go(-1)">previous page</a> or the <a href="index.php">general board list</a>.</div>';   include 'footer.inc.php';   exit; }}if ($userlevelm >= 52){ $result   = mysql_query('SELECT COUNT(*) FROM marked'); $num_msgs = mysql_result($result, 0); $result  = mysql_query("SELECT COUNT(*) FROM temp_users WHERE act_status = 2"); $num_pend_users = mysql_result($result, 0); ?> <span class="d" style="display: block; width: 100%; line-height: 25px; text-align: center"><b>Backlog:</b> <a href="mark_queue.php">Marked Messages</a> - <b><?= $num_msgs ?></b> / <a href="man_act_user.php">Inactive Users</a> - <b><?= $num_pend_users ?></b></span> <?php}//// Set Common Query String Variables//$q_string_x = '';$q_string_x .= isset($_GET['board']) ? 'board=' . $_GET['board'] : '';$q_string_x .= isset($_GET['topic']) ? '&topic=' . $_GET['topic'] : '';$q_string = array();$q_string['a'] = '';$q_string['b'] = '';if ($q_string_x != ''){ $q_string['a'] = '?' . $q_string_x; $q_string['b'] = '&' . $q_string_x;}?>[/codeBOX]

    This should work, you had put a single quote in the string you were trying to echo.Use notepad, turn off Word wrap, and press ctrl G


  4. <?php$_CONFIG['mbname']    = 'Giga Pass';    // Giga Pass$_CONFIG['mbsurl']     = 'http://gigapass.trap17.com';    // [url=http://gigapass.trap17.com]http://gigapass.trap17.com[/url]$_CONFIG['dbhost']    = 'Xisto.com';    // Xisto.com$_CONFIG['homepage']   = 'http://gigapass.trap17.com';    // [url=http://gigapass.trap17.com]http://gigapass.trap17.com[/url]$_CONFIG['legal_tags'] = 'b|i'; // HTML tags allowed in messages. You can only add tags that have no attributes./////// Set these variables://////////THESE MUST BE SET CORRECTLY!$_MYSQL['dbhost']      = 'localhost';    // localhost$_MYSQL['dbuser']      = 'dayzed_ejashby';    // dayzed_ejashby$_MYSQL['dbpass']      = '';    // (I put the password for dayzed_ejashby here)$_MYSQL['dbname']      = 'dayzed_SQLdatabase';    // dayzed_SQLdatabase//// User level definitions//define('Inactive', 0);define('Warned', 1);define('Mutie', 12);define('Rookie', 15);define('Veteran', 18);define('Idol', 30);define('Moderator', 52);define('Administrator', 60);//// Include money (Coins) configuration. Go edit that file.//require 'mny_config.php';$db = @mysql_connect($_MYSQL['dbhost'], $_MYSQL['dbuser'], $_MYSQL['dbpass'])or die("<b>Error:</b> Failed to connect to database host: {$_MYSQL['dbhost']}<br />     <b>Possible Solution:</b> Check if the database host name, user name and password are defined     correctly in the config.inc.php file.<br />     <b>MySQL says:</b> ". mysql_error());@mysql_select_db($_MYSQL['dbname'], $db)or die("<b>Error:</b> Failed to select database: {$_MYSQL['dbname']}<br />     <b>Possible Solution:</b> Check if the database is set up and the database name     defined in the config.inc.php file is correct.<br />     <b>MySQL says:</b> ". mysql_error());?>

    Try this, but make sure the variables are set properly.

  5. No, the "//" means what ever is after it is a comment but you should probably set thoose variables like this:

    $_CONFIG['mbname']    = 'Giga Pass';    // Giga Pass$_CONFIG['mbsurl']     = 'http://gigapass.trap17.com';    // [url=http://gigapass.trap17.com]http://gigapass.trap17.com[/url]$_CONFIG['dbhost']    = 'Xisto.com';    // Xisto.com$_CONFIG['homepage']   = 'http://gigapass.trap17.com';    // [url=http://gigapass.trap17.com]http://gigapass.trap17.com[/url]$_CONFIG['legal_tags'] = 'b|i'; // HTML tags allowed in messages. You can only add tags that have no attributes.

    Or use whatever values you want.

  6. Try this, make sure you set the variables.
    Before you weren't actually telling the mysql server anything.

    <?php$_CONFIG['mbname']    = '';    // Giga Pass$_CONFIG['mbsurl']     = '';    // [url=http://gigapass.trap17.com]http://gigapass.trap17.com[/url]$_CONFIG['dbhost']    = '';    // Xisto.com$_CONFIG['homepage']   = '';    // [url=http://gigapass.trap17.com]http://gigapass.trap17.com[/url]$_CONFIG['legal_tags'] = 'b|i'; // HTML tags allowed in messages. You can only add tags that have no attributes./////// Set these variables:$_MYSQL['dbhost']      = '';    // localhost$_MYSQL['dbuser']      = '';    // dayzed_ejashby$_MYSQL['dbpass']      = '';    // (I put the password for dayzed_ejashby here)$_MYSQL['dbname']      = '';    // dayzed_SQLdatabase//// User level definitions//define('Inactive', 0);define('Warned', 1);define('Mutie', 12);define('Rookie', 15);define('Veteran', 18);define('Idol', 30);define('Moderator', 52);define('Administrator', 60);//// Include money (Coins) configuration. Go edit that file.//require 'mny_config.php';$db = @mysql_connect($_MYSQL['dbhost'], $_MYSQL['dbuser'], $_MYSQL['dbpass'])or die("<b>Error:</b> Failed to connect to database host: {$_MYSQL['dbhost']}<br />       <b>Possible Solution:</b> Check if the database host name, user name and password are defined       correctly in the config.inc.php file.<br />       <b>MySQL says:</b> ". mysql_error());@mysql_select_db($_MYSQL['dbname'], $db)or die("<b>Error:</b> Failed to select database: {$_MYSQL['dbname']}<br />       <b>Possible Solution:</b> Check if the database is set up and the database name       defined in the config.inc.php file is correct.<br />       <b>MySQL says:</b> ". mysql_error());?>


  7. Go to, Cpanel click on file manager, click on the folder next to "public_http", click on index.html then click edit on the right. A window will open with the code to the index page. Make sure that the files you uploaded are in the public_http folder or you won't be able to access them.You need to make a database before you can access it. To make a database go to cpanel, click on MySQL Databases, type whatever you want to call the database in the textbox and click "Create MySQL database". Then create a new user to access the database. Click on "go back", scroll down to where it says "Existing MySQL Users", type a name for the new user there and a password. Click "Create MySQL user". Now allow the user to change the database. Click "go back", scroll to where it says " Grant permissions on a MySQL database to a MySQL user" and choose the user you made and the database you made. make sure "ALL" is clicked under privileges then click "Grant Permissions".The database name is then the "YOURUSERNAME_YOURDATABASENAME" and then your username is "YOURCPANELUSERNAME_YOURDATABASEUSERNAME"


  8. OK, I can use the TAPI to dial/answer the telephone, use the modem and stuff but I don't know how to get my program to use a .wav file that I have create to play it on the line. I know I have to use MCI functions but that's where I get lost. Any help would be appreciated!Also, if the MCI must be used to send .wav files through the telephone would it be better just to use the MSComm control? Or is the TAPI necessary for such and application to work?Thanks!


  9. I'm not sure if this will work, and there is probably a better way to do this but you might as well give it a try.

    ID is the primary key of the table.
    C1 is the column with the number to be subtracted.
    C2 is the number you are subjection from.
    T1 is the name of the table.

    <?php$result = mysql_query("select ID, C1, C2 from T1");while($row = mysql_fetch_array($result)){  $row[2] = $row[2] - $row[1];  mysql_query("update T1 set C2 = '$row[2]' where ID = '$row[0]");}?>

    Let me know if I screwed up and what the error is and I'll see if I can fix it....

  10. I believe that this should work. Couple things I noticed, first you set the caption of you label to "" thus the functions that depended on that value wouldn't work. Next the LET is not necessary and the LONG if...elseif...endif statement was WAY too long, I replaced it with something I think should do the same trick. I might have messed up a few of the controls names....

    Private Sub Form_Load()lbltime.Caption = "1"Timer1.Enabled = TrueTimer2.Enabled = FalseEnd SubPrivate Sub txtStatus_Change()If frmmain.WindowState = 1 Then    Timer2.Enabled = TrueElse    Timer2.Enabled = False    frmmain.Caption = "AdCache Remover"End IfEnd SubPrivate Sub cmdQuit_Click()EndEnd SubPrivate Sub Timer1_Timer()lbltime.Caption = Str((lbltime.Caption) + 1)lblstatustime.Caption = Str((lblstatustime.Caption) + 1)On Error Resume Nextx = Len(Dir$("c:\Windows\System\AdCache\*.*")) 'If you have a different directory for the AdCache change it.If Err Or x = 0 Then fileexists = False Else fileexists = TrueIf lbltime.Caption = 1 Then    If fileexists = True Then        Kill ("C:\Windows\System\AdCache\*.*") 'If you have a different directory for the AdCache change it.        txtstatus.Text = "Deleting AdCache"        lbltime.Caption = 0    Else        txtstatus.Text = "Removing"        lblstatustime.Caption = 0    End IfEnd IfIf lblstatustime.Caption = 21 Then    txtstatus.Text = txtstatus.Text & ""    lbltime.Caption = 0Else    txtstatus.Text = String(lblstatustime.Caption, ".")End IfEnd SubPrivate Sub Timer2_Timer()Let lblCaptionTime.Caption = Str((lblCaptionTime.Caption) + 1)If lblCaptionTime.Caption = 2 Then    lblCaptionTime.Caption = 0End IfIf lblCaptionTime.Caption = 0 Then    frmmain.Caption = "AdCache Remover"ElseIf lblCaptionTime.Caption = 1 Then    frmmain.Caption = txtstatus.TextEnd IfEnd Sub



    If you need help (Or I screwed this up) just ask me, also remember to put you code within the code tags so you aren't docked posting points. The code tags are "[ CODE ]" to start the code section and "[ /CODE ]" to end the code. Without the spaces and quotes of course... :)

  11. Well the web site that I have created I threw together over a couple of months for my friends and myself to play a small multiplayer game. I had it hosted at another free web hosting service and was still in the process of debugging etc. When the site shutdown so now I'm here( :) ). But I was just making the game as I LOVE to create the code because I can do something artistic that looks cool even though I can't draw at all. :P


  12. I saw something a while ago in a science magazine.The current CD\DVD works with a "pit" which reflects the laser into a direction to repersent a 1 or 0. In each of these "pits" there are other areas which also reflect the beam but the current technology doesn't read/write to this. So by harnassing this they would be able to increase the amount of data that could be stored on a disk by, well, alot! :) I wish I could find the article...... But ya it is really cool.


  13. LOL, ya but what if those little chips in our head turn out to control us instead of the other way around. Hard to defend against the evil robot invasion if we can't lift our cyborg arm, or worse if our cyborg leg kicks our butts.

     

    Seriously though, I see both pros and cons to this tech. It is inevitable, but I am not sure that it is 100% benifitial to the human race. Sure its great for the handycapped, and for that reason alone I say the good outweighs the bad, but what about the guy who gets a robotic arm so he can outpitch any pitcher in the MBA? Sippery sloap that.

    69378[/snapback]

    Currently the way the chip is designed it doesn't send signals in to the brain but it is obviously very adaptable to do so...

     

    wow, thats pretty hardcore.

    i mean the things u cud do with that type of tevchnolgoy are endless.

    But there r probably side affects of using it for long amoutns of time, like head aches etc also if the tech was mass marketed ppl cud get amazingly lazy.

     

    just thinking of all the applicatiosn for this tech is koo. u cudactually have working mech suits and stuff :D

    69426[/snapback]

    There really shouldn't be any headache side effects from this. The interface just reads what your neurons are doing. To control this you use the same process as when you control your arm. And of course people could become extremely lazy! You now the scenario where we evolve into just a brain! :)

     

    exactly, just imagine a guy like this Matthew Nagle being able to just get up and walk out of his weelchair thanks to a working mechanical suit.

     

    Of course this also means that there could be military type mech suits available too. Just what the world needs, more military technology (note the sarcasm).

    69444[/snapback]

    They are attempting to not have to use any sort of prosthetics to get the paralyzed people move again. What they what to do is to be able to send the neuron signals to the rest of the brain bypassing the break in the nervous system. In a way much cooler and nicer for the person, turns them into less of a freak.

     

     

    The things that I am most worried about the tech is what is most likely to happen, the military side of the technology, here is the dream of one the military people who are supporting the research of this tech:

     

    At a conference in 2002, Anthony Tether, the director of Darpa, envisioned the military outcome of BCI research. "Imagine 25 years from now where old guys like me put on a pair of glasses or a helmet and open our eyes," Tether said. "Somewhere there will be a robot that will open its eyes, and we will be able to see what the robot sees. We will be able to remotely look down on a cave and think to ourselves, 'Let's go down there and kick some butt.' And the robots will respond, controlled by our thoughts. Imagine a warrior with the intellect of a human and the immortality of a machine."

    This was from here: http://forums.xisto.com/no_longer_exists/=

     

    While the advantageous are very numerous this tech. needs to be watch very closely because of the VERY bad things that could come from it......

     

     

     

    But still I cannot wait to see if it becomes available to the public! :P


  14. http://forums.xisto.com/no_longer_exists/Braingate article

    This is really cool. While it has been in development for a while in monkeys this article really explains what has happened.
    The baingate is a small chip that is placed on the persons brain and senses the firing neurons. It send this information to a processing computer which translates it. The current test subject, Matthew Nagle, has been able to move a curser across the computer screen, turn the TV on/off, change channels etc.

    The tests that they've done previously on monkeys allowed the monkeys to integrate mechanical arm into themselves.

    What are peoples views on this new technology?

    Personally I think that it could be a very good as quadriplegic people would be able to get a life back but it also has its potential problems. I dont like the view that certain government officials have for using this to control robots that are in the field so that they have human intelligence but the efficiency of a machine.


    Some more links:

    http://forums.xisto.com/no_longer_exists/
    http://forums.xisto.com/no_longer_exists/
    http://www.cyberkineticsinc.com/
    http://forums.xisto.com/no_longer_exists/
    http://forums.xisto.com/no_longer_exists/
    http://www.livescience.com/161-monkey-brain-runs-robotic-arm.html

    These links include some other experiments that have been done with this type of technology, including external sensors.
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | 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.