Jump to content

onthespot

Members
  • Posts

    424
  • Joined

  • Last visited

    Never

Posts posted by onthespot

  1. ok i want to link people on my website to their gamercards on xbox live!

    <a href="http://profile.mygamercard.net/[b]gamertag[/b]">
    <img src="http://card.mygamercard.net/gel/Default/[b]gamertag[/b].png" border=0>

    The parts in bold are going to be the usernames of the people signed up to my website! so by using php, im sure there is a way to make their username go where the bold parts are, and for their gamercards to show up on their profile pages!

    could anyone help me?
  2. mate, PMSL, i no how to do html etc, im just starting at php though! but that php code, is like something that i cant seem to be able to use html on! its information requested from the DB, and therefore i cant make the font for it like i would anything else! so i was tryin to ask where i put the html? or the font face?
  3. <span class="style5">
    <?
    }

    echo "</td></tr><tr><td align=\"center\"><br><br>";
    echo "<b>Member Total:</b> ".$database->getNumMembers()."<br>";
    echo "There are $database->num_active_users registered members and ";
    echo "$database->num_active_guests guests viewing the site.<br><br>";

    include("include/view_active.php");

    ?>
    </span>


    [i]Can someone please help me! I want to make all the "echo" information, in a certain font, say Tahoma! Can someone please modify the code for me, would be greatly appreciated!

    Thankyou![/i]
  4. Please could you help me, the following is the code to login to my site:


    [code]$sql="SELECT loginid FROM userlogin WHERE loginid=’".$loginid.”’ and password=’”.$password.”’”; $r = mysql_query($sql); if(!$r) {

    $err=mysql_error();

    print $err;

    exit(); } if(mysql_affected_rows()==0){

    print "no such login in the system. please try again.";

    exit(); } else{

    print "successfully logged into system.";[/code]



    i am getting an error of [b]
    Parse error: parse error, unexpected '=' in authenticate.php on line 5[/b]

    i have not included the first 2 lines above this as they are just connecting and selecting the databse!
    any ideas?
  5. $sql = "INSERT INTO login_tbl (loginid, password [b]and email[/b]) VALUES ('$loginid', '$password', '$email')";

    that line there, i have changed the bold to

    $sql = "INSERT INTO login_tbl (loginid, password, email) VALUES ('$loginid', '$password', '$email')";

    and the insert into login_tbl to tbl_login because that is the table, i click and ive got a blank screen, maybe a sign that its working?
  6. i did that mate and it changed to this

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'and email) VALUES ('', 'psw', 'email@email.com')' at line 1

    the login_tbl in the line you specified, is the table with the ots_users database right? if so the actual table is called tbl_login?? does this make a difference?
  7. after doing that, i now get the following error:

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'and email) VALUES (\..\,\.psw.\,\.email@email.com.\)' at line 1

    any ideas?
  8. ok my database is ots_users, and the table i have created with loginid password and email is called tbl_login. is this all correct? and how do i test it to see if its working ok?
  9. i still havent got it mate, ive entered the databse which is ots_users and the password which is the password lol, so that is, "ots_users" "password" for them two. i think it is the other one i am having problems with, my sql database is online on my webspace so what do i put for that? thanx
  10. well thankyou very much, that has obviously fixed it, my only other problem is, it now says cannot connect to DATABSE lol, any ideas? wot do i put the three parts, "localhost" "username" "password"??
    in the username, the username for the database??
    password, password for database?
    wot about localhost?

    cheers m8
  11. hello there, im creating a login for my website, the html for the login page is below


    <form name="register" method="post" action="register.php">
      <input name="login id" type="text" value="loginid" size="20"/><br>
      <input name="password" type="text" value="password" size="20"/><br>
      <input name="email" type="text" value="email" size="50"/><br>
      <input type="submit" name="submit" value="submit"/>
      <input type="reset" name="reset" value="reset"/>


    this is the register.php file:


    <?php

    @mysql_connect("localhost", "usuallymyrealuser", "usuallymypassword") or die("Cannot connect to DB!");
    @mysql_select_db("tbl_login") or die("Cannot select DB!");
    $sql="INSERT INTO login_tbl (loginid, password and email) VALUES (".$loginid.”,”.$password.”,”.$email.”)”;
    $r = mysql_query($sql);
    if(!$r) {
      $err=mysql_error();
      print $err;
      exit();
    }

    ?>


    AFTER DOING THIS, AND SUBMITTING THE INFORMATION ON THE HTML PAGE, I GET THE FOLLOWING ERROR:

    Parse error: parse error, unexpected ',' in myaddress/register.php on line 5



    CAN U HELP PLEASE, IM NOT GREAT WITH PHP AND DONT UNDERSTAND THE PROBLEM!
    THANKYOU!
×
×
  • 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.