Need to capture multiple image paths for responsive design when only one will be displayed at a time

I'm new to CQ and am having enough trouble following the documentation on image components as it is (why is there no master reference for all this?). I have a requirement where we need to capture three versions of an image and put the URLs into three attributes of a tag. The appropriately sized image will be selected via JavaScript based on the browser/device capabilities. I need to know how to capture those images when seemingly only one at a time can be dropped onto the page. Or perhaps there is a more CQ solution to this.

Hi,
You need to customize image component. I mean selected image is a asset in the repository and each asset by default has 3 rendtion generated when the image is uploaded in the dam.
For example when you upload image.jpg file into the DAM, standard workflow is launched and after a while inside the repository (see paths) are created following renditions:
/content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.140.100.png
/content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.319.319.png
/content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.48.48.png
This process can be customized by changing /etc/workflow/models/dam/update_asset.html workflow and modifing "Thumbnail creation" step by adding in the Process tab -> Arguments field new values for new rendition. So for example if you add there [400,400] new rendition will be created in the path
/content/dam/project/image/image.jpg/jcr:content/renditions/cq5dam.thumbnail.400.400.png
Next step is to customize jsp for image component. Using path to the drag and dropped image from a component attributes you can easily take all renditions iterating on the /content/dam/project/image/yourimage.jpg/jcr:content/renditions node and then set paths to all renditions in the tag attributes. Then like you wrote using js you can select proper rendition.
I hope that it hepls you.
Regards,
Adam

Similar Messages

  • Multiple alias paths for icons

    Is it possible to define multiple alias paths for icons?
    In the httpd.conf I have an alias for example:
    Alias /d6i_icons/ "/devapps/test/aces/graphics"
    In the Registry.dat I have set the iconpath and iconextension as follows:
    default.icons.iconpath=/d6i_icons/
    default.icons.iconextension=gif
    I want to add an additional path for icons for another system "/devapps/test/iceman/graphics/"
    Is it possible to have 2 paths for the Alias /d6i_icons/ and how do you code this? I have tried defining another alias and adding the other path on the one alias line, but neither worked.
    Thanks!!
    Shellie

    Hi,
    you can only specify one. However, if you store icons in jar files and set documentbase=codebase in the formsweb.cfg file then you can use separate jar files per application
    Frank

  • Will Muse Create an Update for Responsive Design

    Will muse create an update for responsive design? I understand if you put a shape to the edge of the website that the website will be responsive that way, but I want the text, header, and logo to change as well. Or how about an export to reflow?

    I agree somewhat. I love the usablilty of reflow, so I think that if they implemented those tools into muse it would be perfect. It is a complete web design application, so why not have the responsive design into it?

  • Why does the Error: 500 SC_INTERNAL_SERVER_ERROR appear when multiple users access my JSPs but does not occur when only one user accesses my JSPs?

    When multiple users run my JSP application, why do some users get an Error: 500 SC_INTERNAL_SERVER_ERROR for certain JSP pages with the error message No such file or directory. The JSP listed on the Error 500 page varies and is not always the same. When only one user runs my JSP application, the problem does not occur?
    The database connection is held when the user logs in or accesses certain parts of the JSP and then is immediately released. No connections to the database are held.
    We are using Solaris 8 with MU_6 plus recommended patches.
    Enterprise Ultra 250
    iAS 6 SP 3

    Is anything showing up in the KXS or KJS logs?
    It sounds like you might having some kind of thread safety issue with your code. Either that or your guess about running out of database connections.

  • For some strange reason the songs in my library are multiplying. For example, I really only have 4,000 songs but every time I open itunes I have 6,8,10,000 songs! Any one else have this problem.  How do I stop that from happening?

    For some strange reason the songs in my library are multiplying. For example, I really only have 4,000 songs but every time I open itunes I have 6,8,10,000 songs! Any one else have this problem.  How do I stop that from happening?  I keep having to delete my library!

    This "original file cannot be found" thing happens if the file is no longer where iTunes expects to find it. Possible causes are that you or some third party tool has moved, renamed or deleted the file, or that the drive it lives on has had a change of drive letter. It is also possible that iTunes has changed from expecting the files to be in the pre-iTunes 9 layout to post-iTunes 9 layout,or vice-versa, and so is looking in slightly the wrong place.
    Select a track with an exclamation mark, use Ctrl-I to get info, then cancel when asked to try to locate the track. Look on the summary tab for the location that iTunes thinks the file should be. Now take a look around your hard drive(s). Hopefully you can locate the track in question. If a section of your library has simply been moved, or a drive letter has changed, it should be possible to reverse the actions.
    Alternatively, as long as you can find a location holding the missing files, then you should be able to use my FindTracks script to reconnect them to iTunes .
    tt2

  • Accounting for Multiple Cygwin Paths for Windows Hosts

    Hello everyone,
    We are using EM12cR2 (installed on RHEL) but need to monitor a number of Windows hosts. For most Windows hosts, Cygwin is installed in the default path (C:\cygwin) but we also have Citrix XenApp servers that we would like to monitor but they do not have a C: drive, just M:. I've seen the settings file that allows someone to change the Cygwin path but I can't find information on whether or not you can add multiple paths to that line and what that syntax would be. I've also seen an older Citrix plug-in but I don't see anything stating it's compatibility with this version of EM. If I could, I would test out a number of scenarios in a lab environment but we don't have that option.
    Does anyone know if it's possible to add multiple Cygwin paths (and what the syntax is), if the Citrix plug-in is compatible with EM12cR2, or if there's another way to do this that I'm not thinking of?
    Thank you,
    EMS

    Hi ,
    you have to update the following properties in $OMS_HOME/oui/prov/ssPaths_msplats.properties to reflect the new cygwin installation location.
    eg.
    From
    SSH_PATH=C:/cygwin/bin/ssh.exe
    SCP_PATH=C:/cygwin/bin/scp.exe
    MKDIR_PATH=C:/cygwin/bin/mkdir.exe
    SH_PATH=C:/cygwin/bin/sh.exe
    CHMOD_PATH=C:/cygwin/bin/chmod.exe
    TRUE=C:/cygwin/bin/true.exe
    To
    SSH_PATH=M:/cygwin/bin/ssh.exe
    SCP_PATH=M:/cygwin/bin/scp.exe
    MKDIR_PATH=M:/cygwin/bin/mkdir.exe
    SH_PATH=M:/cygwin/bin/sh.exe
    CHMOD_PATH=M:/cygwin/bin/chmod.exe
    TRUE=M:/cygwin/bin/true.exe
    thanks,
    Prakash

  • Batching multiple images - save for web?

    i'm new to elements 9 on my mac & was wondering if there is a way to save multiple images for web?  the only thing i've come across in the program is one image at a time. thx

    Hello,
      There isn't a way of sending multple images through the Save for Web dialog box. But there are ways of working with multiple files that may accomplish the same, it just depeneds on exactly what you are looking to do. For example, if you are only looking for a way to turn a bunch of PSD, TIFF, or RAW files into a internet compatible JPEG, that can be done via File>Process Multiple Files. From here you can take a folder of images and convert them to another format such as JPEG (you can do other things too, like resize, rename, perform autofixes).
    -Brett

  • Need FM to find physical path for given logical path

    Hi Guru's,
    I wanted to find the physical path for the given the logical path.
    I have a requirement where i have to write records into the file  mentioned via logical path .Inside the program i wanted to fetch the physical path for given logical path .
    Is there any FM to achieve this functionality.
    Thanks!!
    Pravee

    Use fm FILE_GET_NAME to get physical file name from a logical file name. But u have to maintain the mapping between logical file name and physical file name in tran. FILE.
         call function 'FILE_GET_NAME'
              exporting
                   logical_filename = lds_name << Logical file name
              importing
                   file_name        = ds_name << Physical file name
              exceptions
                   file_not_found   = 01.
    Regards,
    Joy.

  • Insert images and text in header for responsive design cc

    I am having a issue with inserting a logo, company name and Facebook graphic into my header.
    I started setup of a responsive design and added a responsive header along with other areas below.
    I want the Logo to stay on the left, the company name to the right of the logo and the Facebook graphic on the right side of the header.
    I keep making a mess and can't get anything to line up correctly.
    I am using Adobe Dreamweaver CC and trying to control with CSS.
    I am just starting to learn the new CSS Designer in CC. I liked the old CSS console better.

    Basically, you need to float all 3 elements left and give them a width of 33.33% (3-across).
    header #logo,
    header h1,
    header #fb {
         float:left;
         width: 33.33%;
    HTML:
    <div class="gridContainer fluid">
         <header>
              <div id="logo">Your logo here</div>
              <h1>Your Site Name</h1>
              <div id="fb">Facebook here</div>
         </header>
    Nancy O.

  • Centering Marquee for Responsive Design

    My website is displaying my current marquee... http://www.roemtech.com/new/rotator.html
    I built this rotator for my imac with a width of 100% (1900px max) and a set 500px height.  If you open the page in a browser for the imac the background and image display correctly and the background responds correctly for smaller sized images.  However on smaller screens the rotating images do not hit the center of the background. 
    How can I set the pictures to maintain thier aspect ratio while still hitting the center of the screen for multiple screen sizes?

    Justin: What I meant was I would like the students to design a site that will be responsive to whatever device the visitor is using. It appears Muse has you create three versions (computer, tablet, phone) and then the Business Catalyst host has scripting to know which of the three to send out to the visitor. But, is Muse able to create the scripts required to make this happen without relying on whether or not the server has specific JavaScripts? Sorry, I'm a bit over my head with this. Thank you in advance for your continued help!

  • How to add multiple presets to responsive design view without having to resize the screen each time

    I want to be able to add multiple screen size presets to the responsive design view capability but don't want to have to resize the screen and add each one individually via the custom preset function.
    Have seen that some posts on the internet (http://g-liu.com/blog/2013/08/firefox-rdm-presets/) that say this can be done but cannot find where the config is held in ver 26.0?

    You can also do the opposite and create custom settings in the responsive design mode window.
    You can hold down the Shift key and drag the borders via the (right border, bottom border, bottom right corner) resize icons to get specific dimensions and give the current custom setting a name to add them as a preset.
    This will add the preset to the devtools.responsiveUI.presets pref.
    See also my post here for a bookmarklet.
    *[[/questions/957590]]
    You can paste the current value of the pref in the prompt to see a list of currently defined presets.<br />
    You can add a new preset by entering the width,height,name values in the prompt.<br />
    Copy the new preset list to the pref.
    <pre><nowiki>javascript:(function(){
    function rdObj(w,h,n){with(this){key=w+"x"+h;if(n)name=n;width=w;height=h;}}
    rdObj.prototype={key:"",name:"",width:"",height:""};
    var n={},p='<width>x<height> <name> OR width,height,name',rd=[];
    while(p!=null){
    p=prompt(p,JSON.stringify(rd));
    if(/^(\d{3,4})[,x](\d{3,4})([, ](.+))?$/.test(p)){
    n=new rdObj(RegExp.$1,RegExp.$2,RegExp.$4);rd.push(n);
    }else{try{rd=JSON.parse(p);}catch(e){}}
    }})()</nowiki></pre>

  • Need Recommendation on converting existing site to responsive design in ATG 10.1.2

    Hi,
    We have a site developed for a client which is build using CRS 9.0. We need to convert the website to responsive design using bootstrap framework version 3.4. The HTML prototypes have been design by UI designer using bootstrap. Does anyone have experience in doing similar work and can suggest guidelines/recommendations to make this migration easier/faster?
    Thanks

    Hi,
    Have you had a look at
    https://support.oracle.com/rs?type=doc&id=1563355.1
        Oracle Commerce and Responsive Design White Paper (Doc ID 1563355.1)
    ++++
    Thanks
    Gareth
    Please mark any update as "Correct Answer" or "Helpful Answer" if that update helps/answers your question, so that others can identify the Correct/helpful update between many updates.

  • HT4539 When having multiple user accounts on a mac can only one of you use the automatic downloads in iTunes?

    Why is it that in itunes on a mac, if you have multiple users, that only one apple id can be used for automatic downloads?

    See if this helps: iTunes: How to share music between different accounts on a single computer

  • Need help in setting up PSTN to VOIP gateway with only one VOIP account.

    Hi!
    I am having hard time configuring SPA 3102 for # 3 and # 4 in following requirement list. I have only one VOIP account and my provider does not support simultaneous registrations even on different port. So I want to setup gateway without PSTN line being registered, so only Line 1 is registered with a VSP.
    1. POT terminal can dial out using PSTN or VOIP based on dialplan. Done!
    2. POT terminal can receive call from VOIP. Done!
    3. If a call is received at PSTN line then it should be dealt as gateway call if from particular number, otherwise it is sent to POT Terminal.
    4. If the call is not attended thru POT Terminal then it should be redirected to a particular number using VOIP after certain number of rings.
    Regards,
    Babar.

    #3
    i think that it is not possible,
    - the default bahaviour of the SPA3102 is to recieve the call from the PSTN line, forward it to the phone connected to the FXS port.
    - if there is no answer on the FXS it is then forwarded to a certain number via voip or given a second dial tone.
    #4
    This is functioning ans is the default scenario.,
     register the PSTN line the same as the Line 1.
    set the register to " NO"
    make call without register to "NO"
    ans call without regsiter to "NO"
    - if you need to forward that to a voip number of your choice
    set the PSTN To VOIP dial plan to 2 and change the dial plan on the PSTN line to S0 < : target phone number >

  • Multiple devices showing in iTunes when only one device is plugged in

    How come multiple devices show up in iTunes left-hand DEVICES column when I plug in only one device? When I plug in my iPhone, two of the same devices by the same name show up in the left hand column within iTunes, ALONG with two other iPhones in our family. Can anyone offer insight please? Thank you in advance!

    You may have enabled wifi sync on your iPhone.

Maybe you are looking for

  • Safari has decided it doesn't want to work anymore...

    Safari was working just fine on my MacBook Pro 13" (10.7.2) a few days ago, until it decided it would not load anymore pages.  The load bar stops a few cm in and stays there... also, when I open up Safari it freezes and presents me with the spinning

  • Classic sync problems

    Following a problem with my computer, I reinstalled iTunes and successfully copied all music back on from an external hard drive back up. However, my Classic won't sync with iTunes even though it's recognised. First message says the iPod is sync'd wi

  • How do.I restart macbook.air after forgetting password

    how do.I restart macbook.air after forgetting password

  • Scrolling distortion

    With my new MacBook Pro there is a scrolling distortion appearing in Mail and Safari inside of the window-never outside-and it disappears when you stop scrolling. I never had this happen with my old power book. What to do?

  • Sync Outlook 2010

    I have Outlook 2010 and iPhone 4s. Recently the iphone has stopped syncing with my main calendar either over wifi or when plugged in.  I have tried re-setting in iTunes and removing all annual repeating calendar items and even download iCloud, but I