Jump to content

trq

Staff Alumni
  • Posts

    30,999
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by trq

  1. $form is a class and getFieldHTML() is one of it's methods. This is third party code, not part of php itself.
  2. This topic has been moved to MySQL Help. http://www.phpfreaks.com/forums/index.php?topic=317025.0
  3. This topic has been moved to PHP Installation & Configuration. http://www.phpfreaks.com/forums/index.php?topic=317008.0
  4. This topic has been moved to Miscellaneous. http://www.phpfreaks.com/forums/index.php?topic=317014.0
  5. I don't think you understood. You dont need to use php to send email in Linux.
  6. If you only have a small library (and you mustif there all in one directory) then manual loading is fine. Autoloading only becomes more efficient when your library is bigger and objects start to require more dependencies. The best thing about autoloading is you only ever include what you actually use, this is mOre difficult to do manually.
  7. It's one way of doing things I guess, I definitely wouldn't do it that way though. You should take a look at the MVC pattern. Implementing that your index.php file would simply be in charge of bootstrapping then handing over execution to the front controller or application object.
  8. No need for the big type thanks, we can read. You haven't executed your query using mysql_query.
  9. Indeed they can. You also need to include a timestamp and every time you update the table, check for entries older than say 10 minutes and remove them. Its safe to say these users have left or are at least inactive.
  10. Simple parse errors mean you need a better editor. If you can't see the incorrect syntax highlighting, again, you need a better editor. $sql=mysql_query("insert into users (regno,name,gender,date,month,year,emailid,cell,paddress,caddress,incometype,incomeamt,dad,fyes,dadocup,mom,myes,momocup,password) VALUES ('$_POST[regno]','$_POST[name]','$_POST[gender]','$_POST[date]','$_POST[month]','$_POST[year]','$_POST[emailid]','$_POST[cell]','$_POST[paddress]','$_POST[caddress]','$_POST[incometype]','$_POST[incomeamt]','$_POST[dad]','$_POST[fyes]','$_POST[dadocup]','$_POST[mom]','$_POST[myes]','$_POST[momocup]','$_POST[password]')"); PS: Don't use user inputted data directly in a query like that (your asking for trouble). See mysql_real_escape_string.
  11. What exactly are you talking about?
  12. You seriously need to learn some debugging and manual reading skills. Your posting lots of questions and learning nothing from the answers. On top of that you really should learn some communication skills. You have not provided anywhere near enough information for anyone to be able to assist you. You are seriously verging on trolling.
  13. You need to execute the query ($query) via mysql_query.
  14. Actually, don't bother. Here.... $result=sprintf("SELECT * FROM idb1 WHERE username = '%s' AND password ='%s'", mysql_real_escape_string($userNm), mysql_real_escape_string($passWd)); if(mysql_num_rows ($result) == 0) { $result is a string. You never actually execute the query.
  15. While this doesn't answer or have anything to do with your question, it must be fixed first. My previous reply might not have been clear enough. You cannot call header() after sending data to the browser. See all that html at the top of your page? That is output sent to the browser. You will need to rearrange your code accordingly.
  16. Firstly, you cannot call header after outputting anything to the browser. You will need to rearrange your code accordingly. Secondly, $_POST is an array, not a function. This.... header("Location: Decryption.php?usersubmit=".urlencode($_POST($usersubmit))); should be... header("Location: Decryption.php?usersubmit=".urlencode($_POST[$usersubmit])); I don't see $usersubmit defined anywhere either though.
  17. Most php frameworks have a request object (which it kinda sounds like your describing) that gets passed around through most of the process.
  18. Generally, simple values like this would either be stored in a config file or a database. Either way, you would access them via a Model implementation of some sort.
×
×
  • 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.