473,506 Members | 14,630 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Newsletter signup

Hi, i´m new in php. This is for newsletter subscription

How can I add the following:
1.- email already in database
2.- subscribe/remove (from two radio buttons)
Like [www.siteinteractive.com/subscribe/ "Join Our Mailing List"]
To this code (or change it):

<?php
function ConnectDB()
{ if (!($link=mysql_connect("localhost","ddbb_user","pa ssword")))
{ echo "Error..."; exit(); }
if (!mysql_select_db("ddbb_database",$link))
{ echo "Error..."; exit(); }
return $link; }
$link=ConnectDB();

$email=$_GET['email'];
mysql_query ("INSERT INTO mydb_list (list_email) VALUES ('$email')");
mysql_close($link);
?>

<html>
<head>
</head>
<body>
Your email: <?php echo $_GET['email'] ?>
</body>
</html>

Regards,
J.A. (F.N.)

Aug 11 '05 #1
0 1097

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1919
by: Nis Sarup | last post by:
A customer of mine wants to make a newsletter for their website. The newsletter should be HTML with images and sent to a database of her subscribers. They would like a script where they can easily...
0
2933
by: cooldv | last post by:
i have an *access database + ASP newsletter* that is working fine and it sends newsletter to ALL the email addresses in the DB. i want to send this newsletter to only a select group (like people...
0
1636
by: sylvain | last post by:
http://groups.yahoo.com/group/HiTechUnited (Source of articles about the HiTech Underemployment Crisis) HiTechUnited is a weekly newsletter, delivered Mondays, written by and for...
0
1051
by: Geoff Coope | last post by:
Hi All I have a client that wants a newsletter system that can handle. Templates where they can add images / text Newsletter signup via own website into db UnSubscribe Managament of db and...
1
4659
by: Michel Couche | last post by:
Hello, I am starting the development of a newsletter The use of the class MailMessage of System.Net.Mail is quite straightforward for usual contact forms but my question here is "How can I...
0
1353
by: jon | last post by:
Hey, i've been trying to create a signup page that asks for a username, password and then to confirm the password. It is suppose to check how long both of them are, and if the passwords line up,...
1
3209
by: kang jia | last post by:
hi when user entered particulars in signuppage and click" signup" button, i will direct them to do_signup.php. if say the NRIC is dupicate in datebase, i will redirect them back to signup page...
11
1584
by: ginoplusio | last post by:
Hi, I'm developing a software to send newsletter to the users of my website. I have a problem on the stats, detecting the opening of the newsletter on the user's client. The method I've chosen...
0
7105
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7308
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7371
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
7023
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7479
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5617
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4702
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3188
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
410
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.