15 Replies Latest reply on Nov 12, 2012 7:55 AM by ykdartes

    Web Apps Search Results redirect

    ykdartes

      I know how to redirect a Web Apps Search Result to a page of my choice.

      That's great.

      But only the List View (List Template).

       

      I could not find a way to redirect the Results of the Detail View.

      Clicking a link by defaults it opens up in a page created by the module itself.

       

      Is there a trick around this limitation?

       

      any help is very much appreciated

      Dario

        • 1. Re: Web Apps Search Results redirect
          Liam Dilley Adobe Community Professional & MVP

          Hi Dario,

          I do not understand what you mean because that is not true.

          If you click a web app item you have from the search results it loads the detail view of that web app item.

          • 2. Re: Web Apps Search Results redirect
            ykdartes Level 1

            Hi Liam,

            sorry. I try to explain it better.

            I have a Web App with a search form in a page.

            It has both list template and detail template (of course).

             

            When you perform the search you get a bunch of results (with links) at the bottom of the same page.

            Clicking any of these links opens up a page with the detail view of the item (and if you check the url of the page you can see that it is the url set for the web app module: /name-of-web-app/name-of-item).

            It's a page created on the fly that does not exist in the website.

             

            I wanted my results to appear in an actual page of my website.

            I created the page, put the {module_webappsresults} in it and modified the bit of code in the form action.

            Easy. It works. I get the results in my page (where I can control every aspect of it).

             

            The problem arises when I click the link of one list items. Sure, it opens the detail view of the item but, as I said before, in a page created on-the-fly.

             

            I know I can use the modulestylesheets.css to have some kind of control over its look but I would rather have the detail view appear in a page created for that purpose in the site (like I did with the list view).

             

            Is there any workaround? Maybe with jQuery or something?

             

            thank you for your patience

            Dario

            • 3. Re: Web Apps Search Results redirect
              Liam Dilley Adobe Community Professional & MVP

              Hi Dario,

              Does not work like that. Your using web app search results which searches webapps and the results will show web app item which will click through to their detail view using that URL structure. You can not change this.

              When you say "created on the fly" This is not true. Go to any web app item you will see the URL at the top of that web app item of which you can also edit. These URL's can be read by search engines just as any other.

              If you want to search pages so you click through to pages use a site search and site search results module.

              • 4. Re: Web Apps Search Results redirect
                ykdartes Level 1

                Hi Liam

                I'm not sure we understand each other.

                These pages created by the Web App do not exist in the local version of the website.

                They exist inside the system but I don't have direct access to them.

                 

                Let's say I want to add a link to a  CSS stylesheet or javascript, whatever, for the detail view page.

                I tried to put the code in the detail template, inside a <head> tag.

                After I saved it, and looked back in the HTML tab, the <head> tag had disappeared.

                There was only the link sitting on top of the table with the different modules (no HTML tag anymore).

                 

                What I'm talking about here is the control over the page 'before' it is published...

                • 5. Re: Web Apps Search Results redirect
                  Liam Dilley Adobe Community Professional & MVP

                  They do exist in the system.

                  Every web app item can have a template chosen and in terms of the layout they are accessed via FTP under Layouts - Web apps - Web app name.

                  It is the detail layout of that web app and you have the list and list backup along with the edit layout. You can create custom list layouts as of a recent update as well.

                  These and other system generated pages such as blogs, sysytem messages, eCommerce layouts are all System Templates or Module Layouts and can also be accessed via the Admin or FTP.

                   

                  In terms of CSS, doing web standards you have an external stylesheet and target class and html elements. Scripting is best as external scripting but again with the layout access you ad ID and class elements to target.

                  • 6. Re: Web Apps Search Results redirect
                    ykdartes Level 1

                    OK, that's it I guess.

                    The layouts templates.

                    I'll check them.

                    Thank you, very much

                    Dario

                    • 7. Re: Web Apps Search Results redirect
                      Liam Dilley Adobe Community Professional & MVP

                      If you look at your title and first post Dario, you gone from wanting to redirect search links to your actual issue. Always good to just post what you want to achieve and your actual issue

                      Get to help you quicker.

                      • 8. Re: Web Apps Search Results redirect
                        ykdartes Level 1

                        Sorry Liam, it is just my bad English.

                         

                        Anyway:

                        I did check the templates there.

                        I inserted items in a <head> tag, uploaded back and checked the template in the web app (customize web app layout) window.

                        And look what it did (below). Very ugly job, I would say.

                         

                        It put the <link> stuff in the <body> section. And there is not even a </body> closing tag!

                        If that is all you get... I hope it works!

                         

                        Anyway, thank you for your help.

                        Dario

                         

                         

                        <html lang="en">

                            <head>

                                <meta charset="utf-8" />

                                <meta content="width=device-width, maximum-scale=1.0, minimum-scale=1.0, initial-scale=1.0" name="viewport" />

                                <title>Recipe</title>

                        </head>

                        <body>

                                <link type="text/css" href="_css/styles.css" rel="stylesheet" />

                                <link type="text/css" href="_css/screen_layout_large.css" rel="stylesheet" />

                                <link href="http://fonts.googleapis.com/css?family=Sue Ellen Francisco" type="text/css" rel="stylesheet" />

                         

                                <table>

                                    <tbody>

                                        <tr>

                                            <td>{tag_picture}</td>

                                        </tr>

                        • 9. Re: Web Apps Search Results redirect
                          Liam Dilley Adobe Community Professional & MVP

                          Hi.

                          Layouts do not work like that.

                          You create your template and you have your template contain your head, body elements etc.

                          {tag_pagecontent} In that template the tag will then render content of a page or layout of a web app item detail view and so on.

                          In a web app items detail list view or detail view you should only have the layout you need for that item

                          Avoid using tables to structure layouts if you can too

                          • 10. Re: Web Apps Search Results redirect
                            ykdartes Level 1

                            Please, explain a little bit more.

                             

                            I make my own templates (list/detail), with every HTML element I need. OK.

                            I put my templates in the Layouts/Web App folder, I guess.

                             

                            But what about {tag_pagecontent}? Where it should go?

                             

                            In a web app items detail list view or detail view you should only have the layout you need for that item

                             

                            You mean just the module tags?

                             

                            Avoid using tables to structure layouts if you can too

                             

                            Yeah, I know. Tables are bad! (Joking of course. But truly they're only good for ... tabular data).

                            But BC is full of them, and I did not know you could dispense with them (in BC).

                            • 11. Re: Web Apps Search Results redirect
                              Liam Dilley Adobe Community Professional & MVP

                              Templates are not under layouts.

                              Templates are templates.

                              Under the Templates folder via FTP and the Templates part of the admin. These are the site templates. Your framework of your site where you have the tag page content and modules and footer, header of your site, actual HTML and so on.

                              You choose these templates everywhere from pages, blogs, web app items, system messgaes etc.

                               

                              Thus when you make one change to the header of your site it changes ALL these aspects. Otherwise you will have to go to every page, web app item and more to update it.

                               

                              You really need to imserse yourself in the BC documentation.

                              http://kb.worldsecuresystems.com/kb/create-site-design.html

                              • 12. Re: Web Apps Search Results redirect
                                Liam Dilley Adobe Community Professional & MVP

                                In terms of tables BC only has them as default options.

                                I hardly have any tables or none at all in sites I create because I change module tags to use a ul li layout option, menus use CSS HTML only for ul li format and more.

                                They are there for beginers to work with output who have little or no css knowledge. Does not mean you have to use them

                                • 13. Re: Web Apps Search Results redirect
                                  ykdartes Level 1

                                  Yeah, you're right. I need to study more.

                                  And surely I'll do. But usually I prefer to study bits of things and put them into practice immediately.

                                   

                                  I am building one website now, and I had this specific problem (we are discussing about)...

                                   

                                  Just one more clarification: you mean to say that also the web app module will use my custom template?

                                  But I did not see... oh wait! Now I'm getting it (maybe).

                                   

                                  If I create a template and tell the web app module to use it (in the 'Web App Item Options') then BC will use my template for the general layout of the page and take the item specific content from the list/detail templates?

                                  Which means, also, that I can change the list/detail templates and substitute all table elements with div and so on.

                                  Is that right?

                                  • 14. Re: Web Apps Search Results redirect
                                    Liam Dilley Adobe Community Professional & MVP

                                    Your starting to get it yes.

                                    List layout though you output with the module and that can be in a template or on a page using a template and if a stylesheet is specified in that template the html as with all html will render based on that.

                                    • 15. Re: Web Apps Search Results redirect
                                      ykdartes Level 1

                                      well, then.

                                       

                                      Thank you very much for your precious help.

                                      I learned quite a bit with your expertise.

                                       

                                      Keep up the good job.

                                      Dario