Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

380
Visualizações
(CEP/ExtendScript) Is it possible to include a JSX file from a server?

I am developing an extension for InDesign and I would like to store the jsx file on a server. This would allow me to update the plugin if I change something in the jsx without the user having to re-download the extension. I tried to directly do an include in the jsx that is mentioned in the manifest to try to point to the real jsx like this:

local-index.jsx :

//@include "https://server-name/adobe/addins/extendscript/server-index.jsx"
  • (local-index would only serve as a bridge between JavaScript and ExtendScript)
  • (server-index would contain all the methods I use on the JavaScript side with CSInterface.evalScript();)

It doesn't work and I couldn't find any information on the web. Is it possible or does the jsx file have to be local ?

Thanks in advance !

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

You can make AJAX request in local JS to retrieve JSX string from server
See example below

Server side PHP code be like:

<?php
    //JSX Code
    echo 
    "
    alert ('Hello From Server');
    file = new File('~/Desktop/fromServer.txt');
    file.open('w');
    file.write('Hi');
    file.close();
    ";
    
    //OR JSXBIN Code
    //Use eval and remove line breaks from JSXBIN String
    echo "eval('@JSXBIN@ES@2.0@MyBbyBn0AFJAnA.....')"; 
?>

JS code client side:

$.ajax({
        type: "GET",
        cache:false,
        url: URL,
        complete: function (Res) {
          scr = Res.responseText;
          csInterface.evalScript(scr);
        },
        async: false //For Synchronous Excecution 
      });
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda