569 Posted Topics

Member Avatar for GerryL417

Hey there, Possibly. PHP doesn't (that I know of) gain access to your computer without you being on a server, it is server-side and therefore needs to be on a server. You would therefore have to specifically download something and then run the application. Most of the links that you …

Member Avatar for <M/>
-1
130
Member Avatar for vizz

You've got more chance of finding a blonde virgin than finding a two worded domain ;-)

Member Avatar for ryantroop
0
125
Member Avatar for rayidi

Don't think I quite understand, or, if I do, why would you want to do such a thing.. Ok, have a form that asks the user if (s)he is a user or a re-seller. Then, create a database that stores this information. Everytime you want to check, you can check …

Member Avatar for rayidi
0
232
Member Avatar for mir.jde
Member Avatar for jamburn

Hello!! I don't know if I can offer much help, or, insight to this. You should think of the logic behind Programming as being: "Anyone can code. Anyone can Google. Does that make you a Programmer? It's understanding the logic and given a task to solve and finding the best …

Member Avatar for jamburn
0
219
Member Avatar for Helianthus

> ll concerned abo @Helianthus - In my opinion, learning C++/C will open you up to learning other languages, it will give you that foundation or stepping stone and other languages syntax will become more familiar. Obviously, if you want such jobs as a C++ programming, then, you have to …

Member Avatar for phorce
0
291
Member Avatar for hmooly

Excuse me? What do you think this is? Lol. Don't come here asking/demanding code to be written for you, atleast make an attempt. There are services out there, in which you can PAY developers to make such things.

Member Avatar for phorce
-3
31
Member Avatar for jkulp4

Hey, please try the following: <html> <Head> <Title>Drop Down Choice Example</title> <?php //connect to database, checking, etc include_once "connect.php"; // process form when posted if(isset($_POST['value'])) { if($_POST['value'] == 'Kulp') { // query to get all Kulp records $query = "SELECT * FROM names WHERE LastName='Kulp'"; } elseif($_POST['value'] == 'Smith') { …

Member Avatar for phorce
0
124
Member Avatar for phorce

