Git Product home page Git Product logo

Comments (12)

phoroszowski avatar phoroszowski commented on June 5, 2024 2

Move CEFCommandLIne component into Resources the sample needs to be corrected.

from samples.

Jolg42 avatar Jolg42 commented on June 5, 2024 1

If you have '--enable-nodejs' in the manifest and it's still not working, just make sure that the ExtensionManifest Version="5.0" version is 5.0 😉 I think that below 5, Node.js is not activated for some reason.

from samples.

undavide avatar undavide commented on June 5, 2024

Hi, have a look at this article for explanation and workarounds.
-Davide

from samples.

kodawah avatar kodawah commented on June 5, 2024

same happens for 2015.3, the article unfortunately didn't help.

from samples.

phlaidback avatar phlaidback commented on June 5, 2024

Is it active in version 6?
I cant get this to work in InDesign CEP version 6.

var fileToUpload = new File([$scope.myPdfBlob], "myfile.pdf");
I have enabled '--enable-nodejs' but get this error:
TypeError: File constructor cannot be called in nwdisabled frame.

Im using angularJS.

from samples.

Jolg42 avatar Jolg42 commented on June 5, 2024

@phlaidback CEP & ExtensionManifest versions are both updated in each major release. But you can use an old ExtensionManifest version if you want to keep retro-compatibility.

Yes, CEP 6 is coming with Node.js.

Maybe your problem is linked to CEP 6.1:

(From the latest CEP Cookbook here https://github.com/Adobe-CEP/CEP-Resources/raw/master/CEP_7.x/CEP_7.0_HTML_Extension_Cookbook.pdf)

Using Node.js APIs (CEP 6.1)
Node.js APIs are disabled by default
Due to security consideration, node.js APIs are disabled by default (prior to CEP 6.1,
they were enabled by default) both on the extension level and IFrame level.
To enable Node.js APIs:

  • Set ExtensionManifest version and RequiredRuntime version 5.0 or higher.
  • Specify '--enable-nodejs' in extension manifest. See section Customize CEF
    Command Line Parameters for details
  • To use Node.js APIs in IFrames, add property 'enable-nodejs' to it and to all its
    ancestor IFrames. If any of its ancestors don't have this property specified,
    Node.js APIs won't work <iframe id="xxx" class="xxxxx" enable-nodejs>

from samples.

kodawah avatar kodawah commented on June 5, 2024

Yes I enabled it, and still no node.
For reference this is my manifest.xml

<?xml version="1.0" encoding="UTF-8"?>
<ExtensionManifest Version="6.0" ExtensionBundleId="com.bundle.identifier" ExtensionBundleVersion="1.0.0" ExtensionBundleName="My panel" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

    <ExtensionList>
        <Extension Id="com.bundle.identifier" Version="10.3.0" />
    </ExtensionList>

    <ExecutionEnvironment>
        <HostList>
            <Host Name="PPRO" Version="[9.1,11.9]" />
        </HostList>
        <LocaleList>
            <Locale Code="All" />
        </LocaleList>
        <RequiredRuntimeList>
            <RequiredRuntime Name="CSXS" Version="6.0" />
        </RequiredRuntimeList>
    </ExecutionEnvironment>

    <DispatchInfoList>
        <Extension Id="com.bundle.identifier">
            <DispatchInfo>
                <Resources>
                    <MainPath>./index.html</MainPath>
                    <ScriptPath>./bundle.jsx</ScriptPath>
                </Resources>

                <Lifecycle>
                    <AutoVisible>true</AutoVisible>
                </Lifecycle>

                <CEFCommandLine>
                    <Parameter>--enable-media-stream</Parameter>
                    <Parameter>--mixed-context</Parameter>
                    <Parameter>--allow-file-access</Parameter>
                    <Parameter>--allow-file-access-from-files</Parameter>
                    <Parameter>--enable-nodejs</Parameter>
                </CEFCommandLine>

                <UI>
                    <Type>Panel</Type>
                    <Menu>Bundle</Menu>
                    <Geometry>
                        <Size>
                            <Width>480</Width>
                            <Height>480</Height>
                        </Size>
                    </Geometry>
                </UI>
            </DispatchInfo>
        </Extension>
    </DispatchInfoList>
</ExtensionManifest>

from samples.

bbb999 avatar bbb999 commented on June 5, 2024

CEP HTML successfully uses Node.js, in PPro. Perhaps start from that sample?

I haven't had anyone report continued problems, after working through Davide Barranca's excellent post on the subject: http://www.davidebarranca.com/2015/12/html-panel-tips-19-cc2015-1-cep6-1-node-js-fixes/

from samples.

Jolg42 avatar Jolg42 commented on June 5, 2024

@phoroszowski 👍 by the way the latest sample is here: https://github.com/Adobe-CEP/CEP-Resources/tree/master/CEP_7.x/Samples/CEP_HTML_Test_Extension-7.0

from samples.

phoroszowski avatar phoroszowski commented on June 5, 2024

Sorry.. I tend to live in the Premiere world. I meant the PPRO sample which is kodabb's probable starting place:

https://github.com/Adobe-CEP/Samples/blob/master/PProPanel/CSXS/manifest.xml

from samples.

Jolg42 avatar Jolg42 commented on June 5, 2024

@phoroszowski Yes but the CEP_HTML_Test_Extension-7.0 is more up to date I think. So maybe it's better to take the CEP important part from this one and the PPRO from the other.

By the way the CEP_HTML_Test_Extension-7.0 is compatible with every apps including PPRO.

from samples.

bbb999 avatar bbb999 commented on June 5, 2024

For PPro API usage, refer to PProPanel. For modern web frameworks and purdy HTML, refer to CEP HTML Test Extension.

from samples.

Related Issues (20)

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.