Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API

Developer and Consultant at We Make Awesome Sh
Jan. 29, 2011
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API
1 of 46

More Related Content

What's hot

Infinite Possibilities - Devoxx Belgium, 2014Infinite Possibilities - Devoxx Belgium, 2014
Infinite Possibilities - Devoxx Belgium, 2014Denise Jacobs
Immediate Inspiration Immediate Inspiration
Immediate Inspiration Denise Jacobs
BPL: Libraries, Learning & PlayBPL: Libraries, Learning & Play
BPL: Libraries, Learning & Playhblowers
FeynmanFeynman
FeynmanParkhurst Graphic Design
Banish Your Inner Critic to Unleash Creativity – edUi Conference 2015Banish Your Inner Critic to Unleash Creativity – edUi Conference 2015
Banish Your Inner Critic to Unleash Creativity – edUi Conference 2015Denise Jacobs
CreditsCredits
Creditsr0xee

Similar to Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API

Introduction to javascriptIntroduction to javascript
Introduction to javascriptSyd Lawrence
Frilansverktøykasse (praktiske tips for budsjettering og prosjektstyring)Frilansverktøykasse (praktiske tips for budsjettering og prosjektstyring)
Frilansverktøykasse (praktiske tips for budsjettering og prosjektstyring)Andreas Beining
Javascript DevelopmentJavascript Development
Javascript DevelopmentSyd Lawrence
Mobile Web App Development (Building your API)Mobile Web App Development (Building your API)
Mobile Web App Development (Building your API)Syd Lawrence
Varrati Zack slideshare_presentationVarrati Zack slideshare_presentation
Varrati Zack slideshare_presentationZack James
Wilkins, akeem visual resume Wilkins, akeem visual resume
Wilkins, akeem visual resume Awilkins1920

Recently uploaded

Data Integrity TrendsData Integrity Trends
Data Integrity TrendsPrecisely
Jino Clone: Develop a Car Wash Mobile App with Limited Resources Jino Clone: Develop a Car Wash Mobile App with Limited Resources
Jino Clone: Develop a Car Wash Mobile App with Limited Resources eSiteWorld TechnoLabs Pvt. Ltd.
Microsoft Azure New - Sep 2023Microsoft Azure New - Sep 2023
Microsoft Azure New - Sep 2023Daniel Toomey
ContainerDays Hamburg 2023 — Cilium Workshop.pdfContainerDays Hamburg 2023 — Cilium Workshop.pdf
ContainerDays Hamburg 2023 — Cilium Workshop.pdfRaphaël PINSON
Improving Employee Experiences on Cisco RoomOS Devices, Webex, and Microsoft ...Improving Employee Experiences on Cisco RoomOS Devices, Webex, and Microsoft ...
Improving Employee Experiences on Cisco RoomOS Devices, Webex, and Microsoft ...ThousandEyes
Swiss Re Reinsurance Solutions - Automated Claims Experience – Insurer Innova...Swiss Re Reinsurance Solutions - Automated Claims Experience – Insurer Innova...
Swiss Re Reinsurance Solutions - Automated Claims Experience – Insurer Innova...The Digital Insurer

Recently uploaded(20)

Making AJAX User Friendly, Google Friendly, Friendly Friendly using the History API

