Forum: C++
May 4th, 2008, 4:52 PM
|
|
Replies: 12
Views: 433
Re: Simple if statement question :(
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <iostream>
#include <cctype>
#include <windows.h>
//"Mage Wars" copyright Crimson Games 2007. All rights reserved.
//Created by...
|
Forum: C++
May 4th, 2008, 4:02 PM
|
|
Replies: 12
Views: 433
Re: Simple if statement question :(
Hey, cool! Thanks a lot, that was very helpful. I couldn't help but catch the "bool" an and then the variable bCont after it.
What exactly is bool? I thought I would use "string" for that, simply...
|
Forum: C++
May 4th, 2008, 11:39 AM
|
|
Replies: 12
Views: 433
|
Forum: C++
May 4th, 2008, 11:25 AM
|
|
Replies: 12
Views: 433
Re: Simple if statement question :(
Thanks, peaceofpi. That was helpful and I've fixed my problem; yes I want to get deeper and more complicated in this simple program I have built.
#include <iostream>
#include <string>
using...
|
Forum: C++
May 4th, 2008, 10:59 AM
|
|
Replies: 12
Views: 433
|
Forum: C++
May 4th, 2008, 10:38 AM
|
|
Replies: 12
Views: 433
Re: Simple if statement question :(
Silly me :icon_redface:
Thanks... and just out of curiosity, how can I get the program to go back to the start after ending instead of "Press any key to continue" and the command prompt exits?
|
Forum: C++
May 4th, 2008, 9:30 AM
|
|
Replies: 12
Views: 433
Simple if statement question :(
I haven't used C++ in a while, and right when I get back to starting up again, I fall upon this simple error in my simple code here:
#include <iostream.h>
#include <stdio.h>
#include <string>
using...
|
Forum: PHP
Mar 26th, 2008, 7:26 PM
|
|
Replies: 19
Views: 571
|
Forum: PHP
Mar 26th, 2008, 4:32 PM
|
|
Replies: 19
Views: 571
Re: Simple PHP Search Script
No, a friend gave me the script to practice on.
Now- I believe that solves everything really. Now I need to figure out how to make the outputed searched material have a link to a review page for...
|
Forum: PHP
Mar 26th, 2008, 4:14 PM
|
|
Replies: 19
Views: 571
Re: Simple PHP Search Script
SWEET :D
Now a simple problem here:
What it does is this:
SELECT * FROM users WHERE info LIKE '%JIM%'Jim Jones
In his spare time Jim enjoys biking, eating pizza, and classical music
That's what it...
|
Forum: PHP
Mar 26th, 2008, 3:50 PM
|
|
Replies: 19
Views: 571
Re: Simple PHP Search Script
Ahh okay, I got it now. No errors anymore- now just this:
SELECT * FROM users WHERE info LIKE '%PEGGY%'Sorry, but we can not find an entry to match your query
So peggy which is in the database...
|
Forum: PHP
Mar 26th, 2008, 3:13 PM
|
|
Replies: 19
Views: 571
Re: Simple PHP Search Script
Okay, done.
Now I get this error:
SELECT * FROM users WHERE info LIKE '%HELLO%'You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right...
|
Forum: PHP
Mar 26th, 2008, 2:45 PM
|
|
Replies: 19
Views: 571
Re: Simple PHP Search Script
Okay. Here is my MySQL code:
CREATE TABLE users (fname VARCHAR(30), lname VARCHAR(30), info BLOB);
INSERT INTO users VALUES ( "Jim", "Jones", "In his spare time Jim enjoys biking, eating pizza,...
|
Forum: PHP
Mar 26th, 2008, 2:20 PM
|
|
Replies: 19
Views: 571
|
Forum: PHP
Mar 26th, 2008, 1:39 PM
|
|
Replies: 19
Views: 571
Re: Simple PHP Search Script
Okay, thanks... and I tried that. Now it's bringing the error that I forgot to type something in the search for some reason.. (when I am typing in the search is still does the same thing..).
EDIT:...
|
Forum: PHP
Mar 26th, 2008, 1:18 PM
|
|
Replies: 19
Views: 571
Simple PHP Search Script
I put this all on index.php:
<html>
<head>
<title>arnack.com Gaming Wesbite Database</title>
</head>
<body>
<h2>Search</h2>
<form name="search" method="post" action="<?=$PHP_SELF?>">
Seach for:...
|
Forum: C++
Aug 14th, 2007, 9:17 PM
|
|
Replies: 45
Views: 1,013
|
Forum: C++
Aug 14th, 2007, 6:12 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 14th, 2007, 5:23 PM
|
|
Replies: 47
Views: 1,078
Your talking like the goto command is the death...
Your talking like the goto command is the death to all of us...
And don't get me wrong, I've tried functions so many times, over and over and over, but I always end up with this error (No matter what...
|
Forum: C++
Aug 14th, 2007, 2:03 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 14th, 2007, 1:33 PM
|
|
Replies: 45
Views: 1,013
|
Forum: C++
Aug 13th, 2007, 8:45 PM
|
|
Replies: 47
Views: 1,078
Alright, really simple question.
dmg = rand() %...
Alright, really simple question.
dmg = rand() % 12 + 7;
This randomizes a number 7-12. (which I use as your damage during a fight)
I need a way to be able to add each number (12, and 7) by 3. (so it...
|
Forum: C++
Aug 13th, 2007, 5:36 PM
|
|
Replies: 47
Views: 1,078
DaWie, you see, I have gotten 1/4 of my C++...
DaWie, you see, I have gotten 1/4 of my C++ tutorial done. With what I have learned, I would be able to create a text RPG using Ifs, elses, and loops. I learn the code I copy paste, sometimes...
|
Forum: C++
Aug 13th, 2007, 1:50 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 11th, 2007, 11:35 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 11th, 2007, 11:00 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 11th, 2007, 9:40 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 11th, 2007, 7:07 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 11th, 2007, 11:11 AM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 11th, 2007, 11:09 AM
|
|
Replies: 45
Views: 1,013
:P Yeah DaWei seems like he doesn't have much...
:P Yeah DaWei seems like he doesn't have much else to do but lay around on these forums rambling about how he is better than C++ than the newbies.
Sad, if you ask me.
Anyways, on topic:
What's your...
|
Forum: C++
Aug 11th, 2007, 12:50 AM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 10th, 2007, 11:32 PM
|
|
Replies: 47
Views: 1,078
Well I'm a newbie, and I don't really get what...
Well I'm a newbie, and I don't really get what you said. :P
I mean yeah, that would help dramatacly, I'm just trying to get this thing to work... I need something that returns you back to the main...
|
Forum: C++
Aug 10th, 2007, 11:15 PM
|
|
Replies: 45
Views: 1,013
|
Forum: C++
Aug 10th, 2007, 11:03 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 10th, 2007, 10:33 PM
|
|
Replies: 47
Views: 1,078
Thanks guys, all is going well, but I have a...
Thanks guys, all is going well, but I have a question...
//attack one
if (enemyhealth <= 0)
{
cout << "You have slain the vile enemy! You now gain 10 gold!";
money = money + 10;
}
else if...
|
Forum: C++
Aug 10th, 2007, 9:25 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 10th, 2007, 8:45 PM
|
|
Replies: 47
Views: 1,078
Okay, having some trouble, again.
#include...
Okay, having some trouble, again.
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
//"Mage Wars" copyright Crimson Games 2007. All rights reserved.
//Created by Arnack, distributing this...
|
Forum: C++
Aug 10th, 2007, 8:07 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 10th, 2007, 7:52 PM
|
|
Replies: 47
Views: 1,078
|
Forum: C++
Aug 10th, 2007, 7:24 PM
|
|
Replies: 47
Views: 1,078
|