Travail sur formulaire de don

This commit is contained in:
Adrien Bourmault 2022-04-30 01:18:39 +02:00
parent 07f6188069
commit 869dc90126
No known key found for this signature in database
GPG Key ID: 6EB408FE0ACEC664
10 changed files with 1634 additions and 47 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 723 KiB

View File

@ -0,0 +1,73 @@
/*
========================================================================
Description : CSS stylesheet
Author : neox
Website : https://a-lec.org
License : AGPL
========================================================================
*/
form {
margin-top: 20px;
background: #fff9e4;
display: table;
margin-left: auto;
margin-right: auto;
box-shadow: 3px 3px 5px grey;
}
form *{
padding: 5px;
margin: 10px;
}
form p {
display: table-row;
}
form label {
display: table-cell;
text-align: left;
}
form .renseignements {
display: table-cell;
border-bottom: 2px solid var(--a-lec_blue);
border-radius: 3px;
background-color: lightcyan;
padding: 5px;
color: black;
}
form .renseignements:focus {
border-bottom: 2px solid var(--a-lec_red);
border-radius: 3px;
background-color: lightsalmon;
}
form select {
border-bottom: 2px solid var(--a-lec_blue);
border-radius: 3px;
background-color: lightcyan;
padding: 5px;
}
form .validation {
background-color: var(--a-lec_blue);
box-shadow: 3px 3px 5px grey;
color: white;
font-weight: bold;
border: none;
cursor: pointer;
float: right;
margin-bottom: -10px;
}
form .validation:focus {
display: table-cell;
background-color: var(--a-lec_red);
color: white;
font-weight: bold;
cursor: pointer;
box-shadow: none;
}

View File

@ -1,25 +0,0 @@
<form action="/my-handling-form-page" method="post">
<ul>
<li>
<label for="name">Nom et prénoms</label>
<input type="text" id="name" name="user_name">
</li>
<li>
<label for="address">Adresse postale</label>
<input type="text" id="mail" name="user_address">
</li>
<li>
<label for="mail">Courriel</label>
<input type="email" id="mail" name="user_email">
</li>
<li>
<label for="mail">Courriel (confirmation)</label>
<input type="email" id="mail" name="user_email">
</li>
<li>
<label for="amount">Somme versée</label>
<input type="number" min="1" step="any" name="user_amount">
</li>
</ul>
</form>

View File

