Friday, March 20, 2020
Using PHP and HTML on the Same Page
Using PHP and HTML on the Same Page Want to add HTML to a PHP file? While HTML and PHP are two separate programming languages, you might want to use both of them on the same page to take advantage of what they both offer. With one or both of these methods, you can easily embed HTML code in your PHP pages to format them better and make them more user-friendly. The method you choose depends on your specific situation. HTML in PHP Your first option is to build the page like a normal HTML web page with HTML tags, but instead of stopping there, use separate PHP tags to wrap up the PHP code. You can even put the PHP code in the middle if you close and reopen the ?phpà and ? tags. This method is especially useful if you have a lot of HTML code but want to also include PHP. Heres an example of putting the HTML outside of the tags (PHP is bold here for emphasis): html titleHTML with PHP/title body h1My Example/h1 ?php//your PHP code goes here? bHere is some more HTML/b ?php //more PHP code ? /body /html As you can see, you can use any HTML you want without doing anything special or extra in your PHP file, as long as its outside and separate from the PHP tags. In other words, if you want to insert PHP code into an HTML file, just write the PHP anywhere you want (so long as theyre inside the PHP tags). Open a PHP tag withà ?phpà and then close it withà ?à like you see above. Use PRINT or ECHO This other way is basically the opposite; its how youd add HTML to a PHP file with PRINT or ECHO, where either command is used to simply print HTML on the page. With this method, you can include the HTML inside of the PHP tags. This is a good method to use for adding HTML to PHP if you only have a line or so to do. In this example,à the HTML areas are bold: ?php Echo html;EchotitleHTML With PHP/title;EchobMy Example/b;//your php code herePrintiPrint works too!/i; ? Much like the first example, PHP still works here regardless of using PRINT or ECHO to write HTML because the PHP code is still contained inside the proper PHP tags.
Wednesday, March 4, 2020
Biography of Martha Carrier, Accused Witch
Biography of Martha Carrier, Accused Witch Martha Carrier (ââ¬â¹born Martha Allen; died August 19, 1692) was one of 19 people accused of witchcraft who were hanged during the 17th century Salem witch trials. Another person died of torture, and four died in prison, although the trials lasted only from spring to September of 1692. The trials began when a group of girls in Salem Village (now Danvers), Massachusetts, claimed to be possessed by the devil and accused several local women of being witches. As hysteria spread throughout colonial Massachusetts, a special court was convened in Salem to hear the cases. Fast Facts: Martha Carrier Known For: Conviction and execution as a witchBorn: Date unknown in Andover, MassachusettsDied: Aug. 19, 1692 in Salem, MassachusettsSpouse: Thomas CarrierChildren: Andrew Carrier, Richard Carrier, Sarah Carrier, Thomas Carrier Jr., possibly others Early Life Carrier was born in Andover, Massachusetts, to parents who were among the original settlers there. She married Thomas Carrier, a Welsh indentured servant, in 1674, after giving birth to their first child, a scandal that wasnt forgotten. They had several children- sources give numbers ranging from four to eight- and lived for a time in Billerica, Massachusetts, moving back to Andover to live with her mother after her fathers death in 1690. The Carriers were accused of bringing smallpox to Andover; two of their children had died of the disease in Billerica. That Carriers husband and two other children were ill with smallpox and survived was considered suspect- especially because Carriers two brothers had died of the disease, which put her in line to inherit her fathers property. She was known as a strong-minded, sharp-tongued woman, and she argued with her neighbors when she suspected them of trying to cheat her and her husband. Witch Trials Belief in the supernatural- specifically, in the devilââ¬â¢s ability to give humans the power to harm others through witchcraft in return for their loyalty to him- had emerged in Europe as early as the 14th century and was widespread in colonial New England. Coupled with the smallpox epidemic, the aftermath of a British-French war in the colonies, fears of attacks from nearby Native American tribes, and a rivalry between rural Salem Village and the more affluent Salem Town (now Salem), the witch hysteria had created suspicions among neighbors and a fear of outsiders. Salem Village and Salem Town were near Andover. The first convicted witch, Bridget Bishop, was hanged that June. Carrier was arrested on May 28, along with her sister and brother-in-law, Mary and Roger Toothaker, their daughter Margaret (born 1683), and several others. They all were charged with witchcraft. Carrier, the first Andover resident caught up in the trials, was accused by the four Salem girls, as they were called, one of whom worked for a competitor of Toothaker. Beginning the previous January, two young Salem Village girls had begun having fits that included violent contortions and uncontrolled screaming. A study published in Science magazine in 1976 said the fungus ergot, found in rye, wheat, and other cereals, can cause delusions, vomiting, and muscle spasms, and rye had become the staple crop in Salem Village due to problems with cultivating wheat. But a local doctor diagnosed bewitchment. Other young local girls soon began to exhibit symptoms similar to those of the Salem Village children. On May 31, Judges John Hathorne, Jonathan Corwin, and Bartholomew Gedney examined Carrier, John Alden, Wilmott Redd, Elizabeth How, and Phillip English. Carrier maintained her innocence, though the accusing girls- Susannah Sheldon, Mary Walcott, Elizabeth Hubbard, and Ann Putnam- demonstrated their supposed afflictions caused by Carriers powers. Other neighbors and relatives testified about curses. She pleaded not guilty and accused the girls of lying. Carriers youngest children were coerced into testifying against their mother, and her sons Andrew (18) and Richard (15) were also accused, as was her daughter Sarah (7). Sarah confessed first, after which her son Thomas Jr. did as well. Then, under torture (their necks tied to their heels), Andrew and Richard also confessed, all implicating their mother. In July, Ann Foster, another woman accused in the trials, also implicated Martha Carrier, a pattern of the accused naming other people that was repeated again and again. Found Guilty On August 2, the court heard testimony against Carrier, George Jacobs Sr., George Burroughs, John Willard, and John and Elizabeth Proctor. On August 5, a trial jury found all six guilty of witchcraft and sentenced them to hang. Carrier was 33 years old when she was hanged on Salems Gallows Hill on August 19, 1692, with Jacobs, Burroughs, Willard, and John Proctor. Elizabeth Proctor was spared and later freed. Carrier shouted her innocence from the scaffold, refusing to confess to a falsehood so filthy even though it would have helped her avoid hanging. Cotton Mather, a Puritan minister and author at the center of the witch trials, was an observer at the hanging, and in his diary he noted Carrier as a rampant hag and possible Queen of Hell. Historians have theorized that Carrier was victimized because of a fight between two local ministers over disputed property or because of the selective smallpox effects in her family and community. Most agree, however, that her reputation as a disagreeable member of the community could have contributed. Legacy In addition to those who died, about 150 men, women, and children were accused. But by September 1692, the hysteria had begun to abate. Public opinion turned against the trials. The Massachusetts General Court eventually annulled verdicts against the accused witches and granted indemnities to their families. In 1711, Carriers family received 7 pounds and 6 shillings as recompense for her conviction. But bitterness lingered inside and outside the communities. The vivid and painful legacy of the Salem witch trials has endured for centuries as a horrific example of false witness. Noted playwright Arthur Miller dramatized the events of 1692 in his 1953 Tony Award-winning play ââ¬Å"The Crucible,â⬠using the trials as an allegory for the anti-Communist ââ¬Å"witch huntsâ⬠led by Sen.à Joseph McCarthyà in the 1950s. Miller himself was caught up in McCarthys net, likely because of his play. Sources Salem Witch Trials Timeline. ThoughtCo.The Salem Witch Trials Victims: Who Were They? HistoryofMassachusetts.org.Salem Witch Trials. History.com.Salem Witchcraft Trials. WomensHistoryBlog.com.
Subscribe to:
Posts (Atom)