Hi,
I'm using Pagesetter 6.3.0.0 with PostNuke 0.764 and both are working perfectly. I have successfully created a Publication type and associated html template that allows and displays the upload of images via a field of name "topLevelCoursesSlideshowImageUpload" and type "imageupload".
Within the template I can successfully view instances of the uploaded images using the smarty code:
<img src="<!--[$topLevelCoursesSlideshowImageUpload.url]-->" />
My problem is that I would like to display the uploaded image using PHP and an HTML
![]()
tag on a custom.php page that is not a Pagesetter template.
I notice that uploaded images are stored on the server in .dat format in the directory specified in Configuration > Document upload directory. I can collect the information relating to the uploaded image from the database. For example, an uploaded JPEG image (called 08_children_in_need.jpg) might have the following info stored in the DB:
image/jpeg|53573|50x1x1xtopLevelCoursesSlideshowImageUpload.dat|08_children_in_need.jpg
So I?m wondering how I can use PHP to display the image that is stored as 50x1x1xtopLevelCoursesSlideshowImageUpload.dat. I?ve looked through some of the Pagesetter files (/modules/Pagesetter/pnimageapi.php) and it looks like the PHP imagecreatefromjpeg() function is used along with GD functions but I cannot fully understand what is happening as it's so closely tied to Pagesetter and PostNuke. Does anyone have any instructions on how I can achieve this?
Thanks
Robbie
edited by: robbiethompson, Mar 13, 2009 - 10:31 AM