Closed ahirhasmukh closed 7 years ago
I have used Angular4 Angular-cli 1.2.1. I have made one page website but 3 pages are single so I have added 3 pages.
Angular4
Angular-cli 1.2.1
One page tab like Home About us Product Gallery Another page is FAQ's and Contact us In Footer link of Terms of use
Home
About us
Product
Gallery
FAQ's
Contact us
Terms of use
When I at home page then I show Home About us Product Gallery FAQ's and Contact us When I at FAQ's or Contact us page then I show Home FAQ's and Contact us
But I want to show all page in header when I at FAQ's or Contact us. I have set and get item using session.
One page header is difference and FAQ's or Contact us header is difference.
HTML & Typescript Code
=================== Set Item in Session ============
<a (click)="onTab('Faqs')" scrollTo>FAQ's</a>
onTab(tabName){ sessionStorage.setItem(tabName, "true"); this.router.navigate(['/']); }
=================== Get and Set Item in Session ============
import {scrollTo} from 'ng2-utils'; ngAfterViewInit(){ if (sessionStorage.getItem('Faqs') == 'true') { sessionStorage.setItem('Faqs', 'false'); setTimeout(function () { scrollTo('#Faqs'); }, 70); } }
Working in Google Chrome,Edge browsers but still not working on Mozilla Firefox. So please assistance me.
Google Chrome
Edge
Mozilla Firefox
Same issue coming in my live project. Please give me some batter solution for this ASAP.
Thank you.
@https://github.com/ng2-ui/scrollable/pull/13
Fixed and released
I have used
Angular4
Angular-cli 1.2.1
. I have made one page website but 3 pages are single so I have added 3 pages.One page tab like
Home
About us
Product
Gallery
Another page isFAQ's
andContact us
In Footer link ofTerms of use
When I at home page then I show
Home
About us
Product
Gallery
FAQ's
andContact us
When I atFAQ's
orContact us
page then I showHome
FAQ's
andContact us
But I want to show all page in header when I at
FAQ's
orContact us
. I have set and get item using session.One page header is difference and
FAQ's
orContact us
header is difference.HTML & Typescript Code
=================== Set Item in Session ============
<a (click)="onTab('Faqs')" scrollTo>FAQ's</a>
=================== Get and Set Item in Session ============
Working in
Google Chrome
,Edge
browsers but still not working onMozilla Firefox
. So please assistance me.