rajivgonsalves
Members-
Posts
2,166 -
Joined
-
Last visited
Never
Everything posted by rajivgonsalves
-
Yeah used it too its cool
-
try this text = text.replace(/y/g, 'why')
-
use str_replace on the data http://php.net/str_replace
-
Is your page hosted on a web server or on your local machine
-
hang when from one page log into another page.
rajivgonsalves replied to zgkhoo's topic in PHP Coding Help
because $i will never get increment so while ($i < $length) will always be true -
hang when from one page log into another page.
rajivgonsalves replied to zgkhoo's topic in PHP Coding Help
Yes but the following code will go in an infinite loop if (!strstr($password, $char)) { $password .= $char; $i++; } because all 0-9 numbers will be used and then it will keep on looping -
hang when from one page log into another page.
rajivgonsalves replied to zgkhoo's topic in PHP Coding Help
($type=='Number'){//1 $possible="0123456789"; }// -
it depends how many user u go try this following code, also one thing do you have ob_start() in your config file <?php //Connect to My Gaming Ladder database include('config/config.php'); $query = mysql_query("SELECT * FROM users") or die("Error: ".mysql_error()); //How many MGL users are there? $numusers = mysql_num_rows($query); include('community/Settings.php'); $hdlComDataBase = mysql_connect($db_server, $db_user, $db_passwd,true) or die("Could not connect to SMF database server: ".mysql_error()); mysql_select_db($db_name,$hdlComDataBase) or die("Could not select SMF database: ".mysql_error()); if($numusers == 0){ "There are no users registered on My Gaming Ladder."; } else { while($fetch=mysql_fetch_array($query, MYSQL_ASSOC)){ $id=$fetch["id"]; $alias=$fetch["alias"]; $pass=$fetch["pass"]; $email=$fetch["email"]; $icq=$fetch["icq"]; $aim=$fetch["$aim"]; $msn=$fetch["msn"]; $yahoo=$fetch["yahoo"]; $website=$fetch["website"]; $ipaddress=$fetch["ipaddress"]; echo "Converting MGL member <b>$alias</b> to SMF... "; //Connect to SMF database $query2 = mysql_query("SELECT * FROM smf_members WHERE memberName = '$alias'", $hdlComDataBase) or die("Could not search users: ".mysql_error()); $exists = mysql_num_rows($query2); //If the selected user doesn't exist in the SMF forum database... if($exists==0){ $query3 = "INSERT INTO smf_members (memberName,passwd,emailAddress,websiteUrl,ICQ,AIM,YIM,MSN,memberIP) values ('$alias', '$pass', '$email', '$website', '$icq', '$aim', '$yahoo', '$msn', '$ipaddress')"; //If the query is successfull if(mysql_query($query3,$hdlComDataBase)){ echo "Added MGL member <b>$alias</b> to the SMF forum database."; //Otherwise... } else { echo "There was an error adding the MGL member <b>$alias</b> to the SMF forum database."; } } else { echo "The MGL member <b>$alias</b> was not added because he/she is already a member of the SMF forum."; } } } ?>
-
well you connecting to another database so your link should be new $newlink = mysql_connect($db_server, $db_user, $db_passwd,true) or die("Could not connect to SMF database server: ".mysql_error()); mysql_select_db($db_name,$newlink) or die("Could not select SMF database: ".mysql_error()); $query2 = mysql_query("SELECT * FROM smf_members WHERE memberName = '$alias'",$newlink) or die("Could not search users: ".mysql_error()); $exists = mysql_num_rows($query2); and mysql_query($query3,$newlink)
-
instead of echo "$blcktime:$blckmins"; try $intSeconds = ($blcktime*3600)+($blckmins*60); echo floor($intSeconds/3600).":".floor($intSeconds/60)%60;
-
hang when from one page log into another page.
rajivgonsalves replied to zgkhoo's topic in PHP Coding Help
it will hang if you choose activation code as number because of this if (!strstr($password, $char)) { $password .= $char; $i++; } you have only 10 numbers and they cannot repeat so how will you generate a 13 digit activation code ? -
hang when from one page log into another page.
rajivgonsalves replied to zgkhoo's topic in PHP Coding Help
what is your code for function.php ? -
try using your PC name instead of localhost
-
this has got to do with the mysql server settings read more at http://dev.mysql.com/doc/refman/5.0/en/adding-users.html you hostname has to exists for that username in the hosts table of the mysql database
-
you can read the following http://www.evolt.org/article/comment/17/60265/index.html
-
try the <> instead of the !=
-
Button that opens Popup and changes parent url?
rajivgonsalves replied to Gutspiller's topic in HTML Help
put it in the popup window little change in code <script> if (parent) { parent.document.location.href = "http://..."; } </script> -
somecode would be helpful
-
well pocobueno1388 has the right approach if your try something advance try the soundex http://dev.mysql.com/doc/refman/5.0/en/string-functions.html#function_soundex
-
anytime dude! no proble at all
-
you forgot the break case '3': $MessageID = $rowthree['MessageID']; $Update = "UPDATE messages SET Status = '3' WHERE MessageID='$MessageID'"; $result = mysql_query($Update) or die(mysql_error()); break; default: die ("invalid message selected"); break;
-
try this for that one line echo "<td href='javascript:void(0);' onmouseover=\"return overlib(showRest2('" . $row[18] . "' ,'" . $row[3] ."'), MOUSEOFF, BACKGROUND);\" onmouseout=\"return nd();\">link</td>";
-
ok got it try this if (!empty($_POST)) { sendMail(); } instead of sendMail();
-
can you put some chucks of your code maybe more than 5 lines before and after its echoed ?
-
Ok if you could give an explaination of your registration and which function is called on which page it would be helpful.