HTML editor and image upload to server - asp.net

In asp.net, when we work with any html editor, I often include images and text. How will images upload to a specific folder in the server and be saved as a relative path in the db. I Need this concept for a CMS.

I was using CKEditor first but it was found a bit difficult to work with asp.net. So I moved to obout editor. I think your problem can be solved with obout html editor. check this link, obout.com - Html Editor - Image upload

Why do you need to store the image's relative path in the DB ? As there is no need, because the content html is saved in the DB and when you the retrieve that content that particular image will be shown in the content.
As far as I have used CK Editor, there is some setting required in the config file to set the path where the images are stored when user adds images in content.

Related

how to set image and text scroll in adobe capivate 9

Can anyone please help me. Am using adobe captivate 9. I have a content with image that exceeds the slide spacing, i want to set this content within the page using scroll. I have tried using text-scroll widget but i cant add images to it.
Put the image into an MS Word document and save it as an HTML web page. The result will be an HTML file and folder named "[file name]_files" in whichever folder you saved it to.
Select both the HTML file and the folder, right click, and choose Send to -> Compressed (zipped) folder in the context menu.
Dragging that ZIP folder directly onto your Captivate slide will create scrolling HTML Web Object based on the formatting of the MS Word file. It will show up in your Library in the "Web" folder.
Unfortunately, this is a feature that is missing from Captivate. The best solution I've found is to make an html file that includes the text and points to the image, then zip and import as an HTML5 Animation.

Get TinyMCE 4.3 Image Tools to save images as regular image files

The new TinyMCE 4.3 Image Tools (eg when cropping) saves images as blob data instead of image files in a directory. the edited mage url is like
blob:http://www.example.com/f2953aa1-e64f-49e1-a6e3-a283986663bf
I want to upload the image file to a specific folder and then use it as regular image referance / path.
Note
The question I am going to put is similar to Image edit issue. but the answer to this question is not working. I also tried http://archive.tinymce.com/forum/viewtopic.php?id=35740 solution but not working because it produces always same name image name.
The basic process is that TinyMCE will create a separate HTTP POST for each image that you modify with the image editor. It will send that image to a URL of your choosing (via HTTP POST) based on the setting of the images_upload_url option in your init.
The image handler at the URL referenced in the images_upload_url (which you have to create) has to do whatever needs to be done to "store" the image in your application. That could mean something like:
Store the item in a folder on your web server
Store the item in a database
Store the item in an asset management system
...regardless of where you choose to store the image your image handler needs to return a single line of JSON telling TinyMCE the new location of the image. As referenced in the TinyMCE documentation this might look like:
{ location : '/uploaded/image/path/image.png' }
TinyMCE will then update the image's src attribute to the value you return. If you use the images_upload_base_path setting in the init that will be prepended to the returned location. The TinyMCE page has more details on all of this:
https://www.tinymce.com/docs/advanced/handle-async-image-uploads/
The net here is that TinyMCE knows when an embedded image exists in your content but it can't possibly know what to do with that image in the context of your application so that job (the "image handler") is something you must create.

Regarding CMS concept and html editor in asp.net

we create page through html editor in CMS project. when we design pages then we can add image through html editor. so i just want to know how automatically image path will be stored in my database table and image will upload in proper forlder. suppose i work with fckeditor.
fckeditor can automatically upload images in right folder and how images path will be saved in right table. do i need to parse the html and extract images and replace the image path with properly and atlast upload images programatically to right folder on server before saving the html to databased. please discuss this in detail because i never work with CMS before.
what is the best html editor for CMS and asp.net project.
also tell me what the best free open source CMS for asp.net.
thanks.

How to display image into each recent post in drupal front page?

