Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: lynque
  • Order by date
  1. lynque

    Target specific session array and value in WHERE clause

    And the output of the $session object Session Object ( [fName] => [lName] => [street] => [apt] => [city] => [stProv] => [country] => [pc] => [phone] => [username] => me [userid] => 993cbe7b590e2b60950c3c48ce389502 [userlevel] => 9...
  2. lynque

    Target specific session array and value in WHERE clause

    Here is my entire query: function displayVendorInfo(){ global $database; $q = "SELECT coName,coStreet,coUnit,coCity,coStProv,coType,pack FROM vendors WHERE coCity = '".mysql_real_escape_string($session->userinfo['city'])."' AND coStProv =...
  3. lynque

    Target specific session array and value in WHERE clause

    my apologies jpadie, I certainly don't mean to waste anyone's time and am very appreciative of all of your help thus far with regard to this problem I'm having. I'm starting to track all of the $session data from point of login to see if I can find where the problem is. I will post back my...
  4. lynque

    Target specific session array and value in WHERE clause

    Notice: Undefined variable: session in Notice: Trying to get property of non-object in Notice: Undefined variable: session in on line 55 Notice: Trying to get property of non-object in error with query. error was Query was:SELECT coName,coStreet,coUnit,coCity,coStProv,coType,pack FROM...
  5. lynque

    Target specific session array and value in WHERE clause

    Thanks jpadie, here is the result of the query output: Query was:SELECT coName,coStreet,coUnit,coCity,coStProv,coType,pack FROM vendors WHERE coCity = '' AND coStProv = ''
  6. lynque

    Target specific session array and value in WHERE clause

    Thanks jpadie, I used the code you provided and it printed all of the $session properties :), I tried using this in my query but it still fails: WHERE coCity = '".mysql_real_escape_string($session->userinfo['city'])."' AND coStProv = '".mysql_real_escape_string($session->userinfo['stProv'])."'";
  7. lynque

    Target specific session array and value in WHERE clause

    jpadie Array ( [username] => Lynque [url] => /login/promotions.php [userid] => 54e1c027d16a5c673ebdb8c6d60f9f93 ) is the result, though I am also echoing this: echo "<b>City:</b> ".$session->userinfo['city']."<br>"; echo "<b>State / Province:</b>...
  8. lynque

    Target specific session array and value in WHERE clause

    Thanks for both suggestions but neither work Vucinita: Notice: Undefined index: userinfo Don: Notice: Undefined index: userinfo Notice: Trying to get property of non-object in Any further help with this would be great.
  9. lynque

    Target specific session array and value in WHERE clause

    I'm trying this but I think the syntax is wrong... WHERE coCity = '".mysql_real_escape_string($_SESSION['userinfo->city'])."' AND coStProv = '".mysql_real_escape_string($_SESSION['userinfo->stProv'])."'"; Any help is appreciated
  10. lynque

    SELECT * FROM _TBL WHERE username = '$username'

    Thanks again, Googling now.
  11. lynque

    SELECT * FROM _TBL WHERE username = '$username'

    Thanks feherke, I've heard a lot about SQL injection attacks but haven't found a definitive guide for protecting my DB, do you know of a link that would serve as a good guide?
  12. lynque

    installed php on windows but php code not interpreted?

    Also, whenever you make a configuration change in IIS you need to re-start the service for the changes you've made to be implemented.
  13. lynque

    SELECT * FROM _TBL WHERE username = '$username'

    I have a query that executes when I hardcode the username but not when I try to use the session var. Works: $q = "SELECT * FROM ".TBL." WHERE username = 'Me'"; Doesn't work: $q = "SELECT * FROM ".TBL." WHERE username = '$username'"; I have used: <?php print_r($_SESSION); ?> to print out...
  14. lynque

    mail redirect if subject !=

    Let me post the entire block of code so you can see what I'm trying to do $email = $_POST["eMail"]; $subject = $_POST["subject"]; */ if($subject == "Accepted - MDG"){ $email = $_POST["eMail"]; mail($email,$subject); $redirect="thank-you.html" header("Location: $redirect"); }else...
  15. lynque

    mail redirect if subject !=

    So the solution is $email = "name@mydomain.com"; if($subject == "accepted"){ $email = "thankyou.htm"; header("Location: $redirect"); }else if($subject == "declined"){ $email = "name@mydomain.com"; $redirect = "declined.htm"; header("Location: $redirect"); } Thanks again
  16. lynque

    mail redirect if subject !=

    thanks to both of you for your help, I should have clarified the desired functionality as pointed out by a6. step1 - user fills out form and submits step2 - mailer finds out if $subject == accepted or declined step3 - if accepted email sent and redirect to thank you page, if declined email sent...
  17. lynque

    mail redirect if subject !=

    Thanks a6, can you put that in it's proper context within the code please? I'm pretty green with php mailer :s
  18. lynque

    mail redirect if subject !=

    Hello all, I have a php mailer that I would like to have redirect if the subject is != "accepted", I've never used a redirect on a mailer so it's new to me. So somethng like the code below $email = "name@mydomain.com"; if($subject = "accepted";){ $email = "name@mydomain.com"; $subject...
  19. lynque

    Open .pdf onClick of html submit button

    Thanks Phil
  20. lynque

    Open .pdf onClick of html submit button

    Hello all, I have a form that submits to a php mail and works just fine. I'd like to add to the submit button an "onclick" that loads up a .pdf document as well as submit the form. Any tips on this would be really helpful

Part and Inventory Search

Back
Top