Jump to content

coldfission

Members
  • Posts

    47
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

coldfission's Achievements

Member

Member (2/5)

0

Reputation

  1. pinging example.com from example.com gives my Internet IP. not my local IP or 127.0.0.1 is that a good thing?
  2. I have worked with two linux servers now that will not send email to itself. When we test programs, we like to send email to ourselves to get test content, but it always fails. for example: i send email with sendmail from server: example.com to email address: test@example.com. No email is ever received when i try Any help with this?
  3. I need to write a program that will take our inventory and find out the predicted date when we will reach quantity = 0 The only way i have decided to do this is to take our "Inventory Changes" (date and quantity at that time) and make a graph of it. Then, find the best fit line (quadratic would be nice but linear works) of that graph. Then, i can find when that best fit line reaches zero and find out what the date is at that point. That will be our predicted quantity = 0 date. Are there any tools already made for php that will find a best fit line? Is there another way to predict this without finding the best fit line?
  4. if ($key = array_search($sku,$inventory_sku)) { $inventory_q[$key] = $inventory_q[$key] + $quantity; } else { $inventory_q[$inv_count] = $quantity; $inventory_sku[$inv_count] = $sku; $inv_count++; } What if the $key = 0? That tells the IF statement that it is false and, in my case, will insert a new record when i don't want it to. How do i solve this problem? thanks
  5. it would be nice if i was to store each picture filename in a database somehow, but i don't really want to do that. I want the customer to be able to just upload the picture to the directory and it shows up in the gallery automatically.
  6. I am trying to automate a customer's photo gallery. directury structure: pictures/01 - gallery 1 pictures/02 - gallery 2 pictures/03 - gallery 3 I want to keep my code flexible so i can expand to more galleries in the future. The gallery page will be a paginated list of ALL pictures no matter folder/gallery they are in. I want each folder to be organized in descending order, but array_merge (?) them in ascending order. This gallery is just a listing of thumbnails that link to the full picture. Now that i have split up the pictures into multiple folders, i have to include which folder that picture is in in the array. I am having trouble with the array structures. Where do i put the folder variable in the array? What would my array structure look like? I'm not very good at working with arrays :'( thanks
  7. wow what a stupid error. i didn't even think of that. thanks
  8. I am sending through SMTP: localhost with no SMTP authentication Any email will send except when the recipient has an email with one of our hosted domains. We setup our MX records exactly as google apps told us to (because we use the google email app) http://www.google.com/support/a/bin/answer.py?hl=en&answer=33352
  9. The code below is supposed to send each recipient a different email body, but the same email body from the first item is being sent to everybody in the list. How do i get the body of the email to be reset for each email? $query = "SELECT orders_id, customers_name, customers_email_address FROM orders WHERE date_purchased LIKE '%$past_date%' AND orders_status=3"; $result = mysql_query($query) or die('Query failed: ' . mysql_error()); require_once "phpmailer/class.phpmailer.php"; $mail = new PHPMailer(); $mail->IsSMTP(); // telling the class to use SMTP $mail->IsHTML(true); $mail->Host = "localhost.localdomain"; // SMTP server $mail->From = "donotreply@tackwholesale.com"; $mail->FromName = "TackWholesale.com"; $mail->AddReplyTo("tackman@tackwholesale.com", "Tackwholesale.com"); $mail->Subject = "Review your Purchased Items and take our Survey"; while ($row = mysql_fetch_array($result)) { $orders_id = $row['orders_id']; $enc_orders_id = ($orders_id*897)-411; $customers_email_address = $row['customers_email_address']; $customers_name = $row['customers_name']; $customers_name = explode(" ",$customers_name); $customers_name = $customers_name[0]; $feedback_email = str_replace('past_date', $past_date, $feedback_email); $feedback_email = str_replace('customers_name', $customers_name, $feedback_email); $feedback_email = str_replace('enc_orders_id', $enc_orders_id, $feedback_email); $mail->Body = $feedback_email; $mail->AddAddress($customers_email_address); if(!$mail->Send()) { echo "error"; } $mail->ClearAddresses(); }
  10. I am not sure where our problem is, but i think Apache has something to do with it. We have multiple websites hosted through our Apache server on a GoDaddy Dedicated server. Every time i send an email (doesn't matter how i send it) to an email address that contains the domain that we host, it will not send. I believe it is trying to send an inbound message to itself and not sending externally. We have our email service at another location, so it needs to send externally just like any other email would. Ex: we host somewebsite.com I try to email me@somewebsite.com and it fails What do i have to change to get these emails working?
  11. This code will loop through the pages array and send them to the iframe. Once the page is loaded, it continues onto the next page source. This is similar to what i want, But I don't want the page to reload to the next one until the user reaches a certain point on that page source. This is because each individual page prompts the user to enter information. After the user enters their information, i want it to continue on to the next page source. How do i do this? <html> <head> <script type="text/javascript"> var pages = []; pages[0] = "http://www.blahblah.com/blah"; pages[1] = "http://www.blahblah.com/blahblah"; function updateFrame() { // get the frame var frame = document.getElementById("loopingFrame"); if(!pages[frame.pageIndex]) { // first iteration -- initialize the properties frame.pageIndex = 0; frame.count = 1; } else if(pages.length <= (parseInt(frame.pageIndex)+1)) { frame.pageIndex = 0; // we've gone through all the pages this time, increment count frame.count++; } else { // no need for a new number, just a new base page frame.pageIndex++; } var pageIndex = frame.pageIndex; var i = frame.count; frame.src = pages[pageIndex] + i; } </script> </head> <body> <iframe id="loopingFrame" src="http://www.blahblah.com/blah" onload="updateFrame();"> </iframe> </body> </html>
×
×
  • 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.