Jump to content

vanyok

Members
  • Posts

    30
  • Joined

  • Last visited

Posts posted by vanyok

  1. Hey guys :) Sorta new to PHP here but getting better day after day. I have a question that I cant seem to figure out.Lets say I have a login form that asks user for the ID and Password.How do I pass the user name as $_GET so it displays in the address bar but pass the password as $_POST so no one can see what the password is ?Is there another way to go about it ? Possibly encrypt that password in the address bar? ( but I'd need to run SSL for that, right ? )Thank you :)

  2. This should be simple .. I hope :)Trying to get current system to store it in the DB ( MySQL format). I'm using$date=date("Y-m-d");For some reason $date returns me 0000-00-00 :) Whyyyyyyyyyy ? Thank you.

  3. hey, good morning.I have a simple script that uploads the file but I cannot get it to work.. says that " No such file or directory" even though the folder is there and i have CHMOD set to full rights.This is the form:<form enctype="multipart/form-data" method="post" action="ProfileResults.php"><input type="hidden" name="MAX_FILE_SIZE" value="3000"><input type="file" name="picture" size="30"><input type="submit" name="imageSubmit" value="Upload"></form>and here is the upload php file: if ($picture != "") { $path="/pictures/$picture.jpg"; copy($picture, $path) or die("Couldn't Upload the file!"); } else die("Please go back and select a picture to upload");What's wrong ?

  4. You can disable right click so no one will be able to righ click and save...But then again, some computer savy people will find a way to get to the link through the page source.

  5. I'd do what justsomeguy posted. I find it the best way. I usually assign it to the variable. Here:$num=mysql_num_rows($result);if ($num>0){echo "My query returned $num rows";}else{echo "Your query didnt return any results";}

  6. Yup.. thats because I added error_reporting(E_ALL); just right now to see if that will help me figure out what's going on.That warrning means that I'm including another php file that has session_start() function as well but it shouldn't cause a problem, should it ?

  7. Hi guys :) I'm confused.. very confused and hope that someone will know what's going on. I have a very simple school homework project that's coming up as a blank page. I dont understand why. Here is the script of index.php:<?php session_start();if (!$_SESSION['userEmail'] && !$_SESSION['userPassword']){include 'hdr.php';include 'content/'.$page.'.php';}else{include 'ProfileResults.php';exit;}include 'ftr.php'; ?>it's located at:http://www.shopperstart.com/vanyok/phphomework/group/I tried on 4 different computer and the web site coming up as a blank page in Interenet Explorer but works fine in Firefox. The problem started after I added sessions so I assume that's the problem. Please help.Thank you in advance.

  8. Hey guys, I'm in the process of making my web site and wanted to know...Once I integrate some open source PhP Forum is it possible to make Forums Database a primary web site member Database ? So I could have users log into their accounts, track possible orders etc...Just trying to avoid extra work of creating registration pages, DBs...Also.. would you possiby recommend some good SQL/PHP open source recourses for this ? ( creating member login/pages )

  9. Anyone can suggest a good web site where I can download various free CSS style sheets templates ?Thank you.oops, sorry, just noticed there is a separeate Forum for CSS

  10. Thats teh problem.. After clicking on "No, I dont want to play anymore" it displays " Thanks for playing" but all game fields are still present on the screen. I would like to make it that everything dissapears. Is it not possible ?

  11. pls. help im makingm y own forum website. :) how can i post all the data(from my database) in my page.
    I would suggest you download one of the open source PHP forums:http://www.phpbb.com/ - one of the manyFrom there you can modify the existing script or build your own based on the example.Hope it helps.
  12. BTW, you may want to do something about the source code. Simply by looking at it quickly i noticed that the second input (the hidden one, named guess) has the value of the number you're supposed to guess. I'm no expert on making script hidden, but theres probably a way of containing the value in PHP, and as PHP doesnt show up when you click view source, you wont be able to see what it is
    Yep, I'm aware of that :) Thats a school project and basically thats one of the things. We're learning how to use hidden forms to pass some values. Everything works great except that prompt at the end.
    not sure, cos i dont have the entire code, but it could be if ($no=="no")instead ofif ($no=="No")
    nah, that didnt help.You can see I've used GET method so the address bar says ..php?no=No when pressed but it isn't displaying "THanks for playing"Would you want me to post full program code ?
  13. Hey guys :) I'm learning PhP and kind stuck with this simple thing ( think it's simple.)Doing a school project. Just a simple "Guessing number" game. Take a look:http://www.shopperstart.com/vanyok/phphome...umber/guess.phpI cannot get "No" button to work at the end of the game prompt "Would you like to play again?"echo "\nWould you like to play again?";echo<<<HERE<form name="playagain" method="get" action="guess.php"><input type="submit" name="yes" value="Yes"><input type="submit" name="no" value="No"></form>HERE;if ($no=="No"){echo "<h3><center>Thanks for playing</center></h3>";}else{}Thats the code behind the button. Seems simply but it's not working, just takes me back to the beginning of the project... :)

×
×
  • Create New...