How To Tell To Send A Specific E-mail At A Specific Time
How to tell PHP to send a specific e-mail at a specific time (newsletter).
View Complete Forum Thread with Replies
Related Forum Messages:
Echo To A Specific Div On A Specific Page
Is it possible to echo something from a php file to a specific div in a different specific html file?If so, can you let me know how to specify where the data should displayed. $myName="john"; echo '$myName'//but i want to echo to a different page on a certain part of that page.
View Replies !
Specific Date And Time...
I've created a new site, and its going to be online in September. Until then, i would like to have online a simple countdown that will display the time left until that day, and when we reach that date the new web page would appear automatically.
View Replies !
Specific Time/date
I needed to setup some links and pages to expire after the end of 2005, and here is a snippet of the code I used. I was wondering, was this the best/most efficient way fo achieving this? PHP Code: //set the end date and time $end_date = "2006-1-01 00:00:00"; // adjust for server time difference $hourdiff = "3"; $timeadjust = ($hourdiff * 60 * 60); $date = date("Y-n-d H:i:s",time() + $timeadjust); // Test to see if the offer has expired, if yes, then redirect if ($date >= $end_date) { header("Location: http://www.xyz.com/offerended.php"); /* Redirect browser */ exit;/* Make sure that code below does not get executed when we redirect. */ } else { echo " "; } // The rest of my HTML code followed this.
View Replies !
Sending Email At A Specific Time
I was curious if someone knew how to send an email at a certain date. If i have a start date and in 3 days i want to send an email, how do i do it? For Example, Starting next monday (whatever the date is), 3 days after monday i want to send an email out, and also send another email out 3 days after that until i tell it to stop. What i'm attempting to do is sort of create an autoresponder for questions entered into the database. The user will enter their question and also enter a frequency of how long the server should wait until it sends an email to the recipient, if the question is not answered by next frequency date it will send out another email to the recipient. How can this be done properly?
View Replies !
Find When DST Comes Into Effect For A Specific Time Zone
I'm making a JavaScript clock which works in real time, and supports every time zone. I am struggling to find a way to see when the clocks are set back or forwards in a specific time zone. Is there any way I can find this out with PHP without having to use some kind of intensive loop, which will probably lag out my server?
View Replies !
Data To Display For Specific Time Period
I am attempting to put some information on my website. For a specified period of time, I would like to display data, such as photos, links, event dates, etc. My database table contains the data, link for example, a start and an ending date. I cannot figure out how to write the script to display the data for a certain amount of time and then automatically change the data at a specified date.
View Replies !
Countdown Clock That Counts Down To A Specific Time
how can I make a countdown clock that counts down to a specific time and isn't affected by the time that the user has their computer set to? I would like the countdown to look like: ___ days ___ hrs ___ min ___ sec until (event)!! I want it to countdown to March 18, 2005 at 5:30 AM U.S. Central Standard Time (GMT -6). No matter what the user has their computer's time set to, I always want the countdown to be for March 18 at 5:30 AM central time.
View Replies !
How To Block A Specific E-mail Address?
My website has a mail form run by PHP, and I'm getting a lot of e-mails sent through it that appear to contain my website's domain after the '@', though I didn't send them. The e-mails contain no other content, so I assume it's some kind of spam bot. There must be a line of PHP that I can add that will basically say, "if the e-mail address contains '@mydomainname.com', do not send." I tried looking at php.net, but I can only find scripts that check if the address is a valid one, which isn't good enough. I need to be able to block a certain e-mail domain.
View Replies !
Sending People To Specific Pages That Are Coming From Specific Pages...
I want to show some specific pages to people that comes to my site from specific urls, I know the variable $_SERVER['HTTP_REFERER'] will be used but how? For ex if the visitor comes from a site that is like: I want to send this person a specific.php . I used below code but not worked: <?php if($_SERVER['HTTP_REFERER'] == "www.cominghost.com" || $_SERVER['HTTP_REFERER'] == "cominghost.com" || $_SERVER['HTTP_REFERER'] == "www2.cominghost.com"){ // Specific page html goes here } else { header("Location: index.php"); } ?> This code not worked for some cases like if the visitor comes from http://www.cominghost.com/account/targeturl.php or http://cominghost.com/account/targeturl.php Ok I know the if statement not working but How?
View Replies !
How To Send Mail At A Later Time
I have a form on my site that I would like to generate an automated response from when it is submitted. The trick is that I want the auto response to send an hour or so after the form is submitted. If I'm using PHP to send mail is there something I can add to the header of an e-mail to tell it to send at a specific time?
View Replies !
Emulating Multithreading To Send Mail To Different Servers At The Same Time
I'm trying to find a solution in order to be able to use more than one SMTP server at once with my newsletter application (written in PHP of course). The scenario is that we have 3 SMTP servers that we're using to send emails from. All of the emails are personalized (with name, surname, etc..). There's a command line script that cycles through the newsletters that have to be sent, looks up the individual email addresses and other data and then starts sending them out. At the moment it's just cycling through the three servers and using the phpmailer class to send the mail. What happens is that with every send, the script has to wait for the communication with the SMTP server to be done. This means that the other 2 servers in the meanwhile are just sitting there and waiting. I would like to use all three at the same time and sort of check which one is free and use it. That way, if one of the servers is already overwhelmed and is answering slowly, I can be sure that I am still using the other 2 efficiently.
View Replies !
Specific IF/Then...
I have a code that displays a value from a row in a mysql db. The code is this: echo "<td>" . $row['year'] . "</td>"; When the user submits their information, there is an option that says "hide the year I was born." Since the row for "year" is set it INT, if they choose that option it returns "0." I was wondering if there was a way to do something like if $row['year'] = "0"{ echo"hidden by request" } else{ echo "<td>" . $row['year'] . "</td>"; } but still have it work with my existing code.
View Replies !
How To Add An SPECIFIC Array
sorry if the subject isint really good to understand, now i will try to explain my best. I recently installed a hack in phpbb and that particular hack allows only 1 variable, but i want to add more than one, and i thought the best thing to do it is in an ARRAY, but i dont know how to do it in an array, the code looks something like this:
View Replies !
Getting Specific Fields From A CSV
I've been using fgetcsv to populate an HTML table with CSV data and so far it has been working great. But now I'm looking to call specific data from the table (ie: row 3, column 5), and I'm not sure fgetcsv can be used for this. Every online example of its use involves getting all the CSV data from a file as my table has done. What function should I use to get specific fields from my CSV? My table doesn't use unique ids, at least not like mysql, with a unique number identifying each row in the leftmost column. What then should I use to identify each row from which I'd like to get data? I'm making a page that describes a person based on the query string and the information in the database, in which each person has a row. So example.com/example.php?christopher+walken would bring up a page where Walken's information is listed. So I guess the ideal way to do what I want is to query the CSV for the name in the query string (Christopher Walken), then get and print the other information in the row (tall, great guy, etc). Any suggestions on this query?
View Replies !
How To Redirect With Specific Value ..?
I want that when i recieve different values from "form page" i will mail myself all the details and redirect the user to another site for CR Card payment. What i need is redirect the user to another site along with the value of total amount of package .How can I do that. I have done the first part of mailing but dont know how to do the redirection in PHP ..
View Replies !
Selecting Specific Tag
I am making a script which displays an RSS feed on my website. To do this I would like to take all the <div class="blabla"><img src="bla.jpg" alt="bla"> </div> tags and put them in front of my text. So the following string: <p>This is text blah blah blah</p> <div class="blabla"><img src="bla.jpg" alt="bla"> </div> <p>this is another text</p> should give as output: <div class="blabla"><img src="bla.jpg" alt="bla"> </div> <p>This is text blah blah blah</p> <p>this is another text</p> I tried using regular expressions, but I do not really get it done. Here is the code I use: while(ereg('/<DIV class="blabla"*>(.*?)</DIV>/i',$content, $matches)){ $img=$img.$matches[0]; $content=ereg_replace('/<DIV class="imgbar50"*>(.*?)</DIV>/i',"",$content,1); } what do i do wrong?
View Replies !
PHP Editor, Vim Specific.
Does anyone have a really good php indent file for vim? I'm working on my first really sizeable project and I'd like it to be kept as clean as possible while I'm working.
View Replies !
Specific Record From DB
I have a form which updates customer information and as default this gets started on record 1. I would like to be able to post a clientname from a previous form and then get the specific data for that customer. I am fine with the posting to seperate pages stuff but how could I get the update form to start on this record? Code:
View Replies !
Specific Pagination !
I've got some regular joe schmoe queries running ... now the totally result of these queries goes well over 2,000 records. Im looking to paginate these in a certain fashion : << Prev 1 2 3 4 5 6 7 8 9 10 Next >> Each # obviously will display the page ! but Prev and Next will jump to either previous 10 or next 10... so if im on page 4 and i hit next ! i dont want to go to page 5 but rather page 11 and display: << Prev 11 12 13 14 15 16 17 18 19 20 Next >> I hope this is doable ! if not please give me a better suggestion, a more effective and/or efficient way to be able to browse through all these records.
View Replies !
Specific Lines
I have the text file 'text.txt' and the contents of it are: CodingForums.com is not cool and i want to change only the 2nd line so the contents of text file is: CodingForums.com is very cool how would I do that? also how would I read just the 1st line?the contents text file would be: CodingForums.com is very cool
View Replies !
Specific Characters
i want to match some specific character set 10 odd characters in a user input string. i want to find all occurences of the any of such characters. i am using preg_match_all for this.the string pattern that i am giving is a regular expression having those characters i.e "ch1|ch2|ch3" but i am getting only first occurence of the the char which is there in the regular expression. where i am goin wrong and how can capture all occurences of those chars. e.g pattern- "x|y|z" string to search "this is the X string for test Z and Y are at end and are not detected" in above case the character that is matched is only X at 13th position and z and y are not matched. i want to detect presence of all 3 chars. i.e x,y as well as z. how can i achieve this.
View Replies !
Specific Include
I have read a lot of posts about the include statement and understand the majority but there is one small thing missing for me. Maybe you could help enlighten me. I read that I can include htm files or php files. Therefore I have two senarios. 1. If I include using a htm within a htm page, how much do I need to write in that htm file that will be included. Code:
View Replies !
Go To Specific Page
I have a search box, then I put in search criteria, got a returned result. When I click on to view that result, I got a page that says "you have to login first". After I login, I want my page to go to that "result page" instead of the member page. Is there a way to do that?
View Replies !
Getting Specific User
I have my login script, and I have it setup so that if they are not logged in it shows the login box, and if they are, it shows a welcome message. But how I can I get the specific username of the person who logged in, from the database? Here is my code: <?php if (!isset($_SESSION['authenticated'])) { echo "<form id="form1" name="form1" method="post" action=""> <label for="username">Username:</label> <input type="text" name="username" id="username" /> <label for="textfield">Password</label> <input type="password" name="pwd" id="pwd" /> <input name="login" type="image" src="images/login_button.jpg" id="login" value="Log in" /> </form>"; exit; } echo "Hey, welcome back $username!"; ?>
View Replies !
Get Specific Query
theres a set of links that derive from a database when a link is clicked you are fowarded to a page called list.php in this page i want to get certain information out of the database based on what link is clicked so this is how it works PHP Code:
View Replies !
Delete A Specific Row
How can i delete a specific row from a mySQL table. I want to delete Image2 (or make the value of it is nothing, NULL) <?php $con = mysql_connect("localhost","name","password"); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("npsari_other", $con); mysql_query("DELETE Image2 FROM ads WHERE ID='$ID'"); mysql_close($con); ?> Is this code right, because it doesnt work.
View Replies !
Specific Types
Is there anyway to count just the. jpg files in a directory? Right now I am counting all the files, but there are some file types I don't want to count.
View Replies !
Specific Variables
hi i was wondering how to count specific variables in an sql database and have it echo the count in a php script. below is what i have so far. PHP Code: $query = "SELECT * FROM ibf_members WHERE mgroup"; $result = mysql_query($query) or die("Query Ruter failed"); while ($row = mysql_fetch_array($result));
View Replies !
Rows With Specific Ids
I have many rows in my database, all with ids which are not unique. I would like to count these ids and display the numbers in a loop. Like so. Row 1 (67) Row 2 (34) Row 3 (234) All ids that match the id of the row should be counted and displayed. I have tried this. $count = mysql_result(mysql_query("SELECT COUNT(*) FROM table WHERE $id=id"), 0);
View Replies !
Returning Specific
I'm new to PHP. I have a properties database (MYSQL). When I click on a specific link, the results show all the properties in the database, however what I need the results to show is not all the properties but ones that meet a certain criteria. I want it to show the ones that are listed as "Rentals" only.
View Replies !
Specific Truncating
I have a block of text stored in a variable, it's order data so it's always different. It's data that is sent back to me as is, so I can't get at what makes it up. I'm trying to get the IP address from the middle of this block of text isolated and put into a variable. The IP always follows the words IP Address:
View Replies !
Looking For A Specific Script
I need to find a script that will allow users to submit their URL to my site and be displayed in a column. Along with that I would like it to have a hit counter to show how many times that link has been clicked. A good example of what I would like is on this site. http://www.lookom.com/. On the righthand side of the page is what I would like.
View Replies !
Specific Calender
I'm a designer by trade so PHP can sometimes be a little out of my comfort zone, but thats always a good place to be, right? I have a specific and I should imagine very easy thing i need to set up. I'm making a website for a band who play a lot of live shows. I wonder if anyone has the best solution to make a list of their shows that automatically deletes a show once it's date has passed. You know the way, say, the Myspace live list works. I don't need any fancy calender graphics or anything like that. Just a self-updating list.
View Replies !
How To Write IE Specific
I have a small peice of code that i want to append as a attribute to a html element ONLY if the users browser is IE. I know how to detect the browser in JS, however i have yet to find an easy way to detect IE in php Code:
View Replies !
Specific Fields In FFD
I have a flat file database with data like the following: Code: 01|Greg|5 02|John|1 02|John|5 03|Mary|3 04|Matt|2 02|John|3 with the form being ID|Name|Hours. How can I extract just, for instance, John's hours and show that he has worked 9 hours total (1 + 5 + 3)? I have found from various sites how to display a single person's information.
View Replies !
$http_referrer Allow Access From Specific URL Only
I am trying to figure out the correct PHP coding to put on a page that will only allow access if referred by a specific URL or URLs (link from another site) and if they are not c oming from that URL(s) then they are redirected to somewhere else like yahoo, etc.
View Replies !
Targeting Specific Frame
Hi I have used frames a while ago but not since going with PHP Is there anything special with frames and PHP I seem to be having trouble with targeting a different frame I have 3 frameset "top", "side" and "main" in the side frame I grab some info from a database and create a simple anchor tag with some variables loaded into into and I want to when the anchor tag is clicked have the information loaded into the "main" frame. the link does not appear to be created correctly here is the actual code for the anchor tag.
View Replies !
Search Question - How To Get Specific
I have a search script on my site now using LIKE with wildcards on either side. The problem is that if someone searches on "APHS" which is a type of film, anything with the word photogrAPHS comes up too. Obviously because the pattern matches. However if I take off the wildcards it wont find it because its not the first word of the string. Anyone have anything thoughts on how to go about that? So that if you search on APHS is searches the whole field to see if there is a word match?
View Replies !
Destroying A Specific Session?
how to destroy the server-side data associated with a session *after* session_write_close() has been called? session_destroy() won't work after session_write_close() because there is no currently-initialized session, and the manual doesn't indicate that there's any way of telling session_destroy() to destroy the data associated with a specific sessionid, which is the only route I could think of to make this work. Calling session_start() to initialize the session a second time (in preparation for a call to session_destroy()) isn't an option, because headers have already been sent by the script.
View Replies !
Find A Specific Value In An Array
What I want to do is compare a value against an array and perform a specified action if the value is in the array. Specifically, I want to preselect an option in a list based on whether or not the option id is in a field (a 'set' column) of a specific entry in a db. My code so far is: PHP Code:
View Replies !
Getting Data From A Specific Row With Mysql
I'm makin a member's area on my site with sessions, as they log in correctly the username is stored as $_SESSION['user'] what I can't work out, is how to access my table and extract data from just the row that has that username, eg SELECT * FROM table WHERE username=$_SESSION['user'] as I'm trying to make the users be able to edit profile, upload pics etc... any idea what I'm doing wrong?
View Replies !
Upload To Specific Folder
I am working in a directory: /www/domain/ and made the directory /www/domain/images/ What I need is for people to be able to upload images to this folder from a form on upload.php They should click browse and select their file to upload then press the "Upload" button. On the next page I want to display the .jpg or .gif that they uploaded. What is the coding for uploading that should go into the first upload.php script and the coding for the upload_result.php script. I think that the result could be: echo "<img src="images/$file">"; where $file = the image they uploaded. But I cannot seem to figure out what the first code should be.
View Replies !
|