Jump to content

ginerjm

Members
  • Posts

    6,906
  • Joined

  • Last visited

  • Days Won

    99

Posts posted by ginerjm

  1. And is it WHAT YOU EXPECT TO SEE? Might be nice to let us know what you are getting if you want us to continue to help you.

     

    Show us your current code and what you are getting for output please. Please read this last twice so that you can be sure to give me the help I am asking for.

  2. How do you see that loop doing what you want? It goes thru the array and posts the data into ONE set of vars. One. So at the end you will get whatever was last posted.

     

    Besides - you can't do this with prepared queries. Each substituted item in a prepared query has to be defined separately I believe.

  3. Along with mac_gyver's great post let me re-enforce something he alluded to: NEVER STORE A PASSWORD IN ANY WAY, SHAPE OR FORM. You use a password to interrogate your authentication table and once used you discard it. Create a token or simply use the username (key) to keep track of the user's status. One doesn't need the password. If you need anything else from the login process store some token or the actual 'something' but NEVER SAVE THE PASSWORD! Storing a password value only leaves you open to some malicious activity where you inadvertently leave yourself vulnerable or where some other vulnerability in the system allows a hacker to see what you have saved.

  4. So now you can see how the reference to the multiple files fields should be done, thanks to cyberRobot's post. It still doesn't change the fact that once you get these images you shouldn't be storing them in a table, but rather in a folder for direct reference when needed. Design your own storage scheme and stick to it.

  5. Are you getting any error from your query? Do you have php error checking turned on?

     

    I've not done it so I have to ask - are you sure that you can upload multiple images using the array format for the name attribute in your html? If you can you need to add another index to that name, [0],[1],[2] I think.

     

    And finally - storing of images in a db is not the recommended way. An image is a large object that can stand on its own as long as you know the name (which you do) and the location (which you do). One simply grabs it for display purposes using the info in the db that points to it. No need for the overhead of storing and retrieving it from the db.

  6. The only php logic/code you are showing us is the part that checks for the existence of the 'txtName' field in your html input. Sure you are using a php echo command to store all the html code but I don't see a script that uses that variable (to output it to the client) nor do I see any code that even attempts to receive the input from your form and try to validate it.

     

    How about making a stab at receiving the POST data and doing some reading and attempt to write proper handling code? Then ask for help making it correct.

  7. No. You got a better result. This time you show a string that apparently contains 17 printable chars, as the var_dump told you. As Barand pointed out, your previous test showed only 10 printable (visible) chars, yet var_dump said there were 17 actual chars in the content.

     

    So - why are you getting non-printable chars in your input?

  8. I would think that if someone logs in while selecting the remember box checkbox, that is when you save the cookie. You always save any specific login info that your appl will need later on that session, but you won't always save a cookie (probably holding the userid only).

     

    If the user logs in without checking the remember me box, then you simply don't save a cookie.

     

    I imagine the cookie would have some application-specific name to it.

  9. If you couldn't use the manual to figure out this problem, how the heck are you writing all your other php code?

     

    $str = '';
    foreach($array as $item)
    $str .= $item .', ';
    $str = trim($str,',');
    echo $str;
    

     

    OR the simpler approach:

     

    $str = implode(',',$array);
    echo $str;
    

     

    I think you should spend some time reading the manual and getting familiar with the language you have chosen to use. :)

  10. 1 - you are missing a closing form tag here.

    2 - you want to post each single ticket with a separate booking number. That means a customer with 3 tickets has 3 booking numbers? Really? How will you tie the tickets to the purchaser?

  11. Really? I'm going to click on your link and open a potentially harmful zip file?

    Plus - since you zipped it up it probably is a large file of a large script which you then expect people to read thru and understand.

     

    How about isolating the part of the code that is giving you the problem and then asking for help with that and then posting the code right here in the forum, using the proper code tags?

×
×
  • 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.