Div id’s conflict between pages in html5

Scenario: Creating an html application, with a few pages in separate html files. Testing the html web in Chrome, Firefox and building the app for my mobile Android phone through phonegap.com. For debugging purposes I created two identical pages (same content) in different files, with links (link1 and link2) in the root menu.

Problem: When selecting either link from the application root menu, only the first page I requested worked properly and ran scripts populating a list on the page. When pressing “back” and then pressing the other link (not pressed in my first attempt) the resulting page is displayed, but the page list is not populated (..without pressing browser refresh).

Solution: Making sure div elements hosting script results have unique names across the application.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s