I am very new to drupal. As I have seen many of drupal free theme can show image in the recent post on the first page of drupal
I tried searching some ways to do but seem my keyword search was mismatched.
If you don't want to install any modules, you can simply use a standard HTML <img> tag to put an image in your node body (make sure your selected Input Format allows for the use of that tag). You can then use FTP to upload the linked images to your /sites/default/files directory.
The modules mentioned by Nikit (especially IMCE) can ease this process greatly. A the very minimum, IMCE allows you to upload files to your server without using FTP and adds a handy "insert image" link after your "body" input fields. Clicking that link uploads your image and then generates the <img> code for you.
You can simply style it in node body (wysiwyg + imce can help to quickly upload image and style it).
But recommend to you use image or cck + imagefield, and theme it via node-{CONTENTTYPE}.tpl.php
Little help here: http://www.hankpalan.com/blog/drupal-themes/theming-node-drupalthe-easy-way
But recommend to learn theming in drupal.
If you don't want to use HTML or change any PHP files then use the admin console.
http://drupal.org/node/1047760

Adding images into blocks html

I've added some html code in my Blocks content and enabled Full HTML filter.
I've used relative paths for my images, such as "sites/all/themes/zen/zen/image.png"
I guess this is not correct because I need to change my paths depending on I'm in the home page or "node/id" page.
I guess I cannot use PHP inside blocks, thus I cannot use $base_url... how can add images path with only html ?
thanks
The previous answers provide a part of the solution, but here's a fuller scoop:
Hand-written HTML
If your site lives at example.com (i.e. it's the "root" site), then adding a front slash to your relative path will solve the issue, as others have suggested:
<img src="/sites/all/themes/zen/zen/image.png">
However, if your site lives at example.com/my-drupal-site, then you'll need to write it like this:
<img src="/my-drupal-site/sites/all/themes/zen/zen/image.png">
It really is better if you can use PHP to determine the appropriate path. If you're calling an image from a theme, you can use the Drupal function drupal_get_path to get the path like this:
$img_path = drupal_get_path('theme', 'zen') . '/zen/image.png';
And then you could be really Drupaly about it and use the theme_image function to generate the HTML for the image:
$img = theme('image', $img_path, 'My Image - Alt Text', 'My Image - Title Text');
Where $img now holds the HTML for the <img> tag and its src, alt, and title attributes. See the API documentation for drupal_get_path and theme_image for more information.
Point-and-click Solution
As jeffreymb points out, your easiest bet is to use a combination of a WYSIWYG editor and a built-in file handling module called IMCE to gloss over all these details for you. If you don't have access to the "PHP code" input format, this is the best solution.
So, steps:
Install the WYSIWYG module, as well as a WYSIWYG editor (I suggest CKEditor).
Install the IMCE module and IMCE WYSIWYG Bridge module, and enable the IMCE button for your WYSIWYG editor in its configuration settings for available Buttons.
See this post for a little more detail on that setup process, and make sure to read the documentation that the WYSIWYG module displays on its configuration page.
Once you have IMCE installed and integrated with your WYSIWYG, when you click the "Image" button in your WYSIWYG toolbar, your normal dialog should appear but with a new little icon to open the IMCE file browser. This file browser allows you to browse your files folder for images or to upload new files. It also supports a modicum of image manipulation, and will automatically generate the necessary HTML once you've selected an image.
I would recommend using the Pathologic module for this case. It is a filter that you can add to your input formats to convert relative URLs like that into proper URLs using your site's base URL. Plus it's useful if you have images in your RSS content as sites that re-publish the content (like feed aggregators, etc.) have the link to the full URL.
I use the CKeditor and IMCE modules to do this on my sites.
It is very user friendly and not that hard to set up.
Instead of the relative path, use the absolute path. So it'd be:
<img src="/sites/all/themes/zen/zen/image.png">
Note the slash at the beginning. The slash should be the only thing you need to do to convert your existing relative paths to absolute ones for use in straight HTML.
If you start your image paths with a slash ("/sites/all/themes/zen/zen/image.png") this will always be relative to your drupal root directory.
You could also simply select "PHP code" as the Input format, and use $base_url as you say.
I does this with cck blocks . The cck blocks is drupal module,it can put drupal fields into blocks

Resources