Editor's Notes

  1. \n
  2. I’m sydlawrence\n afraid of heights\n lead developer at Marmalade\n part time lecturer at Winchester Uni on the Digital Media Development Course\n love the future\n Going to talk about the new History API available in all decent browsers\n will also cover mistakes made by developers with ajax\n\n
  3. What is it?\n You, you guessed it, it is part of the ‘html5’ spec\n\n
  4. HTML5\n but of course it is javascript... That discussion is certainly for another time...\n One of the many new javascript toys available in the HTML5 spec\n DeviceOrientation\n GeoLocation\n LocalStorage\n\n
  5. Javascript Object\n basically window.history is a javascript object\n It has been available for a long time\n window.history.back\n a couple of NEW tools\n\n
  6. What is the problem?\n Why do we need window.history\n\n
  7. Ajax loads new content\n out with the old, in with the new... \n that content is dynamically generated.. \n google doesnt see that content... \n unless you use a link for google to spider.\n\n
  8. Back button\n People press the back button all the time... \n Much more than I ever thought... \n The amount of times I have seen people get confused by pressing back, and then leaving a site..\n One of the horrendous issues with Flash...\n USER FRIENDLY\n\n
  9. Copy & Paste\n Same, same\n People like to share urls...\n GOOGLE FRIENDLY\n They will share the wrong url!\n think ow.ly\n Dont make people confused the first time they click on a link to get to your site...\n First time visitors...\n Treat them with honour, with diginity, intice them back for more...\n\n
  10. Surely this isn’t new\n This isn’t a new problem.. this wasn’t a problem first discovered in the last six months\n Nope\n People like to find solutions\n\n
  11. location.hash\n There has been an interesting solution, using location.hash\n javascript can modify the hash location of the url...\n i.e. adding a # on the end followed by a string..\n\n
  12. if it ain’t broke\n don’t fix it\n BUT there are issues\n\n
  13. always felt like a hack\n always was a hack... location.hash was not meant for that kind of thing (with regards to ajax, hidden content maybe, but not modified content)\n\n
  14. requires javascript on reload\n If you send a link to someone with the hash location... the new user needs javascript for that to take affect...\n OK, ignore lack of javascript...\n What about Google... Your javascript on reload is to populate with the new ajaxed content\n\n
  15. run through example\n www.example.com/old/#/new\n visit old\n www.example.com/old/\n click something\n www.example.com/old/#/new\n share link\n www.example.com/old/#/new\n old static content, then javascript needs to get the new\n\n
  16. What does it do?\n History stack, that behaves in the same way a simple array would\n\n
  17. Adds to the history books\n push on to the stack\n\n
  18. Back to the Future\n popstate event when they press forwards\n\n
  19. When Would This be useful\n When the content changes...\n When someone might want to share the content\n back button\n copy paste\n\n
  20. Lightboxes\n Images..\n videos\n\n
  21. Popup logins\n more and more sites use this\n what if they fail to login and want to try again\n\n
  22. Comments\n pages\n\n
  23. Pagination\n pages\n\n
  24. Browser Support\n Remember, this is still bleeding edge\n\n
  25. Firefox\n introduced in gecko 2\n firefox 4 \n\n
  26. Chrome\n WebKit 528\n Live version \n\n
  27. Safari\n Also uses webkit\n Live version \n\n
  28. Opera\n Not as yet\n\n
  29. Internet Explorer\n Not as yet\n\n
  30. How do you use this wonderful thing?\n run through workflow\n same ajax mistaked\n\n
  31. Click event on link\n Always do this for ajax content... to the same url that you would without javascript\n ALWAYS\n\n
  32. render differently on ajax requests\n Don’t have different urls..\n\n
  33. history.pushState\n this is used to add to the history\n history.pushState(StateObj,title,url)\n local domain url\n StateObj is anthing you might want to retreive later\n \n There is also replaceState that operates in the same way, but it replaces the current state\n
  34. listen for event\n when someone presses back or forward..\n\n
  35. window.onpopstate\npopstate event\nwindow.onpopstate = function(event)\npasses data\ndata.state = StateObj\n\n
  36. sites that use it\n\n
  37. flickr\nfor their lightboxes\n
  38. google\n20 things i learned about the web ebook\n
  39. github\nfile browsing\n
  40. sydlawrence.com\n\nME!\n
  41. USER Friendly\n\nBack / forward button\nSharing Links\n
  42. Google Friendly\n\n\nindexable content\n
  43. Friendly friendly\n\nIts not even hard to do!\n
  44. Want to know more\n\nMozilla Developer Network\nHTML5 Spec\nMy Fancy-box fork on github\n
  45. Any Questions?\n\n\n\nHow to check in browsers\ncheck to see if the pushstate function exists\n\nwindow.onpopstate = function (evt) {}\nhistory.pushState(StateObj,title,url);\n
  46. Thanks, I’v been sydlawrence\n