Jump to content

ginerjm

Members
  • Posts

    6,906
  • Joined

  • Last visited

  • Days Won

    99

Everything posted by ginerjm

  1. You're not really showing us any code. Just some calls to unique functions that we aren't aware of. Show us an actual query statement that uses a where clause that would do this limit thing that you need.
  2. They are entirely unnecessary. PS - it is generally not recommended to use the "select *" query format. Always select the fields that you truly want to obtain from the query and not just do the catchall "*" operand. This way you (and those behind you) know what field names you have acquired from the query and in what order they are in should you choose to use numeric indices.
  3. What's with this line and the parens??? $query_sect = ("SELECT * FROM a_sectionals_bkb");
  4. I'm guessing that the 500 is a sign that you had a php error in your improvements. Have to debug that.
  5. One problem you have is the failure to quote your indices and string values. In the above line, the words box, image, lightbox, border and $row[image'] need quotes aroun them. echo "<td><div class='box'><a href='$row[\"image\"]' rel='lightbox' title='$row[\"image\"]'><img class='border' src='$row[\"image\"]'>"; Now you have to explain what "breaks" means to you. Do you have error checking turned on at least? Do you get any messages? A white screen? Anything?
  6. So you are asking "Can PHP read a PDF file"? Did you google that yet?
  7. I don't know what sources told you that combining two distinct activities into one form is the "best" way to do it. IMHO - register your people first. Get them to respond to an email in order to confirm everything is accurate. THEN let them begin the payment process/ordering steps, whatever. Doesn't make sense that someone tells you otherwise.
  8. You state that you don't want to lose anything or leave the form. How important is it that this email needs to be sent right now?? Have you done any data validation (of the form's data fields) prior to sending off the email? How do you know that what you are (perhaps) sending in that mail is valid/correct? You can easily return the user to the same screen and its form contents by simply saving the values in php vars that are then place into the html code of the form using simple php code. That way your php script can check the inputs, verify they are correct and then send the email OR return all of the data to the user to be corrected. Check the "value=" attribute of an html 'input' tag.
  9. I am curious as to what exactly "fixed" your issue. Hopefully you learned that you should wrap those "t" and "scr" indices with quotes and not left them stranded with no definition, causing php to have to work to understand what you are doing. True?
  10. Obviously the 't' is meant as an index into the array that is in $path. One should ALWAYS use quotes around an index value unless it is a php variable name. Since you are using something called just "t" you need to figure out what belongs there - most likely a dollar sign. Clearing that up and avoiding what php is defaulting your index to (from the error message it may be simply the value "t") an incorrect value. Do you know what $path actually contains? You can do a bit of debugging by simply displaying it.
  11. You have to be kidding. This post is meaningless to almost anyone who reads it. I understand that there is a language problem but you don't even attempt to make clear what you are using, what you are doing nor what any of your code even looks like. Questions: What is "getevent()"? What is "Mage"? Where is this printing taking place? What is "checkout_cart_product_add_after"? A function you wrote? Part of a package you are trying to learn about?
  12. I'm curious as to why you have this need to create individual spreadsheet (files) when you already have the data in a database from which you are able to draw this info from. Are you creating these files for others to use outside of this data-gathering app? And do they do updates within these spreadsheets that you then have to somehow apply to your nice-and-neat already-maintained database?
  13. AND in my first post - did you RTFM on those two functions that you are mis-using?
  14. Do you mean a string value saved in a var or do you mean a valid date value stored in a var? Bit of a difference. Care to elaborate?
  15. Do you have php error checking enabled? Did you read the manual on how to use the date() and strtotime() functions? I think you have bad values in use and that is probably causing your discrepancies.
  16. One thing is to verify that the input value has the content that you expect. Another is to use prepared queries that will remove any threats from using user inputs.
  17. Never sanitize input data? Why on earth would you NOT do that? Hackers can put anything into an input field and your script has to be prepared to handle it or face the consequences. The rule might be 'never alter input'. But for sure you have to sanitize it to avoid damage to your database or whatever your script is doing with the data.
  18. That too is news to me.
  19. Macgyver - great post. But - I don't get the purpose of #7. When I'm done I simply resend the screen back for another set of input or with the results of the logic process. Don't understand your need for a get request.
  20. How about this query? $wpdb->query( 'DELETE FROM '.$wpdb->prefix.'kudos_email WHERE kuemid IN($del_id)' ); Your query statement has a Where clause that looks like this EXACT string: 'WHERE kuemid IN($del_id)'. That is not what you want. Try using double quotes instead of single. ALSO - my research does not show any valid use of the IN operator with an array of args. You need to do an implode on your array to add the commas and use that resulting String value.
  21. Yes I did. Wasn't looking at a UL tag to contain that code.... Probably cause of the layout of this mish-mash of Html and php interspersed.
  22. Two questions: 1 - What do you mean by "read navigation"? 2 - Your php code has a lot of functions but no "main line" code that makes use of them. Perhaps that is why you are posting here?
  23. How to add the echo statements? If you don't know what that is, I'm afraid you are in over your head.
  24. Have you added any debugging code to see what the script is doing? Obviously it is going somewhere you don't expect so add some echos to display what the code is seeing and operating with.
×
×
  • 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.