define("ltrWd", 612); // 11 inches height ---> define("ltrHt", 792); // name new space in memory as "$pdf1" ---> $pdf1 = pdf_open($fp); // misc. info ---> pdf_set_info($pdf1, "Created_by", "Yingyi Lu"); // begin first page ---> pdf_begin_page($pdf1, ltrWd, ltrHt); $page = "page 1"; // outline entry ---> pdf_add_outline($pdf1, $page); // Set color for text, set font and write title ---> pdf_setrgbcolor_fill($pdf1, 0, 0, 0); pdf_set_font($pdf1, "Times-Bold", 20, "host"); pdf_set_text_pos($pdf1, 179, 740); pdf_show($pdf1, "Welcome New Member!"); // First name ---> pdf_set_font($pdf1, "Times-Roman", 12, "host"); pdf_set_text_pos($pdf1, 70, 690); pdf_setlinewidth($pdf1, 1); pdf_show($pdf1, "First Name:"); pdf_moveto($pdf1, 170, 690); pdf_lineto($pdf1, 320, 690); pdf_stroke($pdf1); // Last name ---> pdf_set_text_pos($pdf1, 70, 660); pdf_show($pdf1, "Last Name:"); pdf_moveto($pdf1, 170, 660); pdf_lineto($pdf1, 320, 660); pdf_stroke($pdf1); // Age ---> pdf_set_text_pos($pdf1, 70, 630); pdf_show($pdf1, "Age:"); pdf_moveto($pdf1, 170, 630); pdf_lineto($pdf1, 220, 630); pdf_stroke($pdf1); // Gender ---> pdf_set_text_pos($pdf1, 70, 600); pdf_show($pdf1, "Gender:"); pdf_rect($pdf1, 170, 600, 10, 10); pdf_stroke($pdf1); pdf_set_text_pos($pdf1, 185, 600); pdf_show($pdf1, "Male"); pdf_rect($pdf1, 245, 600, 10, 10); pdf_stroke($pdf1); pdf_set_text_pos($pdf1, 260, 600); pdf_show($pdf1, "Female"); // Marital ---> pdf_set_text_pos($pdf1, 70, 570); pdf_show($pdf1, "Marital:"); pdf_rect($pdf1, 170, 570, 10, 10); pdf_stroke($pdf1); pdf_set_text_pos($pdf1, 185, 570); pdf_show($pdf1, "Single"); pdf_rect($pdf1, 245, 570, 10, 10); pdf_stroke($pdf1); pdf_set_text_pos($pdf1, 260, 570); pdf_show($pdf1, "Married"); pdf_rect($pdf1, 320, 570, 10, 10); pdf_stroke($pdf1); pdf_set_text_pos($pdf1, 335, 570); pdf_show($pdf1, "Seperate"); pdf_rect($pdf1, 395, 570, 10, 10); pdf_stroke($pdf1); pdf_set_text_pos($pdf1, 410, 570); pdf_show($pdf1, "Divorced"); // Horoscopte sign ---> pdf_set_text_pos($pdf1, 70, 540); pdf_show($pdf1, "Horoscope Sign:"); pdf_moveto($pdf1, 170, 540); pdf_lineto($pdf1, 320, 540); pdf_stroke($pdf1); // Ethnicity ---> pdf_set_text_pos($pdf1, 70, 510); pdf_show($pdf1, "Ethnicity:"); pdf_moveto($pdf1, 170, 510); pdf_lineto($pdf1, 320, 510); pdf_stroke($pdf1); // Location ---> pdf_set_text_pos($pdf1, 70, 480); pdf_show($pdf1, "Location:"); pdf_set_text_pos($pdf1, 170, 480); pdf_show($pdf1, "City:"); pdf_moveto($pdf1, 200, 480); pdf_lineto($pdf1, 300, 480); pdf_stroke($pdf1); pdf_set_text_pos($pdf1, 315, 480); pdf_show($pdf1, "State:"); pdf_moveto($pdf1, 345, 480); pdf_lineto($pdf1, 445, 480); pdf_stroke($pdf1); // Email address ---> pdf_set_text_pos($pdf1, 70, 450); pdf_show($pdf1, "Email Address:"); pdf_moveto($pdf1, 170, 450); pdf_lineto($pdf1, 400, 450); pdf_stroke($pdf1); // comment ---> pdf_set_text_pos($pdf1, 70, 420); pdf_show($pdf1, "Please share your personal interest:"); pdf_rect($pdf1, 70, 200, 480, 200); pdf_stroke($pdf1); // mail to ---> pdf_set_text_pos($pdf1, 70, 90); pdf_show($pdf1, "Send this application to:"); pdf_set_text_pos($pdf1, 200, 70); pdf_show($pdf1, "CheckMeOut Club"); pdf_set_text_pos($pdf1, 200, 55); pdf_show($pdf1, "CS Department, UNR"); pdf_set_text_pos($pdf1, 200, 40); pdf_show($pdf1, "Reno, NV, 89557"); pdf_end_page($pdf1); pdf_close($pdf1); fclose($fp); ?>
Testing PDF Capability

Testing GD Graphic