@ -2,25 +2,25 @@
<html lang="fr">
<head>
<meta charset="UTF-8" />
<meta name='viewport' content="width=device-width, initial-scale=1.0">
<meta name='robots' content="all">
<meta name='generator' content="GSL: Statique Littérateur">
<meta name='medium' content='website'>
<meta name='revisit-after' content="3 days">
<meta name='viewport' content="width=device-width, initial-scale=1.0"/>
<meta name='robots' content="all"/>
<meta name='medium' content='website'/>
<meta name='revisit-after' content="3 days"/>
<title>Page introuvable - Libre en Communs</title>
<link rel="stylesheet" media="screen" href="/templates/styles_erreur.css" />
<title>Faire un don - Libre en Communs</title>
<link rel="stylesheet" media="screen" href="styles.css" />
<link rel="stylesheet" media="screen" href="form.css" />
<link rel="shortcut icon" type="image/png" href="favicon.png" />
<link rel='me' type='text/html' href="https://toot.a-lec.org/@a_lec">
<link rel='me' type='text/html' href="https://toot.a-lec.org/@a_lec"/>
<meta name='language' content="fr">
<meta name='reply-to' content="cominfra+www@a-lec.org">
<meta name='copyright' content="2022 Libre en Communs CC-BY-SA 4.0 sauf mention contraire">
<meta name='title' content="Accueil - Libre en Communs">
<meta name='author' content="neox">
<meta name='description' content="Bienvenue sur le site web de Libre en Communs, association française centrée sur le logiciel libre et les communs.">
<meta name='keywords' content="libre,free,communs,Logiciels Libres,Connaissance,Partage,Éducation,Solidarité">
<meta name='search_date' content="2021-07-01">
<meta name='language' content="fr"/>
<meta name='reply-to' content="cominfra+www@a-lec.org"/>
<meta name='copyright' content="2022 Libre en Communs CC-BY-SA 4.0 sauf mention contraire"/>
<meta name='title' content="Accueil - Libre en Communs"/>
<meta name='author' content="neox"/>
<meta name='description' content="Faire un don au profit de Libre en Communs"/>
<meta name='keywords' content="don,libre,free,communs,Logiciels Libres,Connaissance,Partage,Éducation,Solidarité"/>
<meta name='search_date' content="2021-07-01"/>
</head>
<body id="a-lec_page">
@ -28,7 +28,7 @@
<header id="a-lec_banner">
<div id="a-lec_site-logo">
<a href="/">
<img src="/templates/logo_a-lec.svg"
<img src="logo_a-lec.svg"
alt="Logo de Libre en Communs"
title="Logo de Libre en Communs"/>
</a>
@ -47,9 +47,36 @@
<section id="a-lec_page-wrapper">
<article id="a-lec_index">
<img src="/templates/logo_404.svg" class="a-lec_image_center" alt="Erreur 404" title="Erreur 404" style="width:50%;"/>
<br/>
<b style="font-size: 200%;text-align:center;">Page introuvable</b>
<form action="/my-handling-form-page" method="post">
<p>
<label for="nom">Nom</label>
<input class="renseignements" type="text" id="nom" name="nom"/>
</p>
<p>
<label for="prenom">Prénom(s)</label>
<input class="renseignements" type="text" id="prenom" name="prenom"/>
</p>
<p>
<label for="adresse">Adresse postale</label>
<input class="renseignements" type="text" id="adresse" name="adresse"/>
</p>
<p>
<label for="mail">Courriel</label>
<input class="renseignements" type="email" id="mail" name="mail"/>
</p>
<p>
<label for="mailconfirm">Courriel (confirmation)</label>
<input class="renseignements" type="email" id="mailconfirm" name="mailconfirm"/>
</p>
<p>
<label for="somme">Somme versée (EUR)</label>
<input class="renseignements" type="number" min="1" step="any" name="somme"/>
</p>
<p>
<label><br/></label>
<input class="validation" type="submit" value="Valider le don">
</p>
</form>
</article>

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 175 KiB

View File

@ -97,7 +97,7 @@ header {
background: #2d4b63; /* old IE fallback */
background-attachment: fixed;
background-image: url(../templates/electronic.png);
background-image: url(electronic.png);
background-position: 0 0;
background-repeat: cover;
background-size: auto;
@ -164,7 +164,7 @@ footer {
background: #2d4b63; /* old IE fallback */
background-attachment: fixed;
background-image: url(../templates/electronic.png);
background-image: url(electronic.png);
background-position: 0 0;
background-repeat: cover;
background-size: auto;

13
Reçus/RECU_FISCAL.aux Normal file
View File

@ -0,0 +1,13 @@
\relax
\@writefile{toc}{\contentsline {subparagraph}{Dénomination}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Statut}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Adresse}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Nom ou dénomination}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Statut}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Adresse}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Somme (EUR)}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Date du versement}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Forme}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Nature}{}{}\protected@file@percent }
\@writefile{toc}{\contentsline {subparagraph}{Mode de versement}{}{}\protected@file@percent }
\gdef \@abspage@last{1}

285
Reçus/RECU_FISCAL.log Normal file
View File

