Email creator

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
Alidad
Forum Commoner
Posts: 29
Joined: Thu Mar 29, 2007 12:42 pm

Email creator

Post by Alidad »

hi, I wrote code that allow me to create email account outside of cpanel and works greats with one domain name.
However I'm trying to change code for two domains to select domain name using menu.

The forms that i wrote is come with one text fields for input user name and one drop menu for select domain which is:

Code: Select all

<input name="username" size="20" />
		  <select name="domain_select" id="domain_select">
		    <option value="domain.com">domain1.com</option>
		    <option value="domain2.com">domain2.com</option>
        </select>
and then is sending data to other page which is config.php and

Code: Select all

$username = 'username'; // This variable is the cPanel username
$password = 'password'; // Please enter your cPanel password
$domain_name = 'domain1.com, domain2.com'; // Please enter the domain name associated with the account
$domain_select = $domain_name;
$skin = 'x3'; 

and then it will process to other page which is

"http://$username:$password@$domain_name:2082/frontend/$skin/mail/doaddpop.html?email=$_POST[username]&domain=$domain_name&password=$_POST[password]&quota=25");

For some reason is not working right, event i put

Code: Select all

$domain_name = 'domain.com, domian2.com';
between two domain im getting result of domain1.com.
i also changed the variable name to

Code: Select all

$domain_name = '$domain_select ';
and still not working.

Can anyone help me how can i solve this by select one domain name from menu before create email account!

please help thanks.

AM
Last edited by Alidad on Wed Apr 20, 2011 7:10 am, edited 2 times in total.
zyntrax
Forum Commoner
Posts: 32
Joined: Wed Apr 13, 2011 2:23 am
Location: Sweden

Re: Email creator

Post by zyntrax »

What method is your form posting in?
Post Reply