/    Sign up×
Community /Pin to ProfileBookmark

Show picture when button clicked

Hi,
I created a form and I want to show a .jpg picture (in a new empty page) when send button is pressed.
How do I do?

<form target=”_blank” action=”http://localhost/wordpress/grundtema/tack.html” method=”post”>
<div class=”fieldSet”>
<fieldset>
<legend>Kontaktinformation</legend>
<p>Fält med * är obligatoriska.</p>
<p><label class=”field” for=”name”>Namn: *</label>
<input type=”text” id=”name” name=”namn” class=”textbox-1″ value=”” required /></p>
<p><label class=”field” for=”ename”>Efternamn *:</label>
<input type=”text” id=”enamn” name=”efternamn” class=”textbox-1″ value=”” required /></p>
<label class=”field” for=”tel”>Telefon (valfritt):</label>
<input type=”phone” id=”tel” name=”tel” class=”textbox-1″ value=”” /></p>
<label class=”field” for “epost”>E-post: *</label>
<input type=”email” id=”epost” ” name=”mail” value=”” class=”textbox-1″ required /></p>
<label class=”field” for “medd”>Meddelande:</label>
<textarea rows=”4″ cols=”50″ class=”field” name=”comment” class=”textbox-1″ form=”usrform”></textarea>
<br><br>
<input type=”reset” value=”Rensa”>
<input type=”submit” value=”Skicka”>
</fieldset>
</div>
</form>
/Ashley

to post a comment
CSSHTML

1 Comments(s)

Copy linkTweet thisAlerts:
@sibertMay 15.2022 — I guess you can redirect after submitting to another page using PHP, Javascript or whatever language you prefer. Here is my code (Go) after a validation send the user to either error or mailok page.

Look at this as a pseudocode:

``<i>
</i>err := smtp.SendMail("yoursmtp.com:587", auth, r.FormValue("mail"), to, mime)
if err != nil {
tpl.ExecuteTemplate(w, "error.html", "")
} else {
tpl.ExecuteTemplate(w, "mailok.html", "")
}<i>
</i>
``


live: https://static.go4webdev.org/contact
×

Success!

Help @Ashley128 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 3.28,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,

tipper: Anonymous,
tipped: article
amount: 10 SATS,
)...