@ -0,0 +1,285 @@
This is pdfTeX, Version 3.141592653-2.6-1.40.22 (TeX Live 2022/dev/Debian) (preloaded format=pdflatex 2022.4.29) 29 APR 2022 01:20
entering extended mode
restricted \write18 enabled.
%&-line parsing enabled.
**RECU_FISCAL.tex
(./RECU_FISCAL.tex
LaTeX2e <2021-11-15> patch level 1
L3 programming layer <2022-01-21>
(/usr/share/texlive/texmf-dist/tex/latex/base/article.cls
Document Class: article 2021/10/04 v1.4n Standard LaTeX document class
(/usr/share/texlive/texmf-dist/tex/latex/base/size10.clo
File: size10.clo 2021/10/04 v1.4n Standard LaTeX file (size option)
)
\c@part=\count185
\c@section=\count186
\c@subsection=\count187
\c@subsubsection=\count188
\c@paragraph=\count189
\c@subparagraph=\count190
\c@figure=\count191
\c@table=\count192
\abovecaptionskip=\skip47
\belowcaptionskip=\skip48
\bibindent=\dimen138
)
(/usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty
Package: graphicx 2021/09/16 v1.2d Enhanced LaTeX Graphics (DPC,SPQR)
(/usr/share/texlive/texmf-dist/tex/latex/graphics/keyval.sty
Package: keyval 2014/10/28 v1.15 key=value parser (DPC)
\KV@toks@=\toks16
)
(/usr/share/texlive/texmf-dist/tex/latex/graphics/graphics.sty
Package: graphics 2021/03/04 v1.4d Standard LaTeX Graphics (DPC,SPQR)
(/usr/share/texlive/texmf-dist/tex/latex/graphics/trig.sty
Package: trig 2021/08/11 v1.11 sin cos tan (DPC)
)
(/usr/share/texlive/texmf-dist/tex/latex/graphics-cfg/graphics.cfg
File: graphics.cfg 2016/06/04 v1.11 sample graphics configuration
)
Package graphics Info: Driver file: pdftex.def on input line 107.
(/usr/share/texlive/texmf-dist/tex/latex/graphics-def/pdftex.def
File: pdftex.def 2020/10/05 v1.2a Graphics/color driver for pdftex
))
\Gin@req@height=\dimen139
\Gin@req@width=\dimen140
)
(/usr/share/texlive/texmf-dist/tex/latex/tabto-ltx/tabto.sty
Package: tabto 2018/12/28 v 1.4 Another tabbing mechanism
\CurrentLineWidth=\dimen141
\TabPrevPos=\dimen142
)
(/usr/share/texlive/texmf-dist/tex/latex/datetime/datetime.sty
Package: datetime 2015/03/20 v2.60 Date Time Package
(/usr/share/texlive/texmf-dist/tex/latex/etoolbox/etoolbox.sty
Package: etoolbox 2020/10/05 v2.5k e-TeX tools for LaTeX (JAW)
\etb@tempcnta=\count193
)
(/usr/share/texlive/texmf-dist/tex/latex/fmtcount/fmtcount.sty
Package: fmtcount 2020/01/30 v3.07
(/usr/share/texlive/texmf-dist/tex/latex/base/ifthen.sty
Package: ifthen 2020/11/24 v1.1c Standard LaTeX ifthen package (DPC)
)
(/usr/share/texlive/texmf-dist/tex/latex/xkeyval/xkeyval.sty
Package: xkeyval 2020/11/20 v2.8 package option processing (HA)
(/usr/share/texlive/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/share/texlive/texmf-dist/tex/generic/xkeyval/xkvutils.tex
\XKV@toks=\toks17
\XKV@tempa@toks=\toks18
)
\XKV@depth=\count194
File: xkeyval.tex 2014/12/03 v2.7a key=value parser (HA)
))
(/usr/share/texlive/texmf-dist/tex/latex/fmtcount/fcprefix.sty
Package: fcprefix 2012/09/28
(/usr/share/texlive/texmf-dist/tex/latex/fmtcount/fcnumparser.sty
Package: fcnumparser 2017/06/15
\fc@digit@counter=\count195
))
(/usr/share/texlive/texmf-dist/tex/latex/amsmath/amsgen.sty
File: amsgen.sty 1999/11/30 v2.0 generic functions
\@emptytoks=\toks19
\ex@=\dimen143
)
\c@padzeroesN=\count196
\fc@tmpcatcode=\count197
\@DT@modctr=\count198
\@ordinalctr=\count199
\@orgargctr=\count266
\@strctr=\count267
\@tmpstrctr=\count268
\@DT@loopN=\count269
\@DT@X=\count270
)
(/usr/share/texlive/texmf-dist/tex/latex/datetime/datetime-defaults.sty
Package: datetime-defaults 2013/09/10
)
\@day=\count271
\@month=\count272
\@year=\count273
\c@HOUR=\count274
\c@HOURXII=\count275
\c@MINUTE=\count276
\c@TOHOUR=\count277
\c@TOMINUTE=\count278
\c@SECOND=\count279
\currenthour=\count280
\currentminute=\count281
\currentsecond=\count282
Package datetime Info: No datetime.cfg file found, using default settings on in
put line 308.
\@dtctr=\count283
\dayofyear=\count284
\dayofweek=\count285
LaTeX Info: Redefining \today on input line 736.
\dt@a=\toks20
\dt@b=\toks21
)
(/usr/share/texlive/texmf-dist/tex/latex/geometry/geometry.sty
Package: geometry 2020/01/02 v5.9 Page Geometry
(/usr/share/texlive/texmf-dist/tex/generic/iftex/ifvtex.sty
Package: ifvtex 2019/10/25 v1.7 ifvtex legacy package. Use iftex instead.
(/usr/share/texlive/texmf-dist/tex/generic/iftex/iftex.sty
Package: iftex 2020/03/06 v1.0d TeX engine tests
))
\Gm@cnth=\count286
\Gm@cntv=\count287
\c@Gm@tempcnt=\count288
\Gm@bindingoffset=\dimen144
\Gm@wd@mp=\dimen145
\Gm@odd@mp=\dimen146
\Gm@even@mp=\dimen147
\Gm@layoutwidth=\dimen148
\Gm@layoutheight=\dimen149
\Gm@layouthoffset=\dimen150
\Gm@layoutvoffset=\dimen151
\Gm@dimlist=\toks22
Package geometry Warning: `tmargin' and `bmargin' result in NEGATIVE (-58.32816
pt).
`height' should be shortened in length.
) (/usr/share/texlive/texmf-dist/tex/latex/l3backend/l3backend-pdftex.def
File: l3backend-pdftex.def 2022-01-12 L3 backend support: PDF output (pdfTeX)
\l__color_backend_stack_int=\count289
\l__pdf_internal_box=\box50
)
No file RECU_FISCAL.aux.
\openout1 = `RECU_FISCAL.aux'.
LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 37.
LaTeX Font Info: ... okay on input line 37.
LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 37.
LaTeX Font Info: ... okay on input line 37.
LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 37.
LaTeX Font Info: ... okay on input line 37.
LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 37.
LaTeX Font Info: ... okay on input line 37.
LaTeX Font Info: Checking defaults for TS1/cmr/m/n on input line 37.
LaTeX Font Info: ... okay on input line 37.
LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 37.
LaTeX Font Info: ... okay on input line 37.
LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 37.
LaTeX Font Info: ... okay on input line 37.
(/usr/share/texlive/texmf-dist/tex/context/base/mkii/supp-pdf.mkii
[Loading MPS to PDF converter (version 2006.09.02).]
\scratchcounter=\count290
\scratchdimen=\dimen152
\scratchbox=\box51
\nofMPsegments=\count291
\nofMParguments=\count292
\everyMPshowfont=\toks23
\MPscratchCnt=\count293
\MPscratchDim=\dimen153
\MPnumerator=\count294
\makeMPintoPDFobject=\count295
\everyMPtoPDFconversion=\toks24
) (/usr/share/texlive/texmf-dist/tex/latex/epstopdf-pkg/epstopdf-base.sty
Package: epstopdf-base 2020-01-24 v2.11 Base part for package epstopdf
Package epstopdf-base Info: Redefining graphics rule for `.eps' on input line 4
85.
(/usr/share/texlive/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg
File: epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Liv
e
))
(/usr/share/texlive/texmf-dist/tex/latex/fmtcount/fc-english.def
File: fc-english.def 2016/01/12
)
*geometry* driver: auto-detecting
*geometry* detected driver: pdftex
*geometry* verbose mode - [ preamble ] result:
* driver: pdftex
* paper: a4paper
* layout: <same size as paper>
* layoutoffset:(h,v)=(0.0pt,0.0pt)
* modes:
* h-part:(L,W,R)=(45.80893pt, 505.89pt, 45.80894pt)
* v-part:(T,H,B)=(-23.33124pt, 903.375pt, -34.99692pt)
* \paperwidth=597.50787pt
* \paperheight=845.04684pt
* \textwidth=505.89pt
* \textheight=903.375pt
* \oddsidemargin=-26.46106pt
* \evensidemargin=-26.46106pt
* \topmargin=-132.60123pt
* \headheight=12.0pt
* \headsep=25.0pt
* \topskip=10.0pt
* \footskip=30.0pt
* \marginparwidth=65.0pt
* \marginparsep=11.0pt
* \columnsep=10.0pt
* \skip\footins=9.0pt plus 4.0pt minus 2.0pt
* \hoffset=0.0pt
* \voffset=0.0pt
* \mag=1000
* \@twocolumnfalse
* \@twosidefalse
* \@mparswitchfalse
* \@reversemarginfalse
* (1in=72.27pt=25.4mm, 1cm=28.453pt)
<header.png, id=1, 2409.0pt x 662.475pt>
File: header.png Graphic file (type png)
<use header.png>
Package pdftex.def Info: header.png used on input line 39.
(pdftex.def) Requested size: 597.50787pt x 164.31433pt.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <12> on input line 39.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <8> on input line 39.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <6> on input line 39.
LaTeX Warning: No \author given.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <7> on input line 48.
LaTeX Font Info: External font `cmex10' loaded for size
(Font) <5> on input line 48.
LaTeX Font Info: Trying to load font information for TS1+cmss on input line
83.
(/usr/share/texlive/texmf-dist/tex/latex/base/ts1cmss.fd
File: ts1cmss.fd 2019/12/16 v2.5j Standard LaTeX font definitions
)
<tresorier.png, id=3, 872.50969pt x 401.24907pt>
File: tresorier.png Graphic file (type png)
<use tresorier.png>
Package pdftex.def Info: tresorier.png used on input line 114.
(pdftex.def) Requested size: 93.95122pt x 43.20078pt.
[1
{/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map} <./header.png> <./tresorier
.png>]
(./RECU_FISCAL.aux) )
Here is how much of TeX's memory you used:
3294 strings out of 480104
53028 string characters out of 5892285
365566 words of memory out of 5000000
21236 multiletter control sequences out of 15000+600000
474749 words of font info for 46 fonts, out of 8000000 for 9000
81 hyphenation exceptions out of 8191
70i,6n,79p,1006b,309s stack positions out of 5000i,500n,10000p,200000b,80000s
</home/neox/.texlive2021/texmf-var/fonts/pk/ljfour/jknapp
en/ec/tcss1000.600pk></usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts
/cm/cmss10.pfb></usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cm
ss17.pfb></usr/share/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmssbx10
.pfb>
Output written on RECU_FISCAL.pdf (1 page, 303061 bytes).
PDF statistics:
32 PDF objects out of 1000 (max. 8388607)
18 compressed objects within 1 object stream
0 named destinations out of 1000 (max. 500000)
11 words of extra memory for PDF output out of 10000 (max. 10000000)

