moved js script to show pages