diff options
author | Sashi20 | 2018-07-03 10:04:12 +0530 |
---|---|---|
committer | Sashi20 | 2018-07-03 10:04:12 +0530 |
commit | 5c6f63d4a8da4e5bb8dc32edb0ba54c024f13ab9 (patch) | |
tree | 4d953f24246fd0a8577e25532bd1ade7f544b710 | |
parent | 992d5cb0b85b247f115849d1b9cf158d318d39bb (diff) | |
download | r_textbook_companion-5c6f63d4a8da4e5bb8dc32edb0ba54c024f13ab9.tar.gz r_textbook_companion-5c6f63d4a8da4e5bb8dc32edb0ba54c024f13ab9.tar.bz2 r_textbook_companion-5c6f63d4a8da4e5bb8dc32edb0ba54c024f13ab9.zip |
Modified the downloading file name
-rwxr-xr-x | pdf/generate_pdf.inc | 2 | ||||
-rwxr-xr-x | textbook_companion.module | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/pdf/generate_pdf.inc b/pdf/generate_pdf.inc index 812a579..a01778f 100755 --- a/pdf/generate_pdf.inc +++ b/pdf/generate_pdf.inc @@ -149,7 +149,7 @@ function generate_pdf() //$pdf->Output($certificate_name . '_R_TBC_Certificate.pdf', 'D'); $pdf->SetFont('Arial', 'I', 8); $pdf->SetTextColor(0, 0, 0); - $filename = str_replace(' ', '-', $data3->contributor_name) . '-R_TBC_Certificate.pdf'; + $filename = str_replace(' ', '-', $data3->full_name) . '-R_TBC_Certificate.pdf'; $file = $path . '/pdf/temp_certificate/' . $proposal_id . '_' . $filename; $pdf->Output($file, 'F'); header("Content-Type: application/octet-stream"); diff --git a/textbook_companion.module b/textbook_companion.module index 5771c72..be27817 100755 --- a/textbook_companion.module +++ b/textbook_companion.module @@ -703,10 +703,10 @@ function textbook_companion_menu() $items['textbook-companion/certificate/generate-pdf'] = array( 'title' => 'Download Certificate', 'description' => 'Download Certificate', - 'page callback' => 'drupal_get_form', - 'page arguments' => array( + 'page callback' => 'generate_pdf', + /*'page arguments' => array( 'generate_pdf' - ), + ),*/ 'access arguments' => array( 'generate pdf' ), |