How can I change HTML into a dictionary.
So what I mean is I have some html code...
and I want it to look like a dictionary...
Of course I can't just do it myself because different html will be entered each time.
Thanks for the help.
So what I mean is I have some html code...
Code:
<center> <div id="header-content"> <div id="header-content-left"> <a href="index.html" target="_top"><img src="header-image.jpg" id="header-image" alt="Pager"></img><a/> </div> <div id="header-content-right"> <a href="create.html" target="_top"><button id="header-content-right-cp"> <p style="font-family:Calibri; font-size:20px; text-align:center;"> Create </p> </button></a> <button id="header-content-right-si"> <p style="font-family:Calibri; font-size:20px; text-align:center;" onclick="login()"> Login </p> </button> <button id="header-content-right-so"> <p style="font-family:Calibri; font-size:20px; text-align:center;" onclick="logout()"> Logout </p> </button> <div id="header-content-right-pr"> <a href="account.html" target="_top"><p style="margin-top:7px; font-family:Calibri; font-size:18px; text-align:center;"> kMcMaxPicAxeYT991 </p></a> </div> </div> <div id="header-content-right-phone"> </div> </div> </center>
Code:
{"center":
{
"div id="header-content"":
{
"div id="header-content-left":
{
"a href="index.html" target="_top":
{
"img src="header-image.jpg" id="header-image"": None
}
}
"div id="header-content-right"":
{
"a href="create.html" target="_top"":
{
"button id="header-content-right-cp"":
{
"p style="font-family:Calibri; font-size:20px; text-align:center;"": "Create"
}
}
"button id="header-content-right-si"":
{
"p style="font-family:Calibri; font-size:20px; text-align:center;" onclick="login()"": "Login"
}
"button id="header-content-right-so"":
{
"p style="font-family:Calibri; font-size:20px; text-align:center;" onclick="logout()"": "Logout"
}
"div id="header-content-right-pr"":
{
"a href="account.html" target="_top"":
{
"p style="margin-top:7px; font-family:Calibri; font-size:18px; text-align:center;"": "kMcMaxPicAxeYT991"
}
}
}
"div id="header-content-right-phone"": None
}
}
}
Thanks for the help.
Comment