AnsweredAssumed Answered

Problems creating new webscript

Question asked by lemmy on Sep 13, 2011
Latest reply on Sep 13, 2011 by lemmy

I'm trying to create a new webscript. webscripts\list\thumbnails.* is pretty much what I need. So I copied and renamed 3 files to pictures.*. I've updated pictures.get.desc.xml

  <shortname>List of pictures</shortname>
  <description>List of pictures</description>

<!– pictures start –>
<#if articles??>
   <!– if articles –>
    <#if articles.title??>
        <div class="interior-header">
            <h2 class="full-h">${articles.title}</h2>
            <#if articles.description??><p class="intheader-paragraph">${articles.description}</p></#if>
    <div class="interior-content">
        <#if articles.assets?size == 0>
            <#if subTitle??><h3>${msg(subTitle)}</h3></#if>               
            <ul class="portfolio-wrapper">
                <#list articles.assets as article>     
                        <a href="<@makeurl asset=article force='long'/>${linkParam!''}"><img src="<@makeurl asset=article rendition='mediumPublicationThumbnail'/>" alt="${asset.title!''}" class="img-border" /></a>
                        <h3><a href="<@makeurl asset=article force='long'/>${linkParam!''}">${article.title!}</a></h3>
                        <#if article.description??><p><@truncate value=article.description chars=100/></p></#if>
<!– pictures end –>


// Get the collection of articles indicated in the component properties
model.articles = collectionService.getCollection(, args.collection);

// If a link page is specified in the component properties then pass this to the view
if (args.linkPage != null)
   model.linkParam = '?view='+args.linkPage;

//If a sub title is specified in the component properties then pass this to the view
if (args.subTitle != null)
   model.subTitle = args.subTitle;

I shall be used in article1 page.

<?xml version="1.0" encoding="UTF-8"?>
   <description>news article style page with medium image</description>

Requesting the corresponding url shows the first and last html-remarks in pictures.get.html.ftl but not <!– if articles –> The JavaScript Debugger is working but it doesn't stop in pictures.js. Refreshing webscripts with http://localhost:8080/alfresco/service/index or http://localhost:8080/share/service/index doesn't effect anything.

Am I missing something?