<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Importing a script into a webscript in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188099#M141229</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have the same problem. pleeeeeeeeeeeeease reply to this and help us alfresco users out!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I want to use the json utilities from the YUI code, so i put the YUI code in /Alfresco/tomcat/webapps/alfresco/yui&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;the file i want to import is /Alfresco/tomcat/webapps/alfresco/yui/json/json.js&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;my code (first line of my …get.js file)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;import resource="classpath:alfresco/yui/json/json.js"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;i tried&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;import resource="classpath:/alfresco/yui/json/json.js"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;too&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;both of these give the same results, which is a null pointer exception.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;{ "status" : { "code" : 500, "name" : "Internal Error", "description" : "An error inside the HTTP server which prevented it from fulfilling the request." }, "message" : "02010026 Wrapped Exception (with status template): 02010031 Failed to execute script 'classpath*:alfresco\/templates\/webscripts\/Algonquin\/SiteDashboard\/document-library-listing\/document-library-listing.get.js': null", "exception" : "org.springframework.extensions.webscripts.WebScriptException - 02010026 Wrapped Exception (with status template): 02010031 Failed to execute script 'classpath*:alfresco\/templates\/webscripts\/Algonquin\/SiteDashboard\/document-library-listing\/document-library-listing.get.js': null", "callstack" : [ "" ,"java.lang.NullPointerException" ,"org.alfresco.repo.jscript.RhinoScriptProcessor.loadScriptResource(RhinoScriptProcessor.java:324)" ,"org.alfresco.scripts.ScriptResourceHelper.recurseScriptImports(ScriptResourceHelper.java:144)" ,"org.alfresco.scripts.ScriptResourceHelper.resolveScriptImports(ScriptResourceHelper.java:60)"&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 01 Mar 2011 23:58:20 GMT</pubDate>
    <dc:creator>boxie</dc:creator>
    <dc:date>2011-03-01T23:58:20Z</dc:date>
    <item>
      <title>Importing a script into a webscript</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188096#M141226</link>
      <description>I have a webscript "search.get.js" in which i'd like to import a javascript file that is either on the repository or the classpath, doesn't really matter.I've tried both the sintax:&amp;lt;import resource="/Company Home/Data Dictionary/Scripts/myscript.js"/&amp;gt;that works just fine in the javascript file</description>
      <pubDate>Thu, 02 Oct 2008 17:39:58 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188096#M141226</guid>
      <dc:creator>hpalma</dc:creator>
      <dc:date>2008-10-02T17:39:58Z</dc:date>
    </item>
    <item>
      <title>Re: Importing a script into a webscript</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188097#M141227</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Try this:&amp;nbsp; &amp;lt;import resource="classpath:/alfresco/templates/webscripts/myscript.js"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Notice the additional slash in front of 'alfresco'.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Oct 2008 20:02:50 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188097#M141227</guid>
      <dc:creator>sbuckle</dc:creator>
      <dc:date>2008-10-02T20:02:50Z</dc:date>
    </item>
    <item>
      <title>Re: Importing a script into a webscript</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188098#M141228</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Try this:&amp;nbsp; &amp;lt;import resource="classpath:/alfresco/templates/webscripts/myscript.js"&amp;gt;&lt;BR /&gt;&lt;BR /&gt;Notice the additional slash in front of 'alfresco'.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks, but it still doesn't work&amp;nbsp; :cry:&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Oct 2008 22:35:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188098#M141228</guid>
      <dc:creator>hpalma</dc:creator>
      <dc:date>2008-10-02T22:35:47Z</dc:date>
    </item>
    <item>
      <title>Re: Importing a script into a webscript</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188099#M141229</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have the same problem. pleeeeeeeeeeeeease reply to this and help us alfresco users out!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I want to use the json utilities from the YUI code, so i put the YUI code in /Alfresco/tomcat/webapps/alfresco/yui&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;the file i want to import is /Alfresco/tomcat/webapps/alfresco/yui/json/json.js&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;my code (first line of my …get.js file)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;import resource="classpath:alfresco/yui/json/json.js"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;i tried&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;import resource="classpath:/alfresco/yui/json/json.js"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;too&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;both of these give the same results, which is a null pointer exception.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;{ "status" : { "code" : 500, "name" : "Internal Error", "description" : "An error inside the HTTP server which prevented it from fulfilling the request." }, "message" : "02010026 Wrapped Exception (with status template): 02010031 Failed to execute script 'classpath*:alfresco\/templates\/webscripts\/Algonquin\/SiteDashboard\/document-library-listing\/document-library-listing.get.js': null", "exception" : "org.springframework.extensions.webscripts.WebScriptException - 02010026 Wrapped Exception (with status template): 02010031 Failed to execute script 'classpath*:alfresco\/templates\/webscripts\/Algonquin\/SiteDashboard\/document-library-listing\/document-library-listing.get.js': null", "callstack" : [ "" ,"java.lang.NullPointerException" ,"org.alfresco.repo.jscript.RhinoScriptProcessor.loadScriptResource(RhinoScriptProcessor.java:324)" ,"org.alfresco.scripts.ScriptResourceHelper.recurseScriptImports(ScriptResourceHelper.java:144)" ,"org.alfresco.scripts.ScriptResourceHelper.resolveScriptImports(ScriptResourceHelper.java:60)"&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 01 Mar 2011 23:58:20 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/importing-a-script-into-a-webscript/m-p/188099#M141229</guid>
      <dc:creator>boxie</dc:creator>
      <dc:date>2011-03-01T23:58:20Z</dc:date>
    </item>
  </channel>
</rss>

