Jump to content

ShaKeD

Members
  • Posts

    23
  • Joined

  • Last visited

    Never

Everything posted by ShaKeD

  1. Hey to all, I`m trying to send mail, with http://pear.php.net/package/Mail. my functions page formatted as ASCI UTF8 without BOM (using notepad++) and when I make my email, my header is $utf8h = "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />"; when I return my $html I use return iconv("UTF-8", "ISO-8859-8", $html); and then send my email: preparing to send: $html = build_newsletter($values); $text = 'Text version of email'; // sends it to the clients list: require_once('Mail.php'); require_once('Mail/mime.php'); global $websiteName; $today = date("d/m/Y"); $hdrs = array( 'From' => "$websiteName mail <newsletter@".str_replace(" ","","$websiteName").".co.il>", 'Subject' => "[$today] ניוזלטר מאתר $websiteName: {$values['title']}", 'Content-type' => 'text/plain; charset=iso-8859-1' //str_replace(" "," ","[$today] ניוזלטר מאתר $websiteName: {$values['title']}") ); $crlf = "\n"; $mime = new Mail_mime($crlf); $mime->setTXTBody($text); $mime->setHTMLBody($html); $body = $mime->get(); $hdrs = $mime->headers($hdrs); $mail =& Mail::factory('mail'); //send our email! $x = $mail->send($client_address, $hdrs, $html); sorry about my bad english and thank you all for the help! Shaked.
  2. I don't wanna bug anyone , but maybe someone can help here?
  3. solved I meant $_SERVER['SERVERNAME'];
  4. Hey, I want to make a script that take my address and print it. I mean, if I`m now at www.phpfreaks.com I want to do somthing like echo $mywebsite and to get: www.phpfreak.com what do I need to write at $mywebsite for getting this result? thanks in advance, Shaked.
  5. hey all, i`m using phpbb forums and I learned the system throw her code. I`m trying to add html file (that doesn't belong to phpbb) on the top of the page (overall_header.tpl is the top of the page), my problem is that phpbb using <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-8-I"> and my html file must use <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> how can I merge them, that I will see the html file at the top of my page, and then I will see the phpbb forum, without using IFRAME I tryied to use: $mywebpage = file_get_contents("mypage.html"); and then replace {mypagehtml} (at overall_header.tpl) with $mywebpage. Thank you for you help, Shaked.
  6. I used $lang as array lang.php - $lang[blah] = ' blah ' ; $lang[blaas] = ' blah sadf'; index.php - include 'lang.php'; $_GLOBALS['lang'] = $lang; but when I`m using $lang inside my functions it doesn't work.
  7. ok, thanks but maybe there is a way to "define" the include ?
  8. Hey, I`v a problem. I`m using include function. include 'lang.php'; now I want to use all of the variables that exist in lang.php .. the problem is that I`m using functions on my index.php file, and I don't want to enter the function every time with those variables. how can I fix it? 10x.
  9. ok , so how can I do this to work, this was my question. another way of course and not include to variable
  10. Hey all I`m using php file named test.php, and html file named style.sspic (sspic=my system files.). Now on my php file I have $upframe='my php test file blah blah balh'; $htmlpage = include 'style.sspic'; str_replace('{upframe}',$upframe,$htmlpage); and on my html file I have <html> <head> <title>Untitled 1</title> </head> <body topmargin="0" leftmargin="0" rightmargin="0"> <table style="width: 100%" class="style1"> <tr> echo <td align=center>{upframe}</td> </tr> </table> </body> </head> </html> how can I make it work , that when I open my php file, I will see {upframe} as $upframe ? Thanks for you time and help!
  11. ok so I`m using mbot plugin for miranda, this plugin give you to bulid things with php and use them on the miranda, so I have start to work on script that sends emaill throw miranda.. so I did this function : function dlg_callback($ok,$param) {   if($ok == 0)return 1; //cancel or close   $dlg = mb_DlgGet();   $user =  mb_DlgGetText($dlg,1000);   $subject = mb_DlgGetText($dlg,1002);   $message = mb_DlgGetText($dlg,1004);   $headers = "From: <email>\r\nReply-To: email";   if($subject != "" && $message != ""){     mail($user,$subject,$message,$headers);     mb_msgbox("your message has been sent to ".$user);     return 1;   }else{     mbox("you must use the subject and message body both.");     return 0; //if you want to finish the dialog return "end";   } } I checked if I get somthing in $message,$subject and $user and I did, I got everything I need for ex. : $user = myemail@gmail.com $subject = hey whats up! $message = this is a test the problem the I don't get any mail at all.. what can I do ? 10x :)
  12. I didn't understand the differenet.. . this is my code.. : [code]   <?php . . . $headers = "From: <email>\r\nReply-To: email";   mail($user,$subject,$message,$headers); . . . ?>[/code]
  13. Hey again, I was trying to use mail(); function and I got no luck, why is that? [code] mail($user,$subject."(from)",$message,"From $user"); [/code] $user= my email .. $subject = subject from edit box $message= from edit box...  what do you think?
  14. how can I point <input textbox> without control this page...
  15. I will write it again! the problem is like that.. In the internet someone enter the page "1.php" this page gives you to connect and see your profile in the website, BUT this webmaster forgot to add checkbox for "remember my password" and he didn't use cookies. So I wanted to add it myself, how? I want to use IFRAME to this page "1.php" to my page (we can call my page "2.php" for the example). Now in "2.php" I will put a submit button that when I will click on him it will automaticly write my details in the iframe of "1.php" means that if I click on submit it will write in the username textbox username that I wrote in the code when I click submit. I will continue alone from here, but how can I do it? [short words] I just want to use this button to enter value to editbox on another page of someother(not mine) website hope you will understand me
  16. yeah it isn't.. I just want to use <input "textbox"> from another page like if you have page.php: <html> <head> </head> <body> <iframe src="www.gmail.com"> <form method="POST" action="#"> <p dir="ltr"><input type="submit" value="Submit" name="B1"> </form> <?php if ($_POST['B1'] = Submit) {   ['UserName'] = "MYUSERNAME"; -> textbox of the username will get the value "MYUSERNAME"   ['Password'] = "PASSWORD"; -> textbox of the password will get the value "PASSWORD" } ?> now its more clear?
  17. OK I will give you an example: I want to enter my password to my email throw my website, what does it mean? I`v gmail account, now I want to connect throw my page.php so I used <iframe> for the gmail.com page and now I added a button on page.php, this button gives me my details (user\pass) when I click on it. BUT I want that this button will enter automaticly my details (user\pass) to the inputs so I will connect faster and I'll be able to add checkbox that will connect me automaticly to my gmail. this is an example, I know that I don't need it and I`v checkbox on gmail. thanks
  18. How to enter a value to <input> without writing in it ? like I mean I`v <input textbox in page 1.php and now I want to enter the word "what" from 2.php I tryied to do this : if ($_POST['B1'] = Submit) { $_GET['myfor] = "what"; } <input B1  is on 2.php ! thanks :)
  19. Hey, I was starting using php again and I don't remember how can I use this option of Variables: $x = "abc"; $x. = "def"; echo $x; [u][b]display: [/b][/u] abcdef but I don't get the display, I get an error; [b]Parse error: parse error, unexpected '=' in C:\apache2\htdocs\down.php on line 3[/b]
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.