Jump to content

fazlionline

Member
  • Posts

    204
  • Joined

  • Last visited

Everything posted by fazlionline

  1. Hi all, I want to check if the user is using Internet Explorer 7 or above, if it is version 7, he should have an Alert saying “You're using 7.x, please update your IE” and if he has version 8 so NO alert should appear. My code is bellow but I am getting alert for both versions. Need help <script type="text/javascript"> if (/MSIE (\d+\.\d+);/.test(navigator.userAgent)){ //test for MSIE x.x; var ieversion=new Number(RegExp.$1) // capture x.x portion and store as a number if (ieversion>=8) alert("") else if (ieversion>=7) alert("You're using 7.x, please update your IE") } </script>
  2. Hi BeeDev I was confused with some steps in your code 1- I have made a PHP file named "myUrlIncludeFile.php" And stored the following information there <?php $base = 'http://fazlionline.com/v1'; ?> 2 - Then I pasted the following code on very-top of each page <?php require_once('myUrlIncludeFile.php') ?> 3 - then past the following code in each page in tag But it didn?t work. Note: i didnt changes the slashes becaues when i do that, the image disapear form design wiev, (Like broken link) and when online, the LINK also shows INCORRECT/broken
  3. I have added slash to images, It is just replaced from: To: So the main change was just a slash before now, please see the main page and sub page Two images are not working And even click on web design button is giving page error
  4. But I have PHP Include function on each page which is calling menu. If I change it to Then the main page will give error
  5. Thanks both But adding slash with each image will WORK but what about links then. In home page my link was So what with links then When I am in ?v1/webdesign Folder, then Will also give error Is there any better solution Also for time being, I have just webdesign Folder, but later on, I want to add more folders like grapic_desing, domain_host, News, and more. So i have to make changes in each folder. In there any better solution
  6. I have created a menu in Adobe Fireworks CS3 Exported that, and copied all files to my main directory. I have linked the menu with <?php @include ('slidemenu03_sub.htm'); ?> It works fine in main page, see the link: Then I have created a folder named webdesign and copied index.php and past in webdesign folder, renamed it as web_design.php I changed the include code as: <?php @include ('../slidemenu03_sub.htm'); ?> I have just added ../ in there. Now when I brow http://fazlionline.com/v1/webdesign/web_design.php All images are missing and menu is not visible. Can anyone help me what is wrong
  7. thanks alot. can i store the value returend by foreach in a variable? foeexample: if (isset($interest) && $interest != '') {foreach ($interest as $int){ $details .= "$int - ";}} $SelectedInterests = $int ; becuse i want to add this varibale in $details : ... $details = "\n URL - Form: $url\n Subject: $subject\n Name: $name\n email: $email\n system: $system \n gender: $gender \n message: $message \n [b][color=red]Interest: $int \n[/color][/b] language: "; ... thanks
  8. Thanks, now I do not get error if all checkboxes are left blank. I have added second group, interests. It also works fine but I get languages and interests values all in one line in my email. I have changed the code to this: But didn?t worked How I can get them to appear each group in each line. Like My HTML Code is:
  9. thanks i read PHP foreach and PHP array in TIZAG.com thanks alot. now, i have two qestions: 1 - if a user do not click any of the optoin in langauges, i get error: 2 - as i am working on Job Application Form, i need such more checkboxes group. for example, this one was for language, other may be for Interesets (Interest: PHP, JAVA, CSS), other may be for somthing else. so how i can make all together in my above PHP scrip? thanks
  10. instead of Print, how i can store the loop value in a variable and send that variable through mail()
  11. falkencreative i have changes my script according to your suggestion now i get a messages after i submit form" but in my email, i get:
  12. Contact us form Full Name: Persoanl Email: Operating System Windows Linux Mobile Gender Male Female Languages: English Pashto Dari Message: File Attachment:
  13. its working now but i want to add some checkboxes to the form i used the follwoing code, but selected checkboxes do not apears in sent mail.
  14. yes, there was a problem in PHP code in line 62 and i have fixed it. PHP Code: <?php $to = "[my real email]" ; $subject = " Applied for Web Design "; ; $name = $_REQUEST['name'] ; $city = $_REQUEST['city'] ; $email = $_REQUEST['email'] ; $gender = $_REQUEST['gender'] ; $mobile = $_REQUEST['mobile'] ; foreach($_POST['language'] as $value) { $check_msg = "$value\n"; } $language=$check_msg; $gender = $_REQUEST['gender'] ; $url = "T6 - EGGI - Application for Job"; $details = "\n URL - Form: $url\n Subject: $subject\n Name: $name\n City: $city\n From: $email \n Gender: $gender \n Mobile: $mobile \n Language: $language \n "; ini_set("sendmail_from", $email); // Obtain file upload vars $fileatt = $_FILES['fileatt']['tmp_name']; $fileatt_type = $_FILES['fileatt']['type']; $fileatt_name = $_FILES['fileatt']['name']; $headers = "From: $email"; if (is_uploaded_file($fileatt)) { // Read the file to be attached ('rb' = read binary) $file = fopen($fileatt,'rb'); $data = fread($file,filesize($fileatt)); fclose($file); // Generate a boundary string $semi_rand = md5(time()); $mime_boundary = "==Multipart_Boundary_x{$semi_rand}x"; // Add the headers for a file attachment $headers .= "\nMIME-Version: 1.0\n" . "Content-Type: multipart/mixed;\n" . " boundary=\"{$mime_boundary}\""; // Add a multipart boundary above the plain message $message = "This is a multi-part message in MIME format.\n\n" . "--{$mime_boundary}\n" . "Content-Type: text/plain; charset=\"iso-8859-1\"\n" . "Content-Transfer-Encoding: 7bit\n\n" . $details . "\n\n"; // Base64 encode the file data $data = chunk_split(base64_encode($data)); // Add file attachment to the message $message .= "--{$mime_boundary}\n" . "Content-Type: {$fileatt_type};\n" . " name=\"{$fileatt_name}\"\n" . //"Content-Disposition: attachment;\n" . //" filename=\"{$fileatt_name}\"\n" . "Content-Transfer-Encoding: base64\n\n" . $data . "\n\n" . "--{$mime_boundary}--\n"; } // Send the message $ok = mail($to, $subject, $message, $headers); if ($ok) { echo " Mail sent! Yay PHP!"; } else { echo " Mail could not be sent. Sorry!"; } ?>
  15. how can i change php.ini while my files are uploaded on my website.
  16. Contact us form Name: Email: Location: Gender Male Female Subject: Message: File Attachment:
  17. before removing "@", my error was: after removing "@", my error is:
  18. <?php // Read POST request params into global vars $to = $_POST['to']; $from = $_POST['from']; $subject = $_POST['subject']; $message = $_POST['message']; // Obtain file upload vars $fileatt = $_FILES['fileatt']['tmp_name']; $fileatt_type = $_FILES['fileatt']['type']; $fileatt_name = $_FILES['fileatt']['name']; $headers = "From: $from"; if (is_uploaded_file($fileatt)) { // Read the file to be attached ('rb' = read binary) $file = fopen($fileatt,'rb'); $data = fread($file,filesize($fileatt)); fclose($file); // Generate a boundary string $semi_rand = md5(time()); $mime_boundary = "==Multipart_Boundary_x{$semi_rand}x"; // Add the headers for a file attachment $headers .= "\nMIME-Version: 1.0\n" . "Content-Type: multipart/mixed;\n" . " boundary=\"{$mime_boundary}\""; // Add a multipart boundary above the plain message $message = "This is a multi-part message in MIME format.\n\n" . "--{$mime_boundary}\n" . "Content-Type: text/plain; charset=\"iso-8859-1\"\n" . "Content-Transfer-Encoding: 7bit\n\n" . $message . "\n\n"; // Base64 encode the file data $data = chunk_split(base64_encode($data)); // Add file attachment to the message $message .= "--{$mime_boundary}\n" . "Content-Type: {$fileatt_type};\n" . " name=\"{$fileatt_name}\"\n" . //"Content-Disposition: attachment;\n" . //" filename=\"{$fileatt_name}\"\n" . "Content-Transfer-Encoding: base64\n\n" . $data . "\n\n" . "--{$mime_boundary}--\n"; } // Send the message $ok = @mail($to, $subject, $message, $headers); if ($ok) { echo "Mail sent! Yay PHP! "; } else { echo "Mail could not be sent. Sorry! "; } ?>
  19. I have I contact us form to send data to my email. All fields works fine but I get the Gender value NOTHING. Can anyone tell me what is wrong in my scrip? <?php $to = "[my real email]"; $subject = $_REQUEST['subj'] ; $name = $_REQUEST['name'] ; $city = $_REQUEST['city'] ; $email = $_REQUEST['email'] ; $message = $_REQUEST['message'] ; $gender = $_REQUEST['gender'] ; $url = "T1 - fazlionline - Contact Form"; $details = "\n URL - Form: $url\n Subject: $subject\n Name: $name\n City: $city\n From: $email \n Gender: $gender \n Message: $message \n "; ini_set("sendmail_from", $email); $headers = $email; $sent = mail($to, $subject, $details, $headers, $message) ; if($sent) {print "Your mail was sent successfully"; } else {print "We encountered an error sending your mail"; } ?>
  20. I saw news flash in this website News does not scroll like marquee but appear from left to right like flash. Can anyone tell me in which programs I can make same and what exactly it?s called?
  21. WOW I have found in DreamWeaver CS3 Here is how to do it: In the Document window, place the insertion point where you want the date to be inserted. Do one of the following: Select Insert > Date. In the Common category of the Insert bar, click the Date button. In the resulting dialog box, select a format for the name of the day of the week, a format for the date, and a format for the time. If you want the inserted date to be updated every time you save the document, select Update Automatically On Save. If you want the date to become plain text when it?s inserted, and never update automatically, deselect that option. Click OK to insert the date. See Adobe Center For more inforamtion: http://livedocs.adobe.com/en_US/Dreamweaver/9.0/help.html?content=WSc78c5058ca073340dcda9110b1f693f21-7ccd.html
  22. I liked the border [right & left] in main blogger page, can anyone tell me how to make this. I think this is possible with CSS but I do not know how to do that. I have encircled [right & left] border with red in this Blogger.
  23. Thanks Virtual for your good comments. Actually, I searched Google and I found many Script, but I was unable to find a script where minutes and second changes frequently.
  24. I want to have a countdown to my birthday, 10 February 2010, can anyone help me how to create it. Changes should occur each second without Page refresh.
×
×
  • Create New...