Skip to main content
Inspiring
Jun 1, 2021 12:13 AM UTC
Question

Responsive code got broken

This site is a work in progress.

 

Somehow I’ve broken the responsive code (css: media query for mobile) that I’d borrowed from this previous  (mostly) working but unfinished page .  I say (mostly) working because in the mobile version, the whole button needs to highlight on hover, not just the text. I've gone over it line by line but not catching whats wrong...

    This topic is closed to new replies. Start a new post to keep the conversation going.

    17 replies

    Sil.C
    Community Manager
    Community Manager
    Jun 2, 2021 9:35 AM UTC

    Just testing to see if I can reply based on this thread.

    Translate
    Nancy OShea
    Community Expert
    Community Expert
    Jun 1, 2021 6:01 PM UTC

    Use a Bootstrap Starter Template.  It will cut hours off development time and give you a mobile-first,  responsive web page to work with.

     

    Go to File > New Starter Templates > Bootstrap Templates > choose a layout and hit the Create button. 

    SaveAs index.html.

     

     

    Translate
    Nancy O'Shea— Product User & Community Expert
    Inspiring
    Jun 7, 2021 3:47 PM UTC

    I don't get the appeal of Bootstrap. So I start with the Portfolio template. Without any input, just viewing minified CSS, it has over 151,000 characters! That's 45 Word pages of minified CSS text, before I even get started. The hundreds of elements and descriptors defies any elementary understanding. Unless you're swapping out text and images exactly using WYSIWYG, or never open the CSS, customizing from this template is a nightmare without advanced coding knowledge. Even if I just wanted to grab some of the responsive code for use in my own simple page, it's really just impossible as it's spread throughout the template.

     

    So, yes, thanks, I checked it out and gave up. I post here because I'm trying to (re)learn only the most basic necessary code needed, that I can understand and edit.

     

     

    Translate
    Nancy OShea
    Community Expert
    Community Expert
    Jun 7, 2021 6:33 PM UTC

    If building responsively was so simple, everyone would be doing it without the need for frameworks.  But as you're finding, it's not so simple, especially when you have no coding skills.  So pick your poison: 

    • Learn responsive coding methods in  -- HTML5, CSS and JavaScript.
    • DIY with a responsive framework customized to your requirements with Sass, mixins and variables.   See link below for details
      https://getbootstrap.com/docs/4.0/getting-started/theming/
    • DIY with an online web solution that requires no coding skills (special hosting and other fees will apply).
    • Hire a developer.

     

    Translate
    Nancy O'Shea— Product User & Community Expert
    BenPleysier
    Community Expert
    Community Expert
    Jun 1, 2021 1:19 AM UTC
    quote

    in the mobile version, the whole button needs to highlight on hover, not just the text.


    By @TheOriginal150mph

     

    There is no hover event on touch screens, including mobiles.

    Translate
    Wappler is the DMXzone-made Dreamweaver replacement and includes the best of their powerful extensions, as well as much more!
    Inspiring
    Jun 1, 2021 3:30 AM UTC

    Ok thanks. 

     

    Just to confirm - the hover isn't the reason for my question. You'd have to look at the site and resize the window to see how its broken.

    Translate
    BenPleysier
    Community Expert
    Community Expert
    Jun 1, 2021 6:51 AM UTC

    My bad, apparently I did not read the whole question.

     

    Personally I would have gone for a mobile first approach. Create a new style sheet and replace the link in the main document. What you will see is that the `intro-big-text` comes directly below the floated image. You will need to clear the image as well as  the `mainNav`.

    Then you are still stick with the last three menu items menu items that have cleared the floating image. These have moved too far to the left.

     

    All I can suggest is

    1. always develop with mobile first

    2. learn CSS Grid, but at least Flexbox.

     

    Translate
    Wappler is the DMXzone-made Dreamweaver replacement and includes the best of their powerful extensions, as well as much more!