Pixelpost

Authentic Photoblog Flavour


Go Back   Pixelpost Forum > DEVELOPMENT > Addons

Post Reply
 
Thread Tools
  #1  
Old 08-18-2005, 11:23 PM
ibejo Offline
pp veteran
 
Join Date: Jun 2005
Location: Florida
Posts: 68
Send a message via Yahoo to ibejo
Requires question for addon

My new addon requires that exifer be included - which is automatically loaded in the index.php page - problem is, when it is loaded in the addons section of the admin suite, I get an error, because exifer is not included by default by the admin suite. See the problem?

I tried to use the require_once function, which I thought would have loaded exifer only if it wasnt loaded by index.php, and thus would work in the admin suite's addon tab. Guess not.....


Fatal error: Call to undefined function: read_exif_data_raw() in D:\inetpub\ibejo\gallery2\addons\fancyarchive.php on line 265

If I include the line require or require once, I get an error in the index.php parsing, but it works fine in the admin suite.....excellent.

Any thoughts?
__________________
James
ColorBlind Photography
http://www.colorblindphotography.com
Reply With Quote
  #2  
Old 08-19-2005, 05:30 AM
raminia's Avatar
raminia+ Offline
Team Pixelpost
 
Join Date: Jan 2005
Location: FL, US
Posts: 3,706
Send a message via Yahoo to raminia
use if (function_exists('functioname')) to check if the function exists or not. if it was not present define it with require_once.
check php manual for function_exists()

did you check my portfolio addon at last?
__________________
Photoblog: http://pblog.raminia.com Powered by Pixelpost 1.7
Reply With Quote
  #3  
Old 08-19-2005, 05:15 PM
ibejo Offline
pp veteran
 
Join Date: Jun 2005
Location: Florida
Posts: 68
Send a message via Yahoo to ibejo
That did the trick. Excellent! Thanks
__________________
James
ColorBlind Photography
http://www.colorblindphotography.com
Reply With Quote
Post Reply


Thread Tools




All times are GMT. The time now is 12:49 AM.

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd. | Style Design: d3 designs