#1. using InsertImage #2. Generate custom html using InsertImage.

  •  09-12-2007, 10:39 AM

    #1. using InsertImage #2. Generate custom html using InsertImage.

    Hi..again...

    I have 2 Questions.

    #1. using InsertImage

    I want to Insert Some Function while uploading image using InsertImage.
    That function have generating Thumbnail Image.
    ex) Uploading 3000*2000 px photo, when saving Original Image File,
    I want to generate 4 different size of photo for List Page.

    So, I want to know where I can Insert that function.
    I looked up the InsertImage.aspx, however I couldn't find Saving File Section.

    ex) protected void DoSave <--CuteSoft Code {
     
     // My Custom Function should be inserted
     GenerateThumbnailImage();
    }

    By the way, I'm not asking you to make that Function.
    Let me know, the location(document path,name, Line Number) to Insert my Function.

     
    #2. Generate custom html using InsertImage.

    CuteEditor width : 770 px

    When user upload image larger than 770px.
    They can edit Image Resize using cursor (draging corner of image).

    However, many of users in our site is novice.
    (Actually, in korea many people think "OK. There is a image, It's definitely clickable.
    and, when I click that image, Popup window should be pop up to view Original Size Image."

    Many people is familiar with that UI.

    So, I want to Insert custom html to open popup window while using InsertImage Button.

    for example,

    using CuteEditor, Viewing html when I insert image,
    There is "<img src="somefile.jpg" alt="" style="width:100px;height:75px" />

    I want to add [onClick part] automatically.
    <img src="somefile.jpg" alt="" style="width:100px;height:75px" onClick="viewFullImage('imageName')" />

    Is it possible? If not,
    Is there another way to accomplish that goal?

    I thought there are 2 ways to accomplish that goal.

    When saving CuteEditor contents to DB. auto Generated code should be added.
    Or, Viewing Saved Documents, [onClick part] generated dynamically.

    However, second one, I can't use replace Function. because, saved Image Tag have irregullar pattern.
    Of course, maybe I can use RegEx. But, I'm not used to RegEx Syntax.

     

View Complete Thread