therealwesfoster
Members-
Posts
345 -
Joined
-
Last visited
Everything posted by therealwesfoster
-
Negatory, here's the new code: $headers = "MIME-Version: 1.0 \r\n"; $headers .= "Content-type: text/html; charset=iso-8859-1 \r\n"; $headers .= "From: email@amil.com \r\n"; $headers .= "Reply-To: email@amil.com \r\n"; $headers .= "Return-Path: email@amil.com \r\n"; mail("me@gmail.com,another@mydomain.com","Literature Request",$msg,$headers);
-
That's my problem! No, not really I'll add those headers and let you know Wes
-
This is weird and happens a lot. When I send an email from a php script mail("email@gmail.com","Literature Request",$msg); I receive the email in my GMAIL account, no problem. But when sending to any other email address (that ISN'T GMAIL), it doesn't get received. Not even in the spam folder. Whats up with that? Wes
-
[SOLVED] Download and Extract
therealwesfoster replied to therealwesfoster's topic in PHP Coding Help
Wow.. that easy. Thanks Wes -
I'm needing to create a PHP script that will download an external .bz2 file and extract it's contents onto a local directory. Could someone point me in the right direction and give me some tips? Wes
-
Options +FollowSymLinks Options All -Indexes RewriteEngine On RewriteRule ^artisan-(.*?).html ./acpage.php?p=$1 [NC,L] RewriteRule ^(.*?).html ./$1.php [NC,L] I keep getting 500 errors. Wes
-
How can I detect if the window (or tab of the window) is unfocused (or not being viewed by the user) ? Thanks!
-
What's the best way to mass email WITHOUT using any other email servers? I'm just wanting to use the default mail server (it has to be done this way). So should I do: mail('email1, email2, email3',.....); Or in a loop: foreach ($var as $key){ mail($key,...); } Or, if there is another way, let me know! Thanks
-
[SOLVED] Removing a selectbox option
therealwesfoster replied to therealwesfoster's topic in Javascript Help
FIXED IT! I put i--; in my for loop, this fixed it somehow. Final Code: // This is a simple function to check if a value is in an array Array.prototype.inArray=function(value){var i;for(i=0;i<this.length;i++){if (this[i] == value){return true;}}return false;}; // This is the selectbox object var obj = document.getElementById("selbox"); // Keep: CA, DC, CO, FL, GA, IA, MO, MN, NC, NV, NH, NM, OH, OR, SC, VA, WL var keepStates = ['New Mexico','North Carolina','Ohio','Oregon','South Carolina','Virginia']; for(var i=0;i<obj.length;i++){ if (!keepStates.inArray(obj[i].innerHTML)){ // Ok, so the value of the selectbox isn't in the array of states we want to keep, so remove it obj.remove(i); // THE FIX i--; } } -
[SOLVED] Removing a selectbox option
therealwesfoster replied to therealwesfoster's topic in Javascript Help
That's a jQuery function I'm needing just javascript Wes -
[SOLVED] Removing a selectbox option
therealwesfoster replied to therealwesfoster's topic in Javascript Help
That removes the whole object, not just the option Wes -
[SOLVED] Removing a selectbox option
therealwesfoster replied to therealwesfoster's topic in Javascript Help
I'm doing this as a 1ShoppingCart modification. On the cart page there is a dropdown list of states, but since the product being sold (wine) is limited to where it can be shipped, we're wanting to eliminate some of the state in the dropdown. The script above works in a way. It leaves all the states that it's supposed to leave, but not all of the other states get removed. Just every other one, or every other 2 ones. Does remove() reset the dropdown's index? If so, this could be the problem (because var i is always incrementing) Wes -
[SOLVED] Removing a selectbox option
therealwesfoster replied to therealwesfoster's topic in Javascript Help
If it were only that easy!! That doesn't work for me.. Any other ideas as to why? Or ideas as to what to do? Wes -
Ok, here's the idea. There is a selectbox on the page with all 50 states listed. I'm wanting to remove all the states in the selectbox EXCEPT for the ones I have listed in the keepStates array. Below is my code. I can't get this to work! Either nothing happens or I get a "obj.remove() is not a function" error. <script type="text/javascript"> // This is a simple function to check if a value is in an array Array.prototype.inArray=function(value){var i;for(i=0;i<this.length;i++){if (this[i] == value){return true;}}return false;}; // This is the selectbox object var obj = document.getElementById("selbox"); // Keep: CA, DC, CO, FL, GA, IA, MO, MN, NC, NV, NH, NM, OH, OR, SC, VA, WL var keepStates = new Array('New Mexico','North Carolina','Ohio','Oregon','South Carolina','Virginia'); for(var i=0;i<obj.length;i++){ if (!keepStates.inArray(obj[i].innerHTML)){ // Ok, so the value of the selectbox isn't in the array of states we want to keep, so remove it obj.remove(i); } } </script> This does not work. Please help! Wes
-
I'm having trouble getting the 4 timestamps. I had to do this for the previous month's beginning/ending timestamp and I did it like this: $prev_month1 = strtotime(date("1 F Y",strtotime('-1 month'))); $prev_month2 = strtotime(date("t F Y",strtotime('-1 month'))); This snippet gets the beginning and ending timestamp for the previous month. I'm needing to do the same for the current week and current day.. but I'm stuck Wes
-
I'm needing to generate a total of 4 UNIX Timestamps. 1. The beginning timestamp of the current week (Sunday at 0:00:00) 2. The ending timestamp of the current week (Saturday at 23:59:59) 3. The beginning timestamp of the current day (today at 0:00:00) 4. The ending timestamp of the current day (today at 23:59:59) The current day/week of the script can be whenever, so the script should be able to function no matter what day/month/year it is Thanks! Wes
-
[SOLVED] Little JS widgets to collect data
therealwesfoster replied to therealwesfoster's topic in Javascript Help
Ahh, ok. I knew you could do that with php images, but I didn't know it could collect and report data. I'll look more into this Thanks. Solved for now Wes