Skip to main content
vilim6745980
Participant
May 28, 2019
Answered

Duplicating page inc JS/CSS and others

  • May 28, 2019
  • 2 replies
  • 1935 views

I have a template and want to add a page, it has 4 pages.

Home About Services Contact

I want to add a new page FAQ, in the same format at the About page

Is the only way to do this, to manually search for every entry/code named:  About and copy is, then rename the new copy to FAQ ?

Or does DW have a system/function that will do that for me ?

    This topic has been closed for replies.
    Correct answer B i r n o u

    Birnou ..

    That is a most generous offer ....

    If you have some spare time, and only at your convenience; I would be most grateful.

    I was not looking for someone to 'fix this - please'.

    I have had Adobe CC for sooo many years, I have tried tutorial videos like https://www.lynda.com.

    But I end-up finding life demanding and have to leave my Adobe/PC dabbling for extended periods, of course in that time I forget all I figured.

    This time when my son asked for help putting a site together I tried to get him on to Wix or something like that. I felt I just didn't have the time now, (I am my aged dads f/t carer).  Then when I opened CC - WoW so much had changed, almost so, that anything I remembered how to do, I couldn't find/figure cause it didn't look the same as I remembered it.

    I know DW is powerful, and I am ashamed to admit I use it almost like Notepad, not even notpad++.

    So this is where my original question came from, was what I looking for/to do something built-in to DW. I thought I'm better of asking now when it would be handy to know. Than to find out in a few months/years time - so I found my way here and asked 

    P.S.

    BTW .....

    If you have read this far I'll add:

    I'm glad my son encouraged me to do this for him; even though it's been a bit of a bumpy ride, it has shown me I can fit some 'me' time in and dabble around on the PC.

    So I think I will take the advice offered here and try some of the Adobe tutorials and start afresh - again.


    hello sorry for the delay... I had some work on my desk when beeing back from the event... so ...  here is an alternative approach to yours

    BUT... yours of replacing the unused page as you did was really fine....

    so

    Well, first on the source HTML and after the present menu one need to add a new LI item for completing the menu as

    <li id="navNewLink" class="nav-item">

        <a href="#" class="nav-link"> New Link </a>               

    </li>

    two elements are important in term of semantic, label and case sensitive...

    the ID navNewLink

    the menu item (as you like) New Link

                       

    so still in the source code, one need to add the SECTION reflecting the future and new page content,

    here there is a template nuts to be respected before adding the free and pure content   

    one can add the newt HTML code, just after the line

    <!-- Dropdown Script -->  (currently present in the source code).

    just remark that a class         newlink-page is created for this purpose and so need to be added in the style.css file...

    just play with a ctrl-f in that document to find aout where   

    (check in your template material if there is any scss file... for sure that will help to avoid a massive copy / paste in that purpose)

    CAUTION !!!! you have an error on the rules at /** End icon-max && Close **/

    there is a space .faq-page .full-width, that shouldn't be present as

            .faq-page.full-width,

    so the HTML SECTION

                      

    <!-- Start New Link -->

    <section class="newlink-page" id="newlinkPage">

        <div class='row height-all'>

            <!-- Icon max -->

            <div class="col-lg-12 text-right icon-max">

                <div class="table-icon-top"> <span> <svg class="icon toggle-width max-min" height="21" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg">

                    <path d="M950.857143 1024h-219.428572a73.142857 73.142857 0 1 1 0-146.285714h146.285715v-146.285715a73.142857 73.142857 0 0 1 146.285714 0v219.428572a73.142857 73.142857 0 0 1-73.142857 73.142857z m0-658.285714a73.142857 73.142857 0 0 1-73.142857-73.142857V146.285714h-146.285715a73.142857 73.142857 0 1 1 0-146.285714h219.428572a73.142857 73.142857 0 0 1 73.142857 73.142857v219.428572a73.142857 73.142857 0 0 1-73.142857 73.142857z m-658.285714 658.285714H73.142857a73.142857 73.142857 0 0 1-73.142857-73.142857v-219.428572a73.142857 73.142857 0 0 1 146.285714 0v146.285715h146.285715a73.142857 73.142857 0 1 1 0 146.285714zM292.571429 146.285714H146.285714v146.285715a73.142857 73.142857 0 0 1-146.285714 0V73.142857a73.142857 73.142857 0 0 1 73.142857-73.142857h219.428572a73.142857 73.142857 0 1 1 0 146.285714z" fill="#fff" />

                    </svg>

                    <!-- SVG Close Tab -->

                    <svg class="icon close-section" height="25" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg">

                    <path d="M184.64768 836.34176a20.50048 20.50048 0 0 0 28.9792-0.02048l292.70016-293.04832 292.70016 293.04832a20.48 20.48 0 1 0 28.99968-28.93824L535.61344 514.64192 828.0064 221.92128a20.48 20.48 0 1 0-28.9792-28.93824L506.30656 486.03136 213.6064 192.98304a20.48 20.48 0 1 0-28.9792 28.93824l292.37248 292.72064L184.6272 807.38304a20.48 20.48 0 0 0 0.02048 28.95872z" fill="#fff" />

                    </svg> </span> </div>

            </div>

            <!-- Icon max -->

            <!--  Start -->

            <div class="col-lg-12 container-scroll">

                <div class="screen-lg-big">

                    <div class="container">

                        <div class="row list">

                            <h2 class="text-center col-lg-12" data-text="Contact"> New Link<span style="color: #1e7e34;"></span> </h2>

                            <p class="text-center wow fadeIn col-lg-12 contact-parg" data-wow-delay=".1s"> Sub title of the section. </p>

                        </div>

                       

                        <!-- CONTENT GOES HERE  -->

                       

                       

                    </div>

                </div>

            </div>

        </div>

    </section>

    <!-- End New Link -->

    in the same way an ID is created, newlinkPage    and this id must be set up in the main.js file in the init native function

    (you'll see there all the other pages recored... so add

            newlinkPage  = $('#newlinkPage')

           

    that done, one need to link the menu ittem ...  so still in the main.js add

    navNewLink   = $('#navNewLink')

    and on the allSectionMoved, adding the page section ID

    in our case --> newlinkPage so modify the appropriate JS line as

    allSectionMoved = $('#contactPage, #servicesPage, #aboutPage, #faqPage, #portfolioPage, #newlinkPage')

    and the event too... so as the scripts are multiple... one need one by one to add to all of them (navAbout, navFaq, navServices , navPortfolio, navContact

    just adding to all of them the add(newlinkPage) just before the removeAttr('style') will be fine

    then create your own for this new page (New Link) at the end of all the others one as

        // Show New Link

        navNewLink.on('click', function () {

            activeNavBar(navNewLink);

            contactPage.add(ServicesPage).add(portfolioPage).fadeOut(100);

            contactPage.add(ServicesPage).add(AboutPage).add(FaqPage).add(portfolioPage).add(newlinkPage).removeAttr('style');

            // Close Nav In Mobile

            if (navbarTogglerMob.attr('aria-expanded') !== 'false') {

                navbarTogglerMob.trigger('click');

            }

            // show page

            newlinkPage.fadeIn(399);

        });

    then adding the full screen and the close buttons events.

    simply look almost at the end of the main.js, and add .add(newlinkPage) to the closeSectionContent function

    that should do the job

    as it makes a lot of modification, you will find the HTML JS and CSS file on that link,

    http://www.birnou.net/tjt11719822.zip

    please, let me know when donwloaded, I will remove the archive from server.

    hope that helps...

    have a pleasant day

    b_irnou

    2 replies

    B i r n o u
    Legend
    May 29, 2019

    it is for sure that knowing the code is a value that is sorely lacking today.

    but it is also important, and especially for small teams, to keep in mind that mastering the notions of ergonomics, content strategy, to know how to promote a user experience that is worthy of the name... are just as many values that should not be forgotten.

    I saw so many sites developed by programming and code experts that were so visually poor... so old-fashioned... that the value provided by the code passed far, so far from reality for the customer...

    it is necessary to preserve this fair compromise between code quality and user experience richness

    Legend
    May 29, 2019

    https://forums.adobe.com/people/B+i+r+n+o+u  wrote


    it is necessary to preserve this fair compromise between code quality and user experience richness

    Unfortunately a great percentage of 'developers' using frameworks, drag and drop, cms etc lack either skill. Its not that the problem is frameworks and drag and drop per se, its that they are openly available to the skill-less that predominately use them.

    B i r n o u
    Legend
    May 29, 2019

    osgood_  a écrit

    Unfortunately a great percentage of 'developers' using frameworks, drag and drop, cms etc lack either skill. Its not that the problem is frameworks and drag and drop per se, its that they are openly available to the skill-less that predominately use them.

    I wasn't talking about developers using frameworks, I was talking about code experts

    BenPleysier
    Community Expert
    Community Expert
    May 28, 2019

    You don't have to duplicate anything, just create a new page from your template after adding a new menu item.

    Wappler is the DMXzone-made Dreamweaver replacement and includes the best of their powerful extensions, as well as much more!
    vilim6745980
    Participant
    May 29, 2019

    When I did that ... nothing worked.

    I think its looking for all the JS and CSS and Bootstrap info.

    BenPleysier
    Community Expert
    Community Expert
    May 29, 2019
    Wappler is the DMXzone-made Dreamweaver replacement and includes the best of their powerful extensions, as well as much more!