Hello, wondering if someone can help me quickly.. Basically, I have created a array to store all the data in a text file. The pointer of the array is sent to a function, which then populates it. Here is the code: void Data(char* theData) { ifstream txtFile(inputFile.c_str()); if(!txtFile.is_open()) { cerr …

Member Avatar for Ancient Dragon
0
161
Member Avatar for shibu2all

> C K F H D B G Hey, do you have an image of what the tree actually looks like? Thanks :)

Member Avatar for iamthwee
0
118
Member Avatar for da(code)da

Hey, I'm guessing 1 = active, 2 = not active.. <?php mysql_select_db("my_db", $con); $result = mysql_query("SELECT * FROM gameChart WHERE secID=='1'"); echo "<dl><dt>Writer's Forge</dt>"; if(mysql_affected_rows() == 1) { echo "<dd>Collaborated Poetry</dd>"; }else{ echo "<dd><a href='showcase'>Collaborated Sreenplays</a></dd>"; } ?> Could try this.. I mean, I'm not too sure why you need …

Member Avatar for coreyavis
0
272
Member Avatar for Alochai
Member Avatar for Alochai
0
648
Member Avatar for turpentyne

Just a suggestion.. The $var will be stored in temp memory, and, when you re-load the page, the $var value will therefore be cleared. Why not store it as a session?

Member Avatar for turpentyne
0
133
Member Avatar for hcoyle545

Hey there, nice attempt. When using classes, you should remember that your class definition should be in a (.h) file, and then class methods/functions should be in it's own seperate (.cpp) file. Let me show you an example: Sample.h: class Sample { public: Sample(); int term(int a, int b, int …

Member Avatar for phorce
0
277
Member Avatar for pocix

Well, have you got a login script that handles if the user has entered the correct details? If this is the case, you can use sessions to determine whether or not the user is signed in, or not.. And then which link/data you want the user to see

Member Avatar for pocix
0
344
Member Avatar for Djmann1013

Try this: <?php //init.inc.php file session_start(); mysql_connect('mysql.host.com', 'username', 'password') or die(mysql_error()); mysql_select_db('DB name'); include('include'); // whatever your including, meh! // Get users from table function fetch_users() { $query = "SELECT user_id AS id, user_name AS username FROM profile"; $result = mysql_fetch_array($query); $users = array(); while ($row = mysql_fetch_assoc($result) !== false) …

Member Avatar for phorce
0
89
Member Avatar for hannah shrn j

What? I'm confused, do you expect someone to check what domain names are free or not? :S That's a pretty extreme thing to ask for ha! http://www.fasthosts.co.uk/domain-names/ try this or who 'whois {domain_name}' in terminal/cmd

Member Avatar for phorce
-1
136
Member Avatar for gilgil2

> mysql_query("DELETE FROM gigs WHERE gigname='".$name."'"); Try: mysql_query("DELETE FROM gigs WHERE gigname='$name'"); Other than that, output $name

Member Avatar for phorce
0
498
Member Avatar for heur1konrc

<?php // connection details // connection details $sql = "SELECT * FROM {table}"; $result = mysql_query($sql) or die(mysql_error()); if(mysql_affected_rows() >= 1) { while($row = mysql_fetch_array($result)) { $image_url = $row['url']; } echo "http://localhost/htdocs/image_folder" . $image_url . ".jpg"; } ?> Have not tested it, should give you a rough idea :)!

Member Avatar for phorce
0
155
Member Avatar for phorce

Hello, I'm trying to develop an algorithm/program that calculates the distance between two points. These values are stored inside a 1D array, which, acts as a 2D array (I think you know what I mean!) The values are: 150 50 15 20 The calculation should therefore be: d = √(150 …

Member Avatar for phorce
0
209
Member Avatar for Djmann1013

Hey first off, for your own purpose, please don't post your MYSQL Account information on a public forum that anyone can see ;) Second, can you please just var_dump the $url variable where you're trying to re-direct.. So for example: > db_field <?php $host="mysql6.000webhost.com"; // Host name $username="removed"; // Mysql …

Member Avatar for Djmann1013
0
196
Member Avatar for dhruv_arora

Hey, you could try this: Hey, you could try this: <?php include 'connect/connect.php'; if(isset($_POST['sub'])) { $bcode = $_SESSION['barcode_v']; $iname = $_POST['u_name_f'].' '.$_POST['u_name_l']; $name = stripcslashes(strip_tags($iname)); $email = $_POST['email']; $dob = stripcslashes(strip_tags($_POST['y']."-".$_POST['m']."-".$_POST['d'])); $insti = stripcslashes(strip_tags($_POST['insti'])); $phone = $_POST['phone']; $course = $_POST['course']; $school = $_POST['school']; $address = $_POST['address']; $sql2 = "SELECT * …

Member Avatar for phorce
0
108
Member Avatar for newbie1234

In order to achieved this, you, would have to use url re-write (like @Nichito pointed out) You would still have your username.php which accepts the paramater (hh). <?php $user = $_GET['username']; // Obviously with a bit more security var_dump($user); ?> Hope this helps

Member Avatar for IIM
0
159
Member Avatar for 111100/11000
Member Avatar for Khav

It would be this, surely?: <?php $url = "something"; // In my php files $url contain multiple values ?> <html> <td><input type="text" size="50" value="<?php echo $url; ?>"/></td> </html> Ohhhhhhhh!! You're talking about arrays! Apologies! So you'd have a list of values: <?php $urls = array('www.google.com', 'www.yahoo.com', 'wwww.website.com'); foreach($urls as $url) …

Member Avatar for jasonsarino
-1
43K
Member Avatar for da(code)da
Member Avatar for magicmarkuk

Hey, Look at this: <?php $budget_min = 10; $budget_max = 10; if(!isset($budget_min) && strlen($budget_min) < 20) { // display the errror } // Check if the value entered is numeric if(!is_numeric($budget_min)) { // display the error } if($budget_min >= $budget_max) { } ?> Hope this helps :)

Member Avatar for phorce
0
170
Member Avatar for rithish

Try this: #include <iostream.h> int main() { int d; int i=0,n,j,b[100]; cout<<"\n Press 1 for Decimal to Binary converstion"; cout<<"\n press 2 for Decimal to Octal converstion "; cout<<"\n press 3 for Decimal to Hexadecimal converstion"; cout<<"\n\nEnter your choice: "; cin>>d; switch(d) { case 1: cout<<"\nEnter decimal number: "; cin>>n; …

Member Avatar for phorce
-2
440
Member Avatar for diknas

Hey, I'll give you an example.. Then you can just relevant insert the code where you need it. int choice = 0; cout << "Please enter an option: \n"; cout << "\t\t 1) Sum Row\n"; cout << "\t\t 2) Sum Column\n"; cout << "\t\t 3) Diagonal Sum\n"; cout << "\t\t …

Member Avatar for phorce
0
274
Member Avatar for jfunchio

Hey, As far as I'm aware, extract data from a .pdf form is impossible in PHP.. Please see: http://stackoverflow.com/questions/7419236/how-to-extract-field-value-from-pdf-form-in-php Which may offer some more help, there might be a platform that can do this.. I've never come across this though!

Member Avatar for almostbob
0
181
Member Avatar for da(code)da

mhmh, just a suggestion.. But I don't code like you: <?php $callsign = mysql_real_escape_string($_POST['CallSign']); $query = "SELECT * FROM users WHERE Callsign='$callsign'"; $result = mysql_query($query); if(mysql_affected_rows() == 1) { $row = mysql_fetch_row($result); echo $row[0] . "<br>"; }else{ echo "That CallSign has been claimed Already!<br>"; echo "<p><a href='register.php'>Return to Try Again</a><br>"; …

Member Avatar for phorce
0
268
Member Avatar for HasNor

From what you've said - It should be possible.. I believe, not to sure what it is your trying to do though! Anything is possible, if you put your mind to it ;)

Member Avatar for willson1
0
123
Member Avatar for CarterLangley

> e same Do you want someone to do the code for you? You could atleast attempt it. I don't get what question you're actually asking.

Member Avatar for phorce
0
111
Member Avatar for dlmagers

Like everyone else has said, you should atleast attempt it before posting on here! Maybe this might help.. #include <iostream> #include <vector> #include <numeric> using namespace std; double subTotal(vector<double> &values) { return accumulate(values.begin(),values.end(),0); } int main(int argc, char *argv[]) { vector<double> numbers; numbers.push_back(10); numbers.push_back(20); numbers.push_back(9); numbers.push_back(8); cout << subTotal(numbers) << …

Member Avatar for phorce
0
758
Member Avatar for DanErik

> e text in the source code as "plain text" so it's language can be changed (english/swedish/ ....) > > An example might explain better Hey, basically, a language convertor? You can use Google's Translate API for this. https://developers.google.com/translate/ Hope this helps

Member Avatar for pritaeas
0
177
Member Avatar for phorce

Hello, I'm building an application in PHP and when outputting HTML tags, it shows the tags.. So for example: <?php echo "<b>Hello world</b>"; ?> I would expect Hello world to be in bold.. But no, I get: <b>Hello world</b> as the output Any ideas please?

Member Avatar for phorce
0
69
Member Avatar for phorce

Hello, I'm having a weird problem with some PHP when outputting some HTML. For example: echo "<h1>There are errors!</h1>"; foreach($errors AS $error) { echo $error . '\n'; } exit(); I want the output to actually show the text in H1 style, however the output is like this: <h1>There are errors!</h1> …

Member Avatar for broj1
0
94
Member Avatar for David2012

No, it should recognise "Class 1", "Class 2".. <?php $study = $_POST['study_class']; var_dump($study); ?> Then depending on whichever value is entered, should assign this. I haven't tested it though, might be wrong!

Member Avatar for David2012
0
199
Member Avatar for David2012

Confused.. By using var_dump, it just dumps whatever is stored in a particular varialbe and then outputs it to the screen (or whatever)! In order to display the output, you should just use echo/printf? <form action="abc.php" method="post"> <select name="study_class[]" multiple> <option value="Class 1">CLASS 1</option> <option value="Class 2">CLASS 2</option> <option value="Class …

Member Avatar for David2012
0
268
Member Avatar for Djmann1013

Hello, Have you tried to use jQuery? It has an amazing library for key events. I haven't come across such a thing in PHP before.

Member Avatar for Djmann1013
0
228
Member Avatar for laura301019

Hello, It would be a good idea if you atleast tried this yourself, even the smallest attempt would be beneficial since we're not here to do homework. I don't clearly understand what you want, but, have a look at this: <?php // Accept the users age $age = $_POST['age']; $half_age …

Member Avatar for Biiim
0
155
Member Avatar for rjony321

No. You cannot. You can however, "design" the drop down menu in HTML and then process it using PHP.

Member Avatar for mlm2gether
0
354
Member Avatar for laura301019

Hello, First of all, I wouldn't put the function there. Make sure that the function is above all of the main code, so like this: <?php function echoArray($theArray) { $size=count($theArray); for ($i=0; $i<=$size; $i++) echo "month number " . $i . " is :" .$theArray[$i] . "<br />"; } // …

Member Avatar for phorce
0
259
Member Avatar for labise

Try this: <?php // Set up the database connection $dsn = 'mysql:host=localhost;dbname=lafamosa_plaincart'; $username = 'lafamosa_kermis'; $password = 'lafamosa1980'; $options = array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION); try { $db = new PDO($dsn, $username, $password, $options); } catch (PDOException $e) { $error_message = $e->getMessage(); include('errors/db_error_connect.php'); exit(); } ?>

Member Avatar for phorce
0
142
Member Avatar for shlokka

Maybe show some code where it's going wrong - People might be able to help you :)

Member Avatar for shlokka
0
379
Member Avatar for kn3rdmeister

> here, I don't know how to get PHP to build a list using the data. I could do it manually every time a new month comes up, but that defeats the purpose in my book. Hello, Basically (From what I understand) you should have a table/column that populates a …

Member Avatar for pritaeas
0
674
Member Avatar for marreameathue

Hello, First of all.. int main(); Shouldn't have a semicolon, therefore it should just be: int main() { return 0; } You've also declared a function, but, it doesnn't mean it's wrong, you can set the prototype (Especially if your using the function in main, but it's actual functiuanlity is …

Member Avatar for phorce
0
374
Member Avatar for LastMitch

> <?php > $product_name = "pencils"; > $product_price= 7.99; > printf( "Product %f will cost %1.1f dollars.", > $product_name, $product_price ); > ?> Can't you just echo it? <?php $product_name = (string) "pencils"; $product_price= 7.99; echo "Product $product_name will cost $product_price"; ?>

Member Avatar for phorce
0
155
Member Avatar for juljan30

> 2, 67, 23, 5, 7, 34, 14, 4, 8, 62}; Hey, Think something like this is what you mean.. Obviously, change it slightly! #include <iostream> using namespace std; int main(int argc, char *argv[]) { int numArray[10] = {2, 67, 23, 5, 7, 34, 14, 4, 8, 62}; int arrayNum[10]; …

Member Avatar for phorce
0
138
Member Avatar for khezel nicole
Re: c++

I had to do this as a first year project.. Can you atleast show that you have attempted it, so then people can help?

Member Avatar for phorce
0
45

The End.