Jump to content

ajaxsoundscool

Members
  • Posts

    10
  • Joined

  • Last visited

Everything posted by ajaxsoundscool

  1. Hi folks! Im trying to implement an Ajax chat client to my website, and im having issues with the implementation of the files., This is a third party code, the link is here... http://ajaxim.com/ Now, i have my database set up etc... but when i implement this code into my pages, the chat box doesnt show, and if i ftp the ajaxim.php file in standalone as it were, i get this error, even though the files are there. Fatal error: require_once() [function.require]: Failed opening required '../ajaxim/libraries/dbMySQL.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/guyrich/public_html/ajaxim/ajaxim.php on line 30 The snippet of code im using to implement the chat system in my <head> is <script type="text/javascript" src="ajaxim/js/im.load.js"></script> This is bugging me big time, and by the sounds of it, others are having this issue also. Im not excellent with coding, im a learner. Your help is most appreciated
  2. Hi guys, Im new to coding, learning fast! I have built a simple social networking website and im trying to implement a chat system on my site.. im using this resource. http://old.ajaxim.com/ Im following the database connection and i get this error.. Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'user'@'localhost' (using password: YES) in /home/guyrich/public_html/AJAX IM/install.php on line 135 Here is the code for the connection file. <? /////////////////////////////////// // ajax im 3.41 // // AJAX Instant Messenger // // Copyright © 2006-2008 // // http://www.ajaxim.com/ // // Do not remove this notice // /////////////////////////////////// // MySQL Database Configuration $sql_user = 'user'; $sql_pass = ''; $sql_host = 'localhost'; $sql_db = 'ajaxim'; // This is the prefix for the ajax im MySQL tables -- this can usually be left alone. // (If upgrading from a version < 3.1, set the prefix to '') define('SQL_PREFIX', 'ajaxim_'); $maxBuddyIconSize = 100; // in KBs, set to 0 to disable uploads ?> This may seem like a lame question, but how do i configure this to connect to my database :/ Cheers Guy
  3. Hi guys, it was a silly error, I forgot to include a check_login_status.php file at the top of the page. Did that, everything works swimmingly, well...in terms of messages flying backwards and forwards. Now i just have the issue or having to refresh the page to view messages all the time,,, its not instant, so the next task is to set up an instant message system. This is something i haven't ventured into yet so if anyone knows any great resources, please let me know Thank you all for your help! Guy
  4. Do you think it could be that its checking for new PM's for logged in users and wont connect to the database because their not logged in?
  5. Hey, thanks for the replies. db_connex does exist, my update status section works fine with the db_connex, and the private message function connects fine too, this error pops up in a section of code that tells the .gif on page top to animate when a new message is received this works fine... I only get the error on my signup page, so when a user isn't logged in i think the code is failing to say that the icon should be inaccessible for not logged in users. My db_connex.php is located in a php includes folder.. <?php $db_connex = mysqli_connect("localhost", "username", "*****************.", "guyrich_social"); //Evaluate the connection if (mysqli_connect_errno()) { echo mysqli_connect_error(); exit(); } ?> And here is the code snippet from template_pageTop.php <?php //check for new pm's $pm_n = '<img src="../images/pmStill.gif" width="17" height="12" alt="Pm" title="This pm is for logged in members">'; $sql = "SELECT id FROM pm WHERE (receiver='$log_username' AND parent='x' AND rdelete='0' AND rread='0') OR (sender='$log_username' AND sdelete='0' AND parent='x' AND hasreplies='1' AND sread='0') LIMIT 1"; $query = mysqli_query($db_connex, $sql); $numrows = mysqli_num_rows($query); if ($numrows > 0) { $pm_n = '<a href="../pm_inbox.php?u='.$log_username.'" title="Private Message Notifier"><img src="../images/pmFlash.gif" width="17" height="12" alt="Pm"></a>'; } else { $pm_n = '<a href="../pm_inbox.php?u='.$log_username.'" title="Private Message Notifier"><img src="../images/pmStill.gif" width="17" height="12" alt="Pm"></a>'; } // It is important for any file that includes this file, to have // check_login_status.php included at its very top. $envelope = '<img src="images/note_dead.jpg" width="22" height="12" alt="Notes" title="This envelope is for logged in members">'; $loginLink = '<a href="login.php">Log In</a> | <a href="signup.php">Sign Up</a>'; if($user_ok == true) { $sql = "SELECT notescheck FROM users WHERE username='$log_username' LIMIT 1"; $query = mysqli_query($db_connex, $sql); $row = mysqli_fetch_row($query); $notescheck = $row[0]; $sql = "SELECT id FROM notifications WHERE username='$log_username' AND date_time > '$notescheck' LIMIT 1"; $query = mysqli_query($db_connex, $sql); $numrows = mysqli_num_rows($query); if ($numrows == 0) { $envelope = '<a href="notifications.php" title="Your notifications and friend requests"><img src="images/note_still.jpg" width="22" height="12" alt="Notes"></a>'; } else { $envelope = '<a href="notifications.php" title="You have new notifications"><img src="images/note_flash.gif" width="22" height="12" alt="Notes"></a>'; } $loginLink = '<a href="user.php?u='.$log_username.'">'.$log_username.'</a> | <a href="logout.php">Log Out</a>'; } ?>
  6. Hi guys, Im learning to code, i followed some tutorials online on how to make a simple social network website.. I have the bare bones of the sight but it looks shocking and theres a few errors... www.just-vent.com now... I want o create a pretty cool layout for all my content, and im just beginning with code... Is there any simple way of taking my code and applying it to a new style with little coding? Or would anyone be able to wedit my stylesheet if i send over the existing code and a file with all the slices and a note document with all the dimensions? I tried playing around with error after error :/ Cheers Guy
  7. Hi guys, somehow, re-uploading the files to the server fixed the issue :/... however, there is a problem with my pm messages... when in chat with someone, you have to refresh the page before you actually get the message. Is there any way of telling the chat box to auto refresh one a new message has been replied to you? I also have another issue, my signup page returns this error... the code that the error is talking about is a code that tells a gif to flash when a new private message is recieved... So, im guessing its something that is to do with the logged in users bit... Warning: mysqli_query() expects parameter 1 to be mysqli, null given in /home/guyrich/public_html/template_pageTop.php on line 9 Warning: mysqli_num_rows() expects parameter 1 to be mysqli_result, null given in /home/guyrich/public_html/template_pageTop.php on line 10 Here is the code for the template_pageTop.php... <?php //check for new pm's $pm_n = '<img src="../images/pmStill.gif" width="17" height="12" alt="Pm" title="This pm is for logged in members">'; $sql = "SELECT id FROM pm WHERE (receiver='$log_username' AND parent='x' AND rdelete='0' AND rread='0') OR (sender='$log_username' AND sdelete='0' AND parent='x' AND hasreplies='1' AND sread='0') LIMIT 1"; $query = mysqli_query($db_connex, $sql); // $numrows = mysqli_num_rows($query); // These are the lines in question... 9 and 10 if ($numrows > 0) { $pm_n = '<a href="../pm_inbox.php?u='.$log_username.'" title="Private Message Notifier"><img src="../images/pmFlash.gif" width="17" height="12" alt="Pm"></a>'; } else { $pm_n = '<a href="../pm_inbox.php?u='.$log_username.'" title="Private Message Notifier"><img src="../images/pmStill.gif" width="17" height="12" alt="Pm"></a>'; } Cheers, Guy
  8. www.webintersect.com or www.developphp.com great tutorials! Im a beginner too and im trying to build a PM system. mines working, but my issue is that when i send a message to someone, it all goes through great etc... that person receives the message however it doesnt pop up in the box, you have to refresh the damn page all the time! so annoying and i cant get my head around it. If anyone can help me, please do, i will send over my PM system code and details of the mysqli database. Cheers Guy
  9. Hey,thanks for the reply No i didnt write the code, im following a bunch of tutorials, i have added some of my own basic coding however. I have set up the tables as the tutorial states, then implemented the code, all the file names are correct and in the propper locations in the root ad sub folders. I think it could be that (A) the pm_system.php file has something that isnt communicating with the enum values of the pm table, or (B) the table somehow isnt allowing the connection for the enum values due to something i could have overlooked. I would be willing to upload the system script and a screenshot of my tables if anyone would care to take a look? Regards Guy
  10. Hi guys, im looking for someone to help me with a PM system for my site at www.just-vent.com Its very basic and the graphics are awful, but im trying to get the bare bones of the site before i style it. So far i have been following tutorials on creating the site and im stuck with the PM system. I can send and receive messages as ''parent'' messages and it displayes in mysqli table for the pm message system however, on my inbox forms, there are 3 options for each message.. mark as read, delete and reply... none of them work, you can enter txt and press all the buttons, the buttons animate.rollover, but nothing happens... If anyone would be willing to help it would be gratefully received. Regards Guy
  11. Hi everyone! Im learning php and im currently making a simple social networking site and im STUCK with the private message system and sending values to the mysqli database... I am looking to make some friends who are awesome with coding for skype session etc to make my idea a reality. My site is in its very (graphically awful) stages, but the drive and passion is there so thats a good start If anyone is willing to help,,, my trade i am a professional musician and music/media producer, so creating online advertising packages comes with the gratitude to anyone who is willing to help Hope to see some intuitive convos with you guys! Take care Guy And as for my username,, ajax does sound pretty cool.. , maybe a band name
×
×
  • 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.