Changed main domain, specified x10 name servers with registrar, site displays error p

Status
Not open for further replies.

linusgibson36

New Member
Messages
4
Reaction score
0
Points
0
Hi I have a problem with the website I just created. Previously I had the main domain set to paperhobbies.com.x10hosting.com for testing purposes and everything was working perfectly. I recently changed the main domain to gearvice.com (unchecked the use x10hosting subdomain option). Everything was changed without a problem. I then specified the nameservers for my gearvice.com domain with my registrar to ns1.x10hosting.com and ns2.x10hosting.com as specified in the forums. I can now log into the ftp account (ftp.gearvice.com) and it resolves withouta problem, and all the files are still there. However when trying to go to www.gearvice.com, it says Default Web Site Page: If you feel you have reached this page in error, please contact the web site owner. This has been tested by me and a couple other friends on their own computers, and error page is the same result.

I logged back into the ftp account and noticed all the .htaccess files still said paperhobbies.com.x10hosting.com. I changed all references to this previous host name to the new one, gearvice.com. This was done on every .htaccess file I could find (were a lot of them in the frontpage extension folders), an access.cnf file, and a postinfo.html file. It still will not display the website as it did before.

How can this be resolved? Thanks in advance for your assistance.
 

Anna

I am just me
Staff member
Messages
11,750
Reaction score
581
Points
113
Re: Changed main domain, specified x10 name servers with registrar, site displays err

Your domain should now be fully operational. There was an error in the domains configuration on the server which I have now corrected.

If you still can't reach it, please try clearing your browser cache.
 

linusgibson36

New Member
Messages
4
Reaction score
0
Points
0
Re: Changed main domain, specified x10 name servers with registrar, site displays err

Thanks for the expedient reply, and for fixing the server issue. Site is loading up as it did before except the PHP contact form doesn't seem to work with the PHP mail function anymore. Sending messages using the contact form used to be instantaneous and worked perfectly when the main domain was set to paperhobbies.com.x10hosting.com, but now I have not received any of the test messages between myself and a couple other people (been 45 minutes so far and no emails yet).

Is it because the name servers haven't fully propogated yet, or could this be due to another issue? Thanks again in advance for any assistance or at least your thoughts on the matter.
 

dlukin

New Member
Messages
427
Reaction score
25
Points
0
Re: Changed main domain, specified x10 name servers with registrar, site displays err

Make sure the "From" header in the outgoing mail uses your current domain name.
 

linusgibson36

New Member
Messages
4
Reaction score
0
Points
0
Re: Changed main domain, specified x10 name servers with registrar, site displays err

* UPDATE *

I just realized through email admin in CPanel that the default email account that coes with the free account is not the same as username@gearvice.com after seeing a return to sender bouceback in the default email account inbox. Doi. So I created username@gearvice.com and added the headers as indicated in my original reply, but still no email to my personal account as specified by $your_email. However...

I'm making some progress after reading in the forums that external email accounts sometimes don't receive messages via PHP contact forms, at least here at X10. I also set $your_email in my form code to an internal one username@gearvice.com and now messages are coming through.

Small victory, but a victory nonetheless. :) I was hoping I could have the form automatically send an email to my cell phone as a text message... who knows, maybe it still can. But if it can't then I guess I can set up an auto forward rule. Either way, feel free to close this thread unless you have any other relevant thoughts.

* ORIGINAL REPLY *

I didn't specify any From headers in the PHP contact form code when the main domain was previously paperhobbies.com.x10hosting.com and not only did the PHP contact form work, it was lightning fast (received messages in my personal email account only a couple seconds later after submitting them via the form). Here is the code I'm using for the PHP contact form:

Code:
<?php
if(!$_POST) exit;
$email = $_POST['email'];
 
//$error[] = preg_match('/\b[A-Z0-9._%-]+@[A-Z0-9.-]+\.[A-Z]{2,4}\b/i', $_POST['email']) ? '' : 'INVALID EMAIL ADDRESS';
if(!eregi("^[a-z0-9]+([_\\.-][a-z0-9]+)*" ."@"."([a-z0-9]+([\.-][a-z0-9]+)*)+"."\\.[a-z]{2,}"."$",$email )){
$error.="Invalid email address entered";
$errors=1;
}
if($errors==1) echo $error;
else{
$values = array ('name','email','message');
$required = array('name','email','message');
$your_email = "masked@forprivacy.com";
$email_subject = "New Message: ".$_POST['subject'];
$email_content = "new message:\n";
foreach($values as $key => $value){
if(in_array($value,$required)){
if ($key != 'subject' && $key != 'company') {
if( empty($_POST[$value]) ) { echo 'PLEASE FILL IN REQUIRED FIELDS'; exit; }
}
$email_content .= $value.': '.$_POST[$value]."\n";
}
}
$email_content .= 'company'.': '.$_POST['company']."\n";
$email_content .= 'phone'.': '.$_POST['phone']."\n";
if(@mail($your_email,$email_subject,$email_content)) {
echo 'Message sent! You will receive a reply shortly.'; 
} else {
echo 'ERROR!';
}
}
?>

I tried adding From headers to match the default email address that comes with the free account anyways and it's still not working. I left the email the form sends the message to as my personal email address I was using before for testing purposes. Updated code:

Code:
<?php

if(!$_POST) exit;

$email = $_POST['email'];


//$error[] = preg_match('/\b[A-Z0-9._%-]+@[A-Z0-9.-]+\.[A-Z]{2,4}\b/i', $_POST['email']) ? '' : 'INVALID EMAIL ADDRESS';
if(!eregi("^[a-z0-9]+([_\\.-][a-z0-9]+)*" ."@"."([a-z0-9]+([\.-][a-z0-9]+)*)+"."\\.[a-z]{2,}"."$",$email )){
	$error.="Invalid email address entered";
	$errors=1;
}
if($errors==1) echo $error;
else{
	$values = array ('name','email','message');
	$required = array('name','email','message');
	 
	$your_email = "masked@forprivacy.com";
	$headers = "From: maskedforprivacy@gearvice.com\r\n";
	$email_subject = "New Message: ".$_POST['subject'];
	$email_content = "new message:\n";
	
	foreach($values as $key => $value){
	  if(in_array($value,$required)){
		if ($key != 'subject' && $key != 'company') {
		  if( empty($_POST[$value]) ) { echo 'PLEASE FILL IN REQUIRED FIELDS'; exit; }
		}
		$email_content .= $value.': '.$_POST[$value]."\n";
	  }
	}
	
	$email_content .= 'company'.': '.$_POST['company']."\n";
	$email_content .= 'phone'.': '.$_POST['phone']."\n";
	 
	if(@mail($your_email,$email_subject,$email_content,$headers)) {
		echo 'Message sent! You will receive a reply shortly.'; 
	} else {
		echo 'ERROR!';
	}
}
?>

Alas, I am still stumped.
 
Last edited:
Status
Not open for further replies.
Top