Coder Social home page Coder Social logo

kademi / keditor Goto Github PK

View Code? Open in Web Editor NEW
318.0 58.0 154.0 13.52 MB

KEditor is a jQuery plugin which provides a content editor with drag n drop, configurable contents

Home Page: http://kademi.github.io/keditor/

License: MIT License

JavaScript 83.41% HTML 0.09% Less 16.50%
keditor content-editor jquery bootstrap fontawesome content-builder drag-and-drop

keditor's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

keditor's Issues

idea: draggable columns?

I came across this solutions to drag and change columns widths, maybe this can be very handy and easy to intergrate. (I am not a js specialist -sorry).

http://jsfiddle.net/onigetoc/ag4mgpbs/

If you also take note of the viewport (like the editor is viewed in an resizable iframe) this might be very handy solution to resize columns for small, medium and large views.
And create something very userfriendly like http://shoelace.io

Example of using textarea with Keditor

Just stumbled across Keditor again and really like the way it is coming along, great job.

Currently using CKEditor in classroom project and have setup using textarea and some PHP to save the textarea content. I will note this is for learning in classroom only and we are not worried about security.

I had seen in closed issue that Keditor now support textareas. We have been struggling for hours attempting to get Keditor working with textarea and hoping for some input.

Our PHP looks like this:

` <?php

$filename = 'Data/test.inc';

if(file_exists($filename)){

	if(isset($_POST['write'])){

		$data = $_POST['content'];
		if($data != ''){
			$handle = fopen($filename, 'w') or die('Cannot open file:  '.$filename); 
			fwrite($handle, $data);
		} else 	{
			echo "This field must contain content...";
		}
	}
}
else{
	echo "ERROR!";
}
?>`

With save button like this:

<input class="btn btn-primary btn-lg raised" id="load" type="submit" name="write" id="write" value="SAVE" />

And textarea is:

<textarea style="width:100%;" class="input-block-level" name="content" id="editor1"><?php include Data/test.inc'; ?></textarea>

Any input will be greatly appreciated. Really like to start using Keditor simply because off the drag and drop.

Cheers!

KEditor to support drag and drop layout components and content components

Users would like the flexibility to arrange the layout of their pages and emails, and this should ideally include dynamic components which may or may not have editable content or properties.

To do this we would have 2 different kinds of snippets:

layout row. A row with fixed number of columns of fixed widths. Is not editable by itself. It can be deleted or moved up or down. A page is a series of layout rows
content component. The main one is a html section, which allows editing of arbitrary html in a wysiwig. We would also have dynamic, use case specific components like an unsubscribe link (for emails), newsletter signup form (for web pages), a gallery component for displaying images, etc
Ideally a content component can be dragged to different locations within the page, eg from one row to another

iframe mode

Hi team,
i'm on MAC (Yosemite 10.10.5) and firefox version 51.0.1,
when iframe is true, nothing are displayed, iframe body is empty, i test on blank html example file.
where can i find a online example ?
thank you

Component settings doesnt appear sometimes

Steps to reproduce:

Click edit page
Hide snippets toolbar
Click any component settings gear, it works. then hide settings toolbar
Click gear button again, not showing toolbar
Click gear once again, toolbar shows

Support multiple types of component

Instead of using CKEditor for editing content of all components. I want to use other things like a dropzone for upload and edit a image or just setting panel in sidebar for configuration of a button.

Standalone CSS/LESS file

In some case, I dont want to use Bootstrap CSS, I want use my own stylesheet, so I need standalone version style of Keditor.

Support data-* attribute into snippets

Example:

<div data-type="component-text" data-preview="snippets/default/preview/heading_2.png" data-category-id="cate01" data-product-id="prod01" data-store-id="store01">
    <h2>Heading text 2</h2>
    <p>Body text</p>
    <div data-dynamic-href="snippets/default/_dynamic_content.html"></div>
</div>

Instead of getting only data-type attribute, should store all data-* attribute

Dynamic content remove data-dynamic-href div

Is it possible that when dynamic content is added to the contentarea it deletes the line where the dynamic content comes from?

To remove the div containing the data-dynamic-href

I do not know if it's clear, sorry, my English

Keditor in angular js

Hey,
I appreciate this plugin very much because of it's extra ordinary beauty. Can you please provide me link of angular directive for this plugin?
Appreciations.

KEditor

How to set content of KEditor using textarea

getContent does not work

Hello,
I would like to get the content but it doesn't work, i use this as explain in doc.
$('#id').keditor('getContent');
jquery return Uncaught TypeError: jQuery(...).keditor is not a function
how to resolve this ?
thank you

pre-designed snippet

What is the best way to add a pre-designed snippet with columns+editable components?

For example: I want a 2 column row, with on the left an image block, on the right a rich-text.
When I add this into the snippets, the components won't be editable anymore. (missing an ID i guess?)

Dynamic components

Consider this use case: I would like to develop a products list component for use with EDM's. This component should show a list of 3 or 4 products which meet the preferences of the user the EDM is being sent to.

Ideally, when i add this component to an EDM using keditor it will generate a list of products so i can see how it looks. But of course i dont want that list of products to be saved into the source of the EDM, i only want the component itself.

So here is how i think we can do this in KEditor

  • component snippets can have a data attribute of dynamic-href on any div in the component. When a such component is added keditor will call out to that href, passing all data params on the component as request parameters. The response will be inserted inside the div with the dynamic-href attribute.
  • when keditor displays content previously saved, any components with that attribute will have the same process executed
  • when keditor saves content, any divs with the dynamic-href attribute will be cleared

The server will support the editor by:

  • having a url for each component, eg /components/productList?numProducts=4&category=fashion
  • when called, this will evaluate the component template and return the html snippet

The persisted content will be used to dynamically generate content when the EDM is sent. Our server will read and parse the content, and then look for dynamic sections and replaced them with content generated by the component template. Note that the component template is never accessed by KEditor, and is not available for editing by content authors.

Example - persisted component

<div data-type="container" data-preview="/static/keditor/snippets/default/preview/row_6_6.png">
<h1>Your products</h1>
<div data-dynamic-href="/components/productList" data-num-products="3" data-category="fashion">
</div>
</div>

When this component is added to the editor, KEditor will load content from /components/productList. This might result in this:

<div data-type="container" data-preview="/static/keditor/snippets/default/preview/row_6_6.png">
<h1>Your products</h1>
<div data-dynamic-href="/components/productList" data-num-products="3" data-category="fashion">
<img src="product1.png"/>
<img src="product2.png"/>
<img src="product3.png"/>
</div>
</div>

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.