Hi everyone, newbie here, and since everyone has so much free time these days, I decided to resurrect an old issue and give the code wizards something to work on!
I would like to get parallax working on mobile (iOS and iPad) for site I am trying to build. I’ve gone through some of @Eldar’s tutorials to learn, but this seems to be more in need of a code solution because blocs doesn’t support natively the implementation that works with iOS restrictions for the effect.
I’ve read the code above from @pealco and have built and example site using his code that gets a parallax working on mobile. But as I said, I am new, and coding is bit over my head. I see what the code is and how the different section classes worked on the different blocs, but I don’t fully understand what the “commands” are in the coding and how to manipulate those commands to get the page effect on my page.
I also just saw this more recent thread:
https://forum.blocsapp.com/t/any-idea-how-to-replicate-this-parallax-fx/
This seems like a different solution for getting parallax effects to work, but maybe @MDS has some ideas on a solution for this.
The desired page structure is 12 blocs that alternates between parallax and static with different images for some of the parallax backgrounds.
NO global header
bloc1-hero-nav - (12.jpeg) parallax background, hero bloc navbar, gradient overlay
bloc2-intro - static purple color background
bloc3-about - (12.jpeg) parallax background with gradient overlay
bloc4-coach - static no background img color
bloc5-services-hero - (camera.jpeg) pararlax background, gradient overlay
bloc6-services - static no background img or color
bloc7-tales - (7.jpeg) párallax background with overlays
bloc8-pricing - static no background img or color
bloc9-contact-hero - (3.jpeg) parallax background, gradient overlay
bloc10-contact-form - static no background img or color
bloc11-newsletter - (14.jpeg) parallax background, overlays
Bloc-placeholder - will add all referenced parallax images and hide visibility
bloc12-footer (global footer) - static no background img or color
I have built an example site of what I am trying to do and some mostly experiments with the code and different page structures. The example page does include a download link for the blocs project file:
https://www.tdadventure.com/parallax/
Looking at the navbar on the landing page, here are the links:
- Parallax page - mockup of the page I am trying to build with parallax for mobile (doe not have any of the code from this thread)
- Working code page - blank page with the code described in this thread.
- Experiment page - without changing the code, I added blocs before the “section-one” class bloc and it changed how the parallax effects functions
- Hero page - added hero structure without an image in the “section-one” class bloc
- Navbar - added a navbar in the global header
- Download - link to a zip of the blocs project file
- Scroll - testing for a “scroll to” link in the navbar
Hopefully the community can put it’s head together and help with a solution.
Thank you in advance!