Quick question about settings..

Creating and modifying plugins.
Post Reply
jasonr
Regular
Posts: 14
Joined: Thu Sep 23, 2004 4:57 am

Quick question about settings..

Post by jasonr » Wed Sep 29, 2004 6:49 pm

Im working on my gmail fetcher plugin. and it all works! except..

If you dont have imagemagick installed, or if the attachment isn't a picture, I'm leaving the images on gmail (they give you a gig of storage why not take advantage of it?) and linking to them.

the image will just be part of themessage as an img tag like:

Code: Select all

<img src="plugins/serendipity_event_gmailfetcher/getgmailimage.php?a=1&m=askdjasldkj&f=Foo.jpg">


Since I obviously DON'T want to pass the gmail username and password as paramaters to getgmailimage I'll need access to serendipity settings for gmail username and password (which my gmailfetcher plugin sets correctly) outside of the serendipity framework. Whats the easiest way to accomplish this? What do I need to include, and what functions do I need to call to initialize the $this->getconfig framework?

Does this make any sense?

Also should popfetcher check if imagemagick is installed before calling serendipity_makeThumbnail?

-Jason

tomsommer
Core Developer
Posts: 240
Joined: Tue Sep 02, 2003 6:43 pm
Location: Denmark
Contact:

Post by tomsommer » Sun Oct 03, 2004 1:15 am

Yes, you should check getConfig(), have a look at the other plugins to see how it is done, basically you need to open a property bag inside the plugin
Tom Sommer (Serendipity Core Developer)
http://blog.dreamcoder.dk

Post Reply