Python Dynamically Add Attribute Using Javascript For Navigation