envjs

unning

  • The goal of Envjs is to provide a highly portable javascript implementation of the Browser as a scripting environment (often referred to as a 'headless' browser ).

    The default implementation is Rhino but many developers have and continue to develop bridges for running Envjs in Ruby, Python, and other host languages with the SpiderMonkey and V8 javascript engines, to name a few.

    The examples below will guide you through how to use Envjs as an end-user, noting in each example which platform the example pertains to. Platform developers should add equivalent examples whenever possible.

    A Warning...

    Envjs will not automatically load and run the external javascript unless the script tags have the attribute type='text/envjs'. To enable all external javascript files you only have to tell Envjs to do so, however remember that all javascript executed will have read/write access to your file system

    Please be aware of the dangers of loading arbitrary code in an insecure environment.


  • rhino


    When running with generic rhino, you will only need the latest rhino, (the rhino bundled with java 1.6 is not recent enough). You will also need to write a javascript file that is responsible for loading env.rhino.js, setting available options if any, and finally setting window.location.



  • readability


    This example is prompted by work from Emre Sevinç who began to try to use Envjs to crawl web pages and use readability.js to output nice simple pages.

posted on 2012-04-01 14:34  lexus 阅读( ...) 评论( ...) 编辑 收藏

转载于:https://www.cnblogs.com/lexus/archive/2012/04/01/2428732.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值