Page 1 of 1

problem with sending mail and htaccess

Posted: Sat Jan 08, 2011 8:02 pm
by Katman
hey all, I am new to these forums and pretty knew to php programming but i think i get the basics. I tried to create several websites before but lost interest after a while. recently though i have been coming up with what seems to me like really interesting web ideas so I am back to have an interest in web programming. In fact after I graduate from biochemistry this semester going back to do a degree in computer science. always have loved programming but in terms of job opportunities i was told there were none in programming hence why i went into the safe route of biochemistry.

well anyways my current site that I have up is called dateratenow.com and its a site where you essentially tell your friends things you couldn't tell them to their face. maybe they do something that annoys you so you want to them to get the message you want them to stop. but not just want them to stop but give them pointers on how they can. anyways i had a registration step but the people who visited did not seem to eager to register so i removed it and had them enter their friends email into the rating section so their friends could be notified that someone (without mentioning names) rated them. I tried the mail ($to,$subject,...) method but it did not work. any code i could use for that?

second i accidentally deleted my htaccess page in cpanel and cannot find it in my trash. so i created a new one thinking that when i typed in it "directoryindex ratings.php" would do it did not. my index.html page is still the directory index, and it still shows up first. when you click from ratings, terms or contact it takes you to the correct pages and correct link paths. but once you click post a date button in ratings it takes you back to index.html. i checked the button and it is to take you to post.php but that does not work.

i hope that i explained it well. anyone have any ideas?

ps. also working another site on the side and wanted to know if there was any php way of opening a site within a div? i tried iframes but they do not work on sites such as facebook and gmail, which my site requires

Re: problem with sending mail and htaccess

Posted: Sun Jan 09, 2011 10:35 am
by jarofgreen
Interesting. Personally I wouldn't trust such a site after that whole fiasco with the facebook app where you could rate your friends anonymously. They did that for years then suddenly started selling premium access where you could pay and see who said what :-) Not that I would have used the original either.

Anyway, emails: what error message comes up when you try? Post the email sending code? Or does it send but then never get there? Unfortunately, email sending is not simple these days - there are so many anti-spam traps out there it's easy to fall foul off.

Should be directoryindex. Are you sure cpanel isn't overwriting your .htaccess with it's own?

Ahh, you are trying to put other sites inside your own frame? Problem is other sites tend to hate that (rightly so in my view) so will use code to detect that and bust out. It's always a arms race that you will constantly be working on, there is no one easy solution.

Re: problem with sending mail and htaccess

Posted: Mon Jan 10, 2011 12:00 pm
by Katman
Thanks for the reply man. I'll get back to you on the mail part of the question because the htaccess part is overwriting it. But for the htaccess all I have is one line that defines my page ratings.Php as my default page. But for some reason the index.HTML page is my default and my default to post. I have no clue why. Any ideas? Also I do not think cpanel is overwriting it as I have tried to find another htaccess page in my file manager but found none.

Re: problem with sending mail and htaccess

Posted: Mon Jan 10, 2011 12:27 pm
by Katman
Also bro I don't think I would ever be able to do that. I see what that facebook app did as a breach of trust. They don't have any real business sense if all they came up with is selling what people trusted to them.

Re: problem with sending mail and htaccess

Posted: Thu Jan 20, 2011 9:09 pm
by Katman
well does anyone at least know a basic site for htaccess?

Re: problem with sending mail and htaccess

Posted: Mon Jan 24, 2011 8:38 pm
by Katman
you were right jarofgreen cpanel did overwrite my htaccess. I just rewrote directoryIndex, but my link to post.php is linking to my old index.html file. Anyone have any ideas? I have searched some other sites and couldn't find anything.