Binary file not shown.

45
Reçus/generer.sh Executable file
View File

@ -0,0 +1,45 @@
#!/bin/bash
# $1 : NOM-DONATEUR
# $2 : STATUT-DONATEUR
# $3 : ADRESSE-DONATEUR
# $4 : SOMME
# $5 : DATE-VERSEMENT
# $6 : FORME-DON
# $7 : NATURE-DON
# $8 : MODE-VERSEMENT
set -e
#exec {BASH_XTRACEFD}> >(tail -n 1) # send set -x output to tail -n 1
#PS4=':At line $LINENO; prior command exit status $?+'
#set -x
if [ $# -ne 8 ]; then
echo "Nombre d'arguments incorrect"
exit 1
fi
FILE="$1"_reçu_$(echo $5 | tr "/" ".").tex
NOM_DONATEUR=$(echo $1 | tr "/" ".")
STATUT_DONATEUR=$(echo $2 | tr "/" ".")
ADRESSE_DONATEUR=$(echo $3 | tr "/" ".")
SOMME=$(echo $4 | tr "/" ".")
DATE_VERSEMENT=$(echo $5 | tr "/" ".")
FORME_DON=$(echo $6 | tr "/" ".")
NATURE_DON=$(echo $7 | tr "/" ".")
MODE_VERSEMENT=$(echo $8 | tr "/" ".")
cat RECU_FISCAL.tex > "$FILE"
sed -i "s/NOM-DONATEUR/$NOM_DONATEUR/" "$FILE"
sed -i "s/STATUT-DONATEUR/$STATUT_DONATEUR/" "$FILE"
sed -i "s/ADRESSE-DONATEUR/$ADRESSE_DONATEUR/" "$FILE"
sed -i "s/SOMME/$SOMME/" "$FILE"
sed -i "s/DATE-VERSEMENT/$DATE_VERSEMENT/" "$FILE"
sed -i "s/FORME-DON/$FORME_DON/" "$FILE"
sed -i "s/NATURE-DON/$NATURE_DON/" "$FILE"
sed -i "s/MODE-VERSEMENT/$MODE_VERSEMENT/" "$FILE"
pdflatex "$FILE"