Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New to the CF scene
    Join Date
    Oct 2012
    Posts
    6
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Exclamation KeyBinding and KeyListener for F11 (Fullscreen) - Please help!

    Hi, and thanks for stopping by.
    I'm completely new to this forum, but I didn't know where else to turn to.
    What I want to do is force the user to enter fullscreen as soon as they enter, and I want them to be the one that presses it.
    This is the order in what I'm trying to create.

    1. User enters webpage and sees the words "Fullscreen to continue" on a black background.
    2. User presses F11 (fullscreen) and the words melt away to enter the site.
    3. If the User exits fullscreen while on my site, the words "Please enter fullscreen to continue viewing" would pop up, and they would have to enter fullscreen again.

    This is for simple viewing pleasure, but it'll be very effective if it works.

    Thank you so much in advance. I'm very new to Javascript and coding in general, so sorry if I am in the wrong niche or this is too advanced or something. I've read about KeyListeners and KeyBindings and ActionMaps and InputMaps but it's all bloody chinese to me.

  • #2
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    is force the user to enter fullscreen
    I don't know about anyone else, but if I saw this "request" I would immediately leave the site. I think you should "request", which wouldn't require any JavaScript.

    If you wish to pursue this, though, then you should investigate, for example, the keydown event.
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • Users who have thanked AndrewGSW for this post:

    Shaqcoulter (10-10-2012)

  • #3
    New to the CF scene
    Join Date
    Oct 2012
    Posts
    6
    Thanks
    3
    Thanked 0 Times in 0 Posts
    Thank you for the quick response.
    Yeah actually you're probably right. I didn't really think. Maybe instead it would allow the menu to popup/fade in? If you need clarification it's for my Tumblr Blog. I was looking to spice it up a little bit to attract a bit more traffic.

    I was thinking like as in this site here.
    http://thequietplaceproject.com/90seconds
    Because when the spacebar is pressed, the words fade out and fly in from the top. It would awesome if I could somehow implement this in, but instead the F11 button would be the space bar.

    What is a KeyDown?

  • #4
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    I can't help you with tumblr, soz.

    What is a KeyDown?
    No offence, but if your knowledge of JavaScript is limited then I don't know how you are going to achieve this. Perhaps there is some kind of similar tumblr feature that you can plug-into.. otherwise you'll need to employ someone to do this for you.
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • Users who have thanked AndrewGSW for this post:

    Shaqcoulter (10-10-2012)

  • #5
    New to the CF scene
    Join Date
    Oct 2012
    Posts
    6
    Thanks
    3
    Thanked 0 Times in 0 Posts
    Again, you're probably right. It was an ambitious project that I was wanting to try and I guess I overextended, due to the fact that I don't know **** about Javascript :/
    No worries though, thanks for trying.
    If anyone has any ideas please please comment!


  •  

    Tags for this Thread

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •