Created
August 21, 2020 06:02
-
-
Save nyluntu/b357625862d7566d4efc25d08bc93efe to your computer and use it in GitHub Desktop.
Lomakkeen lähettäminen kun input kentän tyyppi on image.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Jos HTML lomake lähetetään seuraavaalla tavalla POST tyyppisenä niin | |
| // sen mukana tulee type="image" vuoksi pari ylimääräistä tietoa. | |
| // Koska tässä kentän nimi on "submit" niin lomakkeen mukana tulee kentät | |
| // submit.x ja submit.y | |
| // Kentät muodostuvat sen vuoksi, että input-elemnetin tyyppinä on "image". | |
| <input type="image" name="submit" src="https://payment.checkout.fi/static/img/danskebank_140x75.png" title="Danske Bank" alt="Submit" class="provider-button hover01 col-xs-6" /> | |
| // Edellisen tilanteen voi korjata esimerkiksi muuttamalla hieman lomakkeen | |
| // painiketta. Esimerkki alla. | |
| <button class="provider-button"> | |
| <div class="button-content"> | |
| <img src="https://payment.checkout.fi/static/img/danskebank_140x75.png" alt="Danske Bank" title="Danske Bank"> | |
| </div> | |
| </button> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment