IE
<p>This is some <strong>sample text</strong>. You are using <a href="http://www.fckeditor.net/">FCKeditor</a>.</p> <p> </p> <div style="z-index: 1; position: absolute; top: 89px; left: 50px;" id="Layer1"><img src="/_userfiles/image/Eagle.jpg" style="width: 335px; height: 247px; top: 96px; left: 242px;" alt="" /></div>

Re: drag image / table to absolute position within editor (IE)
Jim
In my customconfig.js file - I added:
FCKConfig.Plugins.Add('AbsoluteImage');I created a new dir 'AbsoluteImage' under plugins, with the file 'fckplugin.js' and the code below:
// BEGIN CODE // ##### Defining a custom context menu entry. // ## 1. Define the command to be executed when selecting the context menu item. var FCKAbsoluteImage = new Object() ; FCKAbsoluteImage.Name = 'AbsoluteImage' ; // Globals for object Command Identifiers. Used with execCommand, queryCommand[Enabled|State|Supported|Value] var CMD_ABSOLUTEPOSITION = 'AbsolutePosition'; var CMD_2DPOSITION = '2D-Position'; var CMD_LIVERESIZE = 'LiveResize'; // Initialization any document level / global wide options - this will be called after the document init has completed. FCKAbsoluteImage.Init = function(sender, status) { if ( FCKBrowserInfo.IsIE ) { if ( status == FCK_STATUS_COMPLETE ) { /* Causes the Editor to update an element's appearance continuously during a resizing or moving operation, rather than updating only at the completion of the move or resize. */ sender.EditorDocument.execCommand(CMD_LIVERESIZE, true, true); } } } // This is the standard function used to execute the command (called when clicking in the context menu item). FCKAbsoluteImage.Execute = function() { // This command is called only when an image element is selected (IMG). var oRange = FCK.EditorDocument.selection.createRange() ; var state = oRange.queryCommandValue(CMD_ABSOLUTEPOSITION); if (state) oRange.execCommand(CMD_ABSOLUTEPOSITION,false,false); else { oRange.execCommand(CMD_ABSOLUTEPOSITION,false,true); FCKAbsoluteImage.Enable2DPositioning(); } } // Allows absolutely positioned elements to be moved by dragging. FCKAbsoluteImage.Enable2DPositioning = function() { var state = FCK.EditorDocument.queryCommandValue(CMD_2DPOSITION); if (!state) FCK.EditorDocument.execCommand(CMD_2DPOSITION); } // This is the standard function used to retrieve the command state (it could be disabled for some reason). FCKAbsoluteImage.GetState = function() { // Let's make it always enabled. return FCK_TRISTATE_OFF ; } // ## 2. Register our custom command. FCKCommands.RegisterCommand( 'AbsoluteImage', FCKAbsoluteImage ) ; // ## 3. Define the context menu "listener". var oMyContextMenuListener = new Object() ; // This is the standard function called right before sowing the context menu. oMyContextMenuListener.AddItems = function( contextMenu, tag, tagName ) { // Let's show our custom option only for images. if ( tagName == 'IMG' ) { contextMenu.AddSeparator() ; contextMenu.AddItem( 'AbsoluteImage', 'Toggle Absolute Position of Image (Custom)' ) ; } } // ## 4. Register our context menu listener. FCK.ContextMenu.RegisterListener( oMyContextMenuListener ) ; FCK.Events.AttachEvent( 'OnStatusChange', FCKAbsoluteImage.Init); //End CodeRe: drag image / table to absolute position within editor (IE)
Re: drag image / table to absolute position within editor (IE)
If i select any element in the Editor the tagName is undefined inorder to add context menu.
Did you find any new solution for this issue (all browser support ) Thanks and waiting for earlist reply.