ewcreators
Members-
Content Count
60 -
Joined
-
Last visited
Everything posted by ewcreators
-
<script type='text/javascript'>function submitForm(){ var xhr; try { xhr = new XMLHttpRequest(); } catch(e) { xhr = new ActiveXObject(Microsoft.XMLHTTP); } xhr.onreadystatechange =function(){if(xhr.readyState == 4) {if(xhr.status == 200) document.getElementById('c').innerHTML="SENT";elsedocument.ajax.dyn.value="ERROR CODE" + xhr.status;}};var data=document.ajax.dyn.value;//var chat=document.ajax.ba.value;var final="&content="+data;xhr.open("GET","chat2.php?ba=<?php echo $_GET[a];?>" +final,true);xhr.send(data);}</script><?phprequire('connection2.php');require('sessions.php');require('details.php');$sel=mysql_query("SELECT * FROM `chat` ORDER BY `id` LIMIT 1,6 ");echo "<table border='1'> <tr><th colspan=2>SIDECHAT</th></tr><tr><td colspan=2>";while($row=mysql_fetch_array($sel)) {echo "<font color='yellow'><b>".$row['name']."</b></font>:<font color='gray'>".$row['content']."</font><br />";}echo "</td></tr><br /><tr><td colspan=2> <div id='c'> </div></tr></td></tr>";echo "<tr><td colspan=1><FORM method='POST' name='ajax' action=''><INPUT type='text' name='dyn' maxlength='40'></td><td><input type='submit' onClick='submitForm()' value='>' ></td></tr>";require('links.php');?> Now when that result shows, (it comes real time afcourse), how can i get others to show their results real time without have the current user to refresh/go to a different page? like msn ..etc you get the results directly real time/at the same time. How can i go about that? Also, i want to keep upto 6 results in my real time chat box, but the only method i know is off 1,6...which will only select the first 6 rows..please help!
-
Could Someone Proofread My Php Lottery Script.
ewcreators replied to coolcat50's topic in Programming
Post them here, im sure i can help -
Could Someone Proofread My Php Lottery Script.
ewcreators replied to coolcat50's topic in Programming
Nice script...I am working on a lotto-mysql based script for my game.Anyways, when you say automate, do you mean that you want it to automatically update their profile? Well, if your using a mysql database, then in the if($lottonum=$nument) bit, i suggest you do it like this (if you have the profiles stored in a database): <?phpif ($lottonum==$nument) {$qry=mysql_query("UPDATE table_name SET money='money+$lotto_won_credits' WHERE name='$_POST[name]'");echo "You won ___ amount of money. Congratulations! It has been added onto your profile.";}?> also for lottonum , to make sure they dont keep winning by entering the same number, use this random script: <?php$lottnum=rand(1,100);?>generates a number between 1 and hundred. Hope this helps -
In some games you see those graphical bars which show your experience or your hp/life ..etcHow can i make something like that in php?
-
Just incase some people find javascript or AJAX quite difficult ( i know i did/am) , you can also achieve this through php. It may require $_GET if its ok with you, but everything will come on one page <?phpif ($_GET['tab'] =="home") {//put the content for the main home page}else if($_GET['tab'] == "join") {//put joining code here}//..etc//..etc?> Hope that helps a little bit.
-
Forum Last Post And Avatar need little help here
ewcreators replied to vipervoid's topic in Programming
well, when the person posts, i suggest you make the action page a redirect which comes back to the original page + <?php//the page that updates everythingrequire('connection.php');require('sessions.php');require('user_stats.php');//determine whether it was a//edit or delete or new post through if/else//Insert /Update accordingly ^^//now use the last posted scrpt//if it is a new post$lp=mysql_query("UPDATE forum_posts SET lastposted='$_SESSION[username]'");//then you use a redirection to go back so that he cannot double post header('location:url');?> -
Forum Last Post And Avatar need little help here
ewcreators replied to vipervoid's topic in Programming
i think he wants the person who posted last to show up there. he could easily use an update query. -
Well I am making a php game (can't release the link yet as i still have to get the basics up) and im currently working on the attack script.Now i need a getting exp from the person you attack " formula.Please make it good ~Aldo
-
Please HElp.Can you teach me :a) How to use smilies with php so that if i want to create a post office or forum , a person who posts with or will get a smiley pic instead of just or . How to divide mysql results into pages~Thanks!
-
Whats Wrong>? please see this piece of code and see whats wrong:
ewcreators replied to ewcreators's topic in Programming
http://forums.xisto.com/no_longer_exists/ Its still in its basic steps as i am trying to make it a proper game so i have to make each and every page completely full proof. Register and login -
Whats Wrong>? please see this piece of code and see whats wrong:
ewcreators replied to ewcreators's topic in Programming
Great it works!Thanks A lot ! -
Whats Wrong>? please see this piece of code and see whats wrong:
ewcreators replied to ewcreators's topic in Programming
even since its a header page, ill go with post. And i know that is a huge security hole, i did that delibrately so that people could just login as i didnt want to keep the game down to long, ill try out == and also username=..... && password=.... Ill be sure to post results here. ~Aldo (P.S : dont delete/lock this thread) -
Ambitions is what makes people do something they want to do. Why dont you try flash and actionscript? seems fairly easy
-
Whats Wrong>? please see this piece of code and see whats wrong:
ewcreators replied to ewcreators's topic in Programming
I tried everything..it doesnt work...it just takes me to my error page which -
i tried to install : first turbo c++ (borland) and it said error writing to langDLL.dll same thing when i tried devshed. Please help! I just started learning c++, and this is my first: #include <iostream> using namespace std;int main() { cout << "Testing to check ";cin.get();} (Im using devshed 4.9.9.2 beta) i compile it , it compiles, i try to run it, it doesnt run..please help! Notice from rvalkass: Please don't double post. If you have something to add then use the edit button. Posts merged, and CODE tags added around the code.
-
Well everyone wants to be a game maker, game owner. Be it adventure games, action, rpg..etc,3d,2d...etc and the very known ,Online games, everyone wants to be a part of it. There are many ways to make a game. Programming languages such as java , c++ , javascript, flash/actionscript and other languages. There are also loads of programs out there, recently i bought a 3d gamemaker..its good. There are programs for making online games such as realm crafter or dark basic trials...but one must know some coding. Then there is the very famous, mostly used online : PHP Php ,a very powerful language, can be used to create almost anything. Its limitations are not known. If combined with javascript,css and ajax ..well .. It leads to powerful and "WOW" results. (believe me, i am playing such a game).. they are created in the form of online web/text based games. Now im focusing on php for now, because its the language i currently know the most 'bout. Infact not only php, but with many other languages you can make games. I'd suggest, like ive seen in many forums, start with actionscript and flash and try to master it. I dont know actionscript and not much flash used since 1-2 years but im starting now, and you should too. Then move onto complex languages like php for internet games or java or javascript and then finally C++. Get into a group, discuss some of your thoughts , ask for help . Even the simplest of doubts should be asked. Start your own group, work on a project, and one by one master everything. Just some thoughts on game creating, ~Aldo
-
require('connection2.php');$select=mysql_query("SELECT * from `users` WHERE password='$_GET[password]'");$co=mysql_num_rows($select);if ($co = 1){session_start();$s=session_id();$_SESSION['access']="yes";$username=$_GET['username'];header("location:../main/index2.php?a=$_GET[username]&s=$s");//echo "<a href='../main/index2.php' > Proceed to Game</a>";//echo $s;} Now that is a bit of my script for my login script to authenticate and stuff. Recently my game went down because there was some error in this. So i kept on trying and it didnt work. Now i found out, wait first let me tell you that over here users get registered for sessions, and if they arent register or are changing urls, they get redirected to an error page, that it always redirected to the error page meaning sessions weren't being registered. So i changed the error page to my game ingame page and it came there. With no luck, i was heading to bed when i mistakenly clicked a bookmarked link of the login file and saw that it said that i have to check the mysql syntax near 'password='passwordentered" at line one.
-
Google Vs *other Search Engine* Which is the best???
ewcreators replied to Thorn's topic in Search Engines
I prefer http://www.com/, which is a fast, easy, and fun way to find what you need. It is not as main stream as google, but it still shows good results almost every time, even for hard to find things. I also like http://de.ask.com/?o=312&l=dir because you can ask questions and it will give you answers, plus it doubles as a search engine. -
Yes I agree as well. I have worked out with one of my roomates for the past two years, since right after I came out of the US Marines, and I don't think I ever got out of shape, because my roomate pushed me to work hard, and I pushed him back. We have virtually the same scheduall as each other, so we can hit the gym almost every day and work hard for as long as possible.
-
Telemarketing Calls, How Do You Stop Them!?!
ewcreators replied to birudagmawi's topic in General Discussion
When telemarketers call, I say 'Um no thanks. Could you please take me off your list?" I mean there will still be an ocasional call, but they will not be calling quite as often. From what I know, there is no hotline to call for them to take you off their list, because diffrent telemarkets are calling for diffrent companies, and a hotline may take you off of one telemarketers list, but not every telemarketers list. -
This is one of my cars, a '69 Mustang: I do not really have any recent pics, but I just got it painted a cherry red. And I am saving up for a 2007 Ford Mustang GT, which I will buy right when I get out of college.
-
Well i just thought of another alternative : how about using if/else combined with mysql_affected_rows? that could help if it is one..then proceed , if it is more than it will stop the script and display an error message, and then he can use a redirect. So if the user clicks more than once, he will get errors.
-
Do You Know How To Cook? Who cooks their own food?
ewcreators replied to FLaKes's topic in Health & Fitness
Ys, I know how to cook well. I started when i was 8, because my parent's were not always around to cook, and I have gotten better and better. I can do all sorts of grilling, and fish is easy, plus I am great at cakes (decorating and all) and all sorts of other pastries. I am pretty good at pasta and sauces and ect., and I can make a mean soup. I have taken a class or two at college for culinary arts, but I don't plan on becoming a chef. But hey at least I will be able to cook for myself and my spouse if I get one.