Etomite Community Forums: Xinha ImageManager - now with valid css floats instead of img align - Etomite Community Forums

Jump to content


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Xinha ImageManager - now with valid css floats instead of img align

#1 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 22 June 2009 - 03:51 PM

I finally solved this problem... I have modified the image manager to insert class="imgleft" or class="imgright" into the img tag instead of the old, depreciated align="right" or align="left".

Etomite 1.1 Xinha ImageManager plugin modification:

This modification makes ImageManage use valid css for alignment like class="imgright" instead of align="right".
Also removes padding, border, and other depreciated controls from ImageManager popup.
Also contains the "what you see is what you mean" CSS that makes xinha show you the block-level elements, as well as the proper image floating CSS that updates the image position right in the editor.

This mod only includes the files needed for the update and assumes you aleready have Etomite 1.1 or greater and are using the latest release of Xinha for Etomite.

To install:
Extract contents of zip file into /manager/media/xinha

To activate:
1) Assuming xinha is already enabled, enable "Stylist" in the main Etomite configuration's "Interface & editor settings" tab, and change the stylist css file to /manager/media/xinha/xinha.css
2) Save the Etomite config.
3) Next, go back into the Etomite config and turn off stylist. (You need to do this because you don't want the actual stylist "addon" as it's worthless, you just want to tell xinha to use the css file in it's display.)
4) Save the Etomite config again.
5)In your website's main CSS, you'll need to add a couple of styles, here's what I use and recommend:

img.imgright{float: right; clear: both; margin:0 0 .5em .5em}
img.imgleft{float: left; clear: both; margin:0 .5em .5em 0}


Mod created by Ian Smith of n-vent.com

Attached File(s)


This post has been edited by cathode: 02 July 2009 - 06:48 PM


#2 User is offline   Ralph 

  • Etomite Administrator
  • Icon
  • Group: Admin
  • Posts: 6,369
  • Joined: 01-July 04
  • Gender:Male
  • Location:Jamestown, NY USA
  • Interests:Computers, Camping, Hiking, Aviation

Posted 22 June 2009 - 06:19 PM

Yeah, even in XHTML mode Xinha uses lax XHTML standards... Very few WYSIWYG editors do XHTML Strict... <_<

#3 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 22 June 2009 - 10:11 PM

View PostRalph, on Jun 22 2009, 02:19 PM, said:

Yeah, even in XHTML mode Xinha uses lax XHTML standards... Very few WYSIWYG editors do XHTML Strict... <_<


This one has been bugging me for a long time. Now with classes, you can add padding, clear the floats, etc. based on the image class... it's so nice. I no longer have to force images over to one side to make it easier on my clients, they can choose to float it to either side and I can provide the CSS to make it look good either way. I've also updated my "WYSIWYM" xinha css to match.

I also made the Width and Height tags go away, and removed the border, padding, color, etc controls that were all depreciated.

#4 User is offline   darren 

  • Likes Etomite Forums!
  • PipPip
  • Group: Member
  • Posts: 245
  • Joined: 23-May 07
  • Gender:Male
  • Location:Williams Bay
  • Interests:My Kids
    Flyfishing
    4-Wheeling
    Web Design

Posted 23 June 2009 - 05:32 PM

View Postcathode, on Jun 22 2009, 03:11 PM, said:

This one has been bugging me for a long time. Now with classes, you can add padding, clear the floats, etc. based on the image class... it's so nice. I no longer have to force images over to one side to make it easier on my clients, they can choose to float it to either side and I can provide the CSS to make it look good either way. I've also updated my "WYSIWYM" xinha css to match.

I also made the Width and Height tags go away, and removed the border, padding, color, etc controls that were all depreciated.


I'll try it out - it's bugged me too.

#5 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 24 June 2009 - 04:06 PM

View Postdarren, on Jun 23 2009, 01:32 PM, said:

I'll try it out - it's bugged me too.


Darren, I've updated the original post with the info and files...

#6 User is offline   darren 

  • Likes Etomite Forums!
  • PipPip
  • Group: Member
  • Posts: 245
  • Joined: 23-May 07
  • Gender:Male
  • Location:Williams Bay
  • Interests:My Kids
    Flyfishing
    4-Wheeling
    Web Design

Posted 24 June 2009 - 07:51 PM

thanks,
i'll try it on a new install later tonight.

#7 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 25 June 2009 - 04:13 AM

View Postdarren, on Jun 24 2009, 03:51 PM, said:

thanks,
i'll try it on a new install later tonight.


Darren,
I just ran into a case where the xinha editor wouldn't load in IE7/8 - let me sort it out before you have a go at it... :)

#8 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 25 June 2009 - 02:15 PM

View Postcathode, on Jun 25 2009, 12:13 AM, said:

Darren,
I just ran into a case where the xinha editor wouldn't load in IE7/8 - let me sort it out before you have a go at it... :)


I fixed this last night- will post update today...

#9 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 02 July 2009 - 06:45 PM

Original post has been updated to include all working files and instruction.

This post has been edited by cathode: 02 July 2009 - 06:49 PM


#10 User is offline   darren 

  • Likes Etomite Forums!
  • PipPip
  • Group: Member
  • Posts: 245
  • Joined: 23-May 07
  • Gender:Male
  • Location:Williams Bay
  • Interests:My Kids
    Flyfishing
    4-Wheeling
    Web Design

Posted 21 July 2009 - 11:29 PM

Ian,
do you still have thumbnails of the images with this mod? For images uploaded with ImageManager and the file manager, my thumbnails show:

src="backend.php?__plugin=ImageManager&__function=thumbs&img=%2Fboats%2F1b.jpg"

for the image assets/images/boats/1b.jpg. Is this correct? on my personal server those sources are more like:

src="/assets/images/boats/.thumbs/.1b.jpg"



uhhhmmm hold on this is the same server i'm having multiple issues with and don't think it has GD.. which is probably required to create the thumbnails..... which explains why all my .thumbs directories are empty. :angry: another email to send. could you confirm for me, though, that backend.php is trying to use GD? I'm not getting any visible errors, even poking around in the rendered source.

#11 User is offline   cathode 

  • Etomite Staff
  • Icon
  • Group: Staff
  • Posts: 648
  • Joined: 21-November 05
  • Location:Indiana, U.S.

Posted 23 July 2009 - 06:33 PM

View Postdarren, on 21 July 2009 - 11:29 PM, said:

Ian,
do you still have thumbnails of the images with this mod? For images uploaded with ImageManager and the file manager, my thumbnails show:

src="backend.php?__plugin=ImageManager&__function=thumbs&img=%2Fboats%2F1b.jpg"

for the image assets/images/boats/1b.jpg. Is this correct? on my personal server those sources are more like:

src="/assets/images/boats/.thumbs/.1b.jpg"

uhhhmmm hold on this is the same server i'm having multiple issues with and don't think it has GD.. which is probably required to create the thumbnails..... which explains why all my .thumbs directories are empty. :angry: another email to send. could you confirm for me, though, that backend.php is trying to use GD? I'm not getting any visible errors, even poking around in the rendered source.


I still get thumbnails with this mod and no errors (on a server set up properly, of course!)

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users