Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
We've all seen in-browser rich text editors, which allow you to edit colored/styled text in a WYSIWYG manner. But what about code editors, which automatically highlight code based on language rules as you type? Think Eclipse in a textarea (but without the refactoring support).
Do such things exist? I imagine scaling would be a problem - larger files would be difficult to edit efficiently.
CodeMirror comes with support for 60+ languages, and addons that implement more advanced editing functionality (autocompletion, code folding, configurable key bindings, search & replace, linter integration etc.). A rich programming API and a CSS theming system are available for customizing CodeMirror, and extending it with new functionality.
It has been developed since early 2007, has a Wikipedia page, and is being used in a wide number of popular open source projects (Joomla, Firebug etc.).
Ace. They don't use an iFrame.
The editArea javascript library does a pretty good job. It's used by the OpenCMS content management system as it's in-place JSP and JavaScript editor. The colorization gets a bit confused when the file is > 2000 lines or so.
The feature list from their page is:
Easy to integrate, only one script include and one function call
Tab support (allow to write well formated source code)
Search and replace (with regexp)
Customizable real-time syntax highlighting (currently: PHP, CSS, Javascript, Python, HTML, XML, VB, C, CPP, SQL, Pascal, Basic, Brainf*ck)
Auto-indenting new lines
Line numbering
Multilanguage support (currently: Croatian, Danish, English, French, German, Italian, Japanese, Polish, Portuguese)
Full screen mode
Can work in the same environment than "protype" and "mootools"'s like libraries.
Mozilla's Bespin looked very interesting, but the project was discontinued.
you can check out dockPHP StackHive for web development (based on codemirror). Right now it supports HTML/CSS development but I am working on live javascript-ing as well..
Disclaimer : I am the founder at dockPHP :)
Cloud9 looks interesting if you're a JavaScript developer.
Amy Editor is another browser-based editor I've come across today - it looks like it is trying to emulate TextMate in the browser - including Bundles and Snippets - although the project looks like it's likely dead... Homepage/Demo and source on GitHub
This is a sideways suggestion -- but I use the Firefox plugin "It's All Text!" to send my text-areas to for editing -- all good markups,searching, etc.
Of course, this is user-dependent, and can't be easily rolled-out to visitors, if that is your intent.
However, I tend to get irritated by the limitations of in-browser editors, anyway. (The way SO captures my C-k during edits STILL catches me off-guard... [which means I don't edit everything in Emacs...])
Javascript VI, has some bugs but is an interesting idea. VI FTW!
I use codiad. I used it with PHP, js and C. Features:
Support for 40+ languages
Plugin Library
Error checking & notifications
Mutliple user support
Editor screen splitting
LocalStorage redundancy
Advanced searching tools
Smart auto-complete
Real-Time Collaborative editing
Over 20 Syntax color themes
Completely Open-Source
Easily customized source
Runs on your own server
Quick-Download backups
Maximum editor screen space
i18n Language Support
http://codiad.com
Eclipse Orion provides a full-blown Code Edit and a minified Orion Editor. You can see its demo here.
codesandbox.com is an up coming choice for several frameworks.
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 7 years ago.
Improve this question
Is there a well known Open Source license that would allow me to open source some mission critical code in such a way that the community could read it, but that would simultaneously prevent competitors from using it to gain an advantage over us?
I'll give you a bit more context. We are developing quite a complex and serious business analytics tool for which we decided to create our own in house javascript MVC framework. As part of the project we also built a bunch of reusable controls that seamlessly integrate with the framework for things like switches, tables, autocomplete search boxes, navigation controls, etc. (think Cocoa controls or jQuery UI).
We'd like to release the framework itself and the controls to the community for better or worse under the Apache2 license, fairly standard stuff there. However, and this is really what I'm asking, we would also like to show the source of our SaaS analytics app (the one that powers our business and generates revenue) for the purpose of demonstrating how a complex enterprise app can be built on top of our framework, for it to be sort of like a rigorous proof-of-concept/case study/demo. But we don't want competitors to just clone the repo and deploy it on their servers with some rebranding and start stealing our customers. Is there a well known open source license that could facility this type of information sharing for the benefit of the community whilst simultaneously precluding competitors from gaining a competitive advantage from it? (I mean obviously our competitors might learn a thing or two and that's fine, but we want to have legal power in case they blatantly copy parts of our code and use it to compete against us; and the judgement of whether they are copying or not should be at our sole discretion).
I think you should look at the Microsoft Reference Source license..
Microsoft does pretty much what you outlined up there with the .NET library.
But as always with these license questions:
Don't take the word of a bunch of internet strangers - ask a lawyer familiar with the topic before you do anything you might regret.
Also, on a side-note: With all my love for OSS software - Regardless of what your competitors do, the second they have your source they can blatantly copy you (and they will if you are successful enough). And once that has happened you have to spend a pile of money on lawyers trying to get to your rights.
Especially when it's the heart of an operation, I'd label that as "competitive advantage" and not release it to the public. It's your IP, once you give it out to someone anyone can simply take your ideas and write his own app with it - no license in the world can prevent that (besides stupid patents you probably don't have).
So my advice here would be to just wait a bit and see how the MVC lib turns out.
Look at Ruby on Rails. It's been developed as part of Basecamp at 37 Signals, but the Basecamp source code never became public simply because there is no need for that. If the framework is any good people will use it and you'll get organically to sample applications.
Having real world examples is nice, but especially for JavaScript frameworks you should aim to be pretty backend-agnostic - so it shouldn't really matter if you run ASP.NET MVC or Rails or Node on the backend. The logical consequence is that the backend code is of no real interest to your library users.
They can see the library working on your site, that in itself should be enough to show useful usage patterns.
If you take some parts out of your app and show them to users you'll be fine without the risk of lawyering to get to your rights..
No. The purpose of any Open Source license is to give the code to the community to further develop, fork, or use for other purposes. The whole point of having a license is purely to prevent complete theft of code without attribution. If code that is claimed as original appears down the road can be proven to be based on your work, you have sufficient grounds for legal action.
The best way to demonstrate a proof of concept is to take discrete parts of your work as an overall demonstration of the value of the framework.
But, I'm no lawyer so I would suggest that you consult with one before doing anything that might jeopardize your business or your job.
Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I am currently considering to build a single page web app using restful api and put the entire UI logic in javascript on the client side. This design concept has been adopted by twitter and several other web apps.
However, I am wondering how to prevent user from stealing my javascript code, since my app logic is all stored in javascript. Does product like gmail, grooveshark, or twitter not care about this issue? do they not care if people can just replicate their app by copy the javascript? if so, does it not bring a lot of risk to the business?
I hope someone can answer my question as I am figuring out how other people are building their app. and if anyone has similar concern on this issue.
On a pure technical level you can't. Any Javascript code readable by a browser can be read by a developer UserAgent. In fact there are browser addons which allow the user to read the Javascript behind or linked by any web page.
Having said that, you can make hijacking of your Javascript code harder by using Minification. (eg: http://code.google.com/p/minify/)
As previously stated, there are no way to prevent "code stealing". Just remember we are in a world where code isn't valued anymore. It's so easy to build an application that what really matters is the branding around it.
Anyone can build a facebook of it's own, but the real value is the number of users on facebook. I don't believe that company tries to protect their code anymore, they in fact make it easy for you to get it via github or the likes. Talking about their products and the way there are made are more beneficial to them than you think.
Just take a look at twitter bootstrap. The investment they put in that code is well rewarded by all the people building apps on their technology. It reinforce the technical value of their systems.
You can minify/obfuscate your javascript code, making it essentially unreadably.
For example: http://code.google.com/p/minify/
or check this question:
How can I obfuscate (protect) JavaScript?
If your business requirements state that your source must remain a closely guarded secret and you are attempting to make a single webpage that contains all your business logic you have a conflicting design.
No matter how much obfuscation or minification you perform on your client-side code, there is going to be a way (simple browser plugins to firebug can do this) to deobfuscate your code.
There is no such thing as "security through obscurity".
Take a look at:
http://a0.twimg.com/b/1/bundle/phoenix-core-en-201112200936.js
http://a2.twimg.com/b/1/bundle/phoenix-more-en-201112200936.js
And consider how hard it is to extract useful information from the code.
This is some of the javascript code that your browser downloads when you visit a page on Twitter. This code has been minified (to make it more efficient to move around the network) and obfuscated (to make it harder to read). These techniques make it much harder for the casual user to re-use or reverse-engineer your code. Tools for doing this a widespread and include: Google's Closure Compiler, Yahoo's YUI Compressor, and others.
No such tool is perfect, however. They won't stop a determined hacker -- of course, a determined hacker could probably just reproduce the functionality, which leads to your best defense, IMHO -- which is your copyright.
When you create software, that software is protected by copyright law, in much the same way as other works are (see Software Copyright). If you create a hot new javascript app, and someone rips the code and puts it in their app, you have grounds for legal action. However, the law doesn't just prevent them from using it exactly "as is". From Wikipedia:
There is a certain amount of work that goes into making copyright
successful and just as with other works, copyright for computer
programs prohibits not only literal copying, but also copying of
"nonliteral elements", such as program structure and design.
This can be very valuable protection.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
We're using GWO (Google Website Optimizer) now. The multivariate and A/B testing is exactly what we need and works great from the perspective of showing the variations to the users. However, we have several issues that make me want to use a different tool:
Statistics are inaccurate compared to Google Analytics, so we now disregard them and have to manually check
Previews typically don't work
Cannot have dynamic content in variations (I know about variation_content, but I cannot get it to work and nobody in google's forums has been able to help.. I suspect google may have stopped supporting this)
Documentation is poor, there's a techie guide with well-known inaccuracies which haven't been fixed in well over a year.
The html/javascript code we modify our multivariate test sections with is ugly and makes our pages fail standards validation
Only 8 test sections per page, problem there is we want to allow our marketeers the ability to do everything they need from within GWO, but now they need to mark off which test sections they want/don't want in our custom tool
Different experiment key for every test, again it makes marketeers need to work with our code sometimes
Is there a good tool like GWO that works with Google Analytics (which I love)?
UPDATE: We went with Optimizely and have generally been happy. However, it can be difficult to work with because it does a little too much for you. You edit your webpage directly from their UI, but of course that isn't always easy or even possible. Particularly when Javascript is involved. Our UI often gets screwed up in the process. I liked GWO's approach to this in that the developer sections off the code and the marketer can then fill in those sections with variables the developer allows for. To me that's ideal, except that GWO, of course, doesn't actually work.
There's a very similar competitor to Optimizely called Visual Website Optimizer. Also looks very nice, but has the same issue I describe above.
Is there a GWO that works?
You should take a look at Optimizely.
Doesn't require creating invalid code.
Easy to create variations on the fly, though only A/B, not MVT.
Simple WYSIWYG test design, on the fly.
Real time data.
Retroactive goals
With regex/head matching for experiments, you can set the experiment to work on dynamic pages.
You can set a Google Analytics custom variable for the experiment that will pass the variation the end user sees as a custom variable. (It even allows you to set what slot you want it to use.)
The test variations are basically just jQuery manipulations of the DOM, so if you know a little jQuery, it's very easy to extend its capabilties even further than the very generous WYSIWYG GUI.
Installation is easy: You only need to include a single script tag, one time, on any experiment or goal page.
I have found Adobe Test&Target to have all the features you need. It is very easy to create experiments, add variations, and conversion goals. You can easily inject JQuery snippets to create new variations, click Save, and the test is running in production.
I have no idea how much it costs, but I'm guessing it is not cheap.
Now Google Website Optimizer killed multivariate testing in new version (Google Analytics Content Experiments) we launched Convert Experiments on Convert.com for people that look for a GWO alternative with MVT
Yes I am Founder of Convert Insights, the company behind this tool...
Dennis
Re your update: I have tried both GWO and Optimizely, and I'd go with Optimizely every time.
You say you wish it worked a little more like GWO - if you want, instead of manipulating the elements of the design using their GUI, you can just redirect each variant to a different URL:
https://help.optimizely.com/hc/en-us/articles/200040675
There are a few other tools which do A/B and MVT. Aren't free, but check them out for yourself: Omniture, Webtrends Optimize, SiteSpect.
Hope this helps!
You can also try VWO. It does MVT as well as A/B testing and is also a good tool. Optimizely is easier to use though so you might want to evaluate both for your scenario.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I have been asked to write an app which screen scrapes info from an intranet web page and presents the certain info from it in a nice easy to view format. The web page is a real mess and requires the user to click on half a dozen icons to discover if an ordered item has arrived or has been receipted. As you can imagine users find this irritating to say the least and it would be nice to have an app anyone can use that lists the state of their orders in a single screen.
Yes I know a better solution would be to re-write the web app but that would involve calling in the vendor and would cost us as small fortune.
Anyway while looking into this I discovered the web page I want to scrape is mostly Javascript (although it doesn't use any AJAX techniques). Does anyone know if a library or program exists which I could feed with the Javascript and which would then spit out the DOM for my app to parse ?
I can pretty much write the app in any language but my preference would be JavaFX just so I could have a play with it.
Thanks for your time.
Ian
You may consider using HTMLunit
It's a java class library made to automate browsing without having to control a browser, and it integrates the Mozilla Rhino Javascript engine to process javascript on the pages it loads. There's also a JRuby wrapper for that, named Celerity. Its javascript support is not really perfect right now, but if your pages don't use many hacks things should work fine the performance should be way better than controlling a browser. Furthermore, you don't have to worry about cookies being persisted after your scraping is over and all the other nasty things connected to controlling a browser (history, autocomplete, temp files etc).
Since you say that no AJAX is used, then all the info is present at the HTML source. The javascript just renders it based on user clicks. So you need to reverse engineer the way the application works, parse the html and the javascript code and extract the useful information. It is strictly business of text parsing - you shouldn't deal with running javascript and producing a new DOM. This would be much more difficult to do.
If AJAX was used, your job would be easier. You could easily find out how the AJAX services work (probably by receiving JSON and XML) and extract the information.
You could consider using a greasemonkey JS. greasemonkey is a very powerful Firefox add on that allows you to run your own script alongside that of specific web sites. This allows you to modify how the web site is displayed, add or remove content. You can even use it to do AJAX style lookups and add dynamic content.
If your tool is for in house use, and users are all happy to use Firefox then this could be a winner.
Regards
I suggest IRobotSoft web scraper. It is a dedicated free software for screen scraping with the best javascript support. You can create and test a robot with its visual interface. You can also embed it into your own application using its ActiveX control and hide the browser window.
I'd go with Perl's Win32::IE::Mechanize which lets you automate Internet Explorer. You should be able to click on icons and extract text while letting MSIE do the annoying tasks of processing all the JS.
I agree with kgiannakakis' answer. I'd be suprised if you couldn't reverse engineer the javascript to identify where the information comes from and then write some simple Python scripts using Urllib2 and the Beautiful Soup library to scrape the same information.
If Python and scraping are a new idea, there's some excellent tutorials available on how to get going.
[Edit] Looks like there's a Python version of mechanize too. Time to re-write some scrapers I developed a while back! :-)
I created a project site2archive that uses phantomJs to render including JS stuff and wget to scrape. phantomJs is based on Webkit, that delivers a similar browsing environment as Safari and Google Chrome.
is using TinyMCE a top choice for WYSIWYG editor on a webpage? What are good alternatives?
some comparison seems to show that TinyMCE is one of the most compatible across browsers:
http://geniisoft.com/showcase.nsf/WebEditors
TinyMCE is a great choice. I've used it in commercial offerings with good results. I'm also looking at FCKEditor for a new project specifically because of the integrated file upload and rumors that it has better XSS protection. Frankly, I'm not sure either one is sufficient to protect against XSS (you may have to supplement with something like http://htmlpurifier.org/ if that is a concern).
I've been using FCKEditor with ASP.NET for years and have found it very easy to customize and configure. It's very stable and the intergrated upload feature is a plus. http://www.fckeditor.net/
This is one of the best in my opinion:
http://www.openwebware.com/
YUI Editor
If you are using PHP or ASP.NET on the back end, take a look at SPAW Editor.
Nicedit is useful for some simple text areas and it has a somewhat clean javascript api.
There is a list of other possible richtext boxes here.
TinyMCE and FCKeditor are the top two WYSIWYG editors in terms of popularity. They are both feature-rich and highly customizable. In my opinion TinyMCE is the easiest to use and maintain of the myriad different options, and still gets my vote after 4 years of usage. YUI is another nice choice worth evaluating, as are the others listed above. I've listed the demo pages for each below:
Tiny
FCK (current site demo is broken, here's a cached site)
YUI
OpenWYSIWYG
I'm liking this Stack Overflow one as well though, +1 to the crew.
-EDIT- but then -1 because you treated me like a spammer with only 1 allowed hyperlink...
HTH
Jeff M.
TinyMCE was the editor that we chose when we were making an internal staff website. The nice part about it was all the keyboard shortcuts (probably found in other editors) and that it was the same editor used inside of WordPress.
We were very happy with how the site turned out, and kept the editor. I would recommend TinyMCE for your project.
Why not try the Stackoverflow site's solution?
you can find details in Stackoverflow's blog post here : Potential Markup and Editing Choices
As many have said here, FCKEditor is a good alternative. However, pay attention to the licensing models of the editors especially if you're planning on using them for a commercial, closed-source application.
http://tinymce.moxiecode.com/license.php
TinyMCE is just LGPL.
http://ckeditor.com/license
CKEditor (the most recent manifestation of FCK Editor) has a separate Closed Distribution License which may cost you some moulah...
I like the feature set and theme of FCKEditor/CKEditor better than TinyMCE but I often end up using TinyMCE due to it being a little simpler to handle in terms of licensing.
No one has mentioned the CuteEditor yet. It's got a silly name, but it's actually quite nice to work with. It's not free, but an enterprise license (which allows you to use it on any number of servers, dev workstations etc) is only 900 bucks or something ridiculously cheap. I believe it's only availble for ASP.Net and classic ASP, though I could be wrong.
TinyMCE and similar editors are not suitable for non-technical people who are likely to mess up the markup. Specially when said non-techy people copy formatted text from word into the RTE on the web page, thinking it's the most natural thing to do.
If you're audience is technical, something like markdown (as used here on SO) is more suitable.
If they're non-technical, let them use WYMeditor (WYM = what you mean), and provide some sort of a tutorial/explanation so they can use it.