Tuesday, June 23, 2009

Tuesday, June 23, 2009

I worked from midnight until like 2:30 AM on the web system for students to check their grades online, which is a social work that I am collaborating with, and it is also a collaboration for the scholarship I got here in El Salvador, at UNICAES university.

At 5:07 AM I received this email from Tang Khai Shing, who is helping me a lot by answering all of my questions about traveling in the United States, campus like at UAH, etc.:

In fact, I traveled twice to NYC. First time was about 4 days...2nd time was 3 days. I don't rmb how much I spent...but the hostel was bout $35 per night...food mayb bout $10 per meal....transportation bout $7 per day for subway. If you really wana 'see' NYC...at least a week would be good...but I dont think you'll hav so much time. I followed the tour the first time i went to NYC...spent bout 3 days in NYC....but had to rush coz visited several places. Itz all up to you...depends on where u wana visit....you can look for some info online and work out your own schedule....this will be better. Some popular things to do or places to go are Statue of Liberty & Ellis Island, Rockefellar, Empire State Building, Broadway show, Central Park, Financial District, Brooklyn Bridge, Times Square...etc. It all depends on your interests...you might be interested in other things...hehe!! :p

Our workshop was 3D2N.


Regards,
Khai Shing

At 10:40 AM I asked this question on Yahoo! Answers:

What is the difference between "switch off" and "turn off"?

I read this sentence:

We would like to remind you that mobile phones must remain completely SWITCHED OFF until the seatbelt sign has been TURNED OFF.

I wonder if they used switch off just for not being redundant and write turn off twice. But I think in this case it means that the cell phone/mobile phone had to be turned off, or completely turned off. Is there any difference? Thanks.

Then I answered these questions on Yahoo! Answers:

What do TTYL stand for?

My answer:

Talk To You Later. It is usually used when chatting on the Internet, like in a chatroom, Yahoo! Messenger, Meebo, MSN, etc. It is just like LOL (Laughing Out Loud or Laugh Out Loud). It is Internet slang.

Question:

PHP Code to link to a html form. Help!!?

I have been working on this code for hours and its not working. please help me figure it out!

<?php
$error_occured = "no";
$name = $_POST['name'];
$b_name = $_POST['b_name'];
$number = $_POST['number'];
$email_address = $_POST['email'];
$situation = $_POST['situation'];
$checkup = $_POST['brand_checkup'];
$bb_workshop = $_POST['BB'];
$recommend = $_POST['Recommend'];
$creative = $_POST['Creative_Team'];
$nominate = $_POST['Nominate'];
$inspired = $_POST['Inspired'];
$subject = $_POST['subject'];

if($error_occured=="no") {

$to = "michelle@localhost";
$email_from = $email_address;
$email_subject = "New mail from www.enyeheri.com!";
$email_body = "You have received a new message. Here are the details: \n\nName:" .$name . " \n\n Business Name:" .$b_name. "\n\n Business Number: " . $number ."\n\n Email Address:" .$email_address . "\n\n Business Situation:" .$situation . "\n\n Brand Check-up: " . $checkup . "\n\n BB workshop: " .$bb_workshop . "\n\n Recommendation: " .$recommend . "\n\n Creative Team: " .$creative . "\n\n Nominate: " .$nominate . "\n\n Inspired: " .$inspired ;
$headers = "From: $email_from";
mail($to,$email_subject,$email_body,$h...
echo "Your message was sent successfully";
}
?>


My answer:

I think your question is not well structured, and so it is difficult to guess what you really want. If you want a PHP code to link to a HTML form, create a .htm page where you have a HTML form, and in order to link to your HTML page with the HTML code, you just use this PHP code:

<?php
echo "<a href='yourhtmlform.htm'>Go to the HTML form</a>";
?>

As for the code you posted, you are using the $_POST[] method, but you need to have the HTML form so that you are calling the information from the HTML form. You need something like this:

<input type='text' value='' name='username' id='username' size='30' maxlength='15' />

Then when you use the PHP code

$name = $_POST['username'];

it would be taking the information that is written in the text box, or whatever the user has written. So I suggest you to study about HTML forms, it is easy, just about adding some text boxes with the <input type='text'...> tag, then putting a button with the <input type='submit'...> tag, and finally use the variables written by the user and doing whatever else you want to do with PHP code. As I can see, you want an HTML form for users to write something in, so that the information can finally be sent to an email address. Nice, you will end up doing this, just keep on working, and I could help you if you need it.
Take care.

I exercised at home twice at the end of the morning.

At night I worked on the design of the database and I planned how the SQL queries would work for the web system for students to check their grades online.

Jaime Montoya
webmaster@jaimemontoya.com
www.jaimemontoya.com

0 comments:

About Me