3 of 3
3
New plugin : IMG Tag Modifier - to modify inline image tags
Posted: 30 June 2008 08:07 AM   [ Ignore ]   [ # 37 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  231
Joined  07-09-2006

ok, look forward to a solution!

btw: i’ve nominated www.scienceofthetime.com for EE site gallery/interview. I’ve mentioned the use of your plugin here!

 Signature 

Erwin van Lun
Marketeer on a Mission

Profile
 
 
Posted: 01 July 2008 04:24 PM   [ Ignore ]   [ # 38 ]  
Grad Student
Rank
Total Posts:  64
Joined  09-12-2005

Hi,

Thank you for mentioning my little plugin wink

I was looking at what might be causing this division by zero problem and found the bug causing it.  I have fixed it and you can download the updated plugin from the site.

The problem did not have anything to do with the images being from an external domain. The problem occurred in the calculation routine that automatically figured out image height or with if only one of the two was given.

If you want to create thumbnails of images on a remote server I think you have to fiddle with this part of the phpThumb config (not sure though if that is enough):

// * Off-server Thumbnailing Configuration:
$PHPTHUMB_CONFIG['nohotlink_enabled']           = false;                                    // If false will allow thumbnailing from any source domain
$PHPTHUMB_CONFIG['nohotlink_valid_domains']     = array(@$_SERVER['HTTP_HOST']);            // This is the list of domains for which thumbnails are allowed to be created. Note: domain only, do not include port numbers. The default value of the current domain should be fine in most cases, but if neccesary you can add more domains in here, in the format "www.example.com"
$PHPTHUMB_CONFIG['nohotlink_erase_image']       = true;                                     // if true thumbnail is covered up with $PHPTHUMB_CONFIG['nohotlink_fill_color'] before text is applied, if false text is written over top of thumbnail
$PHPTHUMB_CONFIG['nohotlink_text_message']      = 'Off-server thumbnailing is not allowed'; // text of error message

Best,
Sami

 Signature 

Samuel Jonasson / trikk.is

Profile
 
 
Posted: 04 July 2008 05:51 AM   [ Ignore ]   [ # 39 ]  
Summer Student
Total Posts:  30
Joined  02-10-2008

What a great plugin! Almost everything works as expected, but i only can’t get “align” to work. Whatever i try it’s not aligning. Am i doing something wrong or is there an error in the plugin. This is my code:

{exp:shj_imgmodifier phpthumb=“true” phpthumb_path=”../phptumb/phpThumb.php” phpthumb_attributes=“q=50&zc=1” clear=“true” align=“right” width=“100” height=“100”}

{body}


{/exp:shj_imgmodifier}

Thanks in advance!

UPDATE: That was easy: Add under line 156
      $attributeList[“align”] = $this->ppAlign;

Profile
 
 
Posted: 07 July 2008 04:01 AM   [ Ignore ]   [ # 40 ]  
Grad Student
Rank
Total Posts:  64
Joined  09-12-2005

Hi,

thank you for pointing out this error.  I have updated the plugin with your correction.

Best,
Sammi

 Signature 

Samuel Jonasson / trikk.is

Profile
 
 
Posted: 16 August 2008 03:09 AM   [ Ignore ]   [ # 41 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  170
Joined  10-16-2007

Hey Sambo

I’m having problems getting the plugin to work. I’m getting an error when using the exact same code as I’m using on another project, which is working fine.

Template:

{exp:shj_imgmodifier phpthumb="true" phpthumb_path="/images/thumb/phpThumb.php" phpthumb_attributes="q=50&zc=1" width="40" height="40" lightbox="true"}
{nyheter_bild}
{
/exp:shj_imgmodifier}

Error:
Fatal error: Call to undefined function: array_combine() in /home/evntyr/www.eventyr.se/eventsinside/plugins/pi.shj_imgmodifier.php on line 98”

Using the latest version of the plugin, downloaded today.

Tnx/Takk

 Signature 

André | Sweden
. pushloop.se

Profile
 
 
Posted: 24 August 2008 05:29 AM   [ Ignore ]   [ # 42 ]  
Grad Student
Rank
Total Posts:  64
Joined  09-12-2005

Hi,

I find it very strange that you are getting this error because in the latest code there is no array_combine method.  I had to create a new method called array_combine_php4 because array_combine was not available in PHP4.

I bet your other site is running on a PHP 5 server - and therefor working.

Please try to download the latest source code again and verify that lines 100 and 185 are using array_combine_php4.

Best,
Sambo

 Signature 

Samuel Jonasson / trikk.is

Profile
 
 
   
3 of 3
3
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 1149, on July 16, 2007 09:33 AM
Total Registered Members: 65096 Total Logged-in Users: 56
Total Topics: 82243 Total Anonymous Users: 38
Total Replies: 442010 Total Guests: 288
Total Posts: 524253    
Members ( View Memberlist )