Modèle:Légifrance/Bac à sable2
[[[:Modèle:Legifrance/derive-url]] Modèle:Legifrance/base-decode, 16-1]
Use this template when you wish to create an external link to French legal text as provided by Légifrance, the official website of the French government for publication of legislation, regulations, and legal information.
Usage
modifier{{ Legifrance | base=database| number=article number| text=Display text for link}}
Note: parameter aliases are provided to make it possible to copy-paste directly from French Wikipedia, so the following is equivalent to the above:
{{ Légifrance | base=database| numéro=article number| texte=Display text for link}}
Note on spelling
modifierIn French, the name of the website is Légifrance, including the accented "e" letter. To make it easier to use this template with English qwerty keyboards, and in conformity with the majority of English sources that refer to the website without the accented letter, the name of this template is "Legifrance", without the accent. In order to facilitate ease of use by copy-pasting directly from sources on French Wikipedia, the accented version is available as a redirect, and can be used as well.
Parameters
modifierThere are five named parameters, two required and three optional. Either base and number, or text and url must be present.
|base=
– a token indicating which part of the code, e.g. Modèle:Pval for the penal code, Modèle:Pval for the Journal officiel, Modèle:Pval for the Civil Code, and so on. Required. See the table below for list of possible values. (See Modèle:Slink for an explanation of these values (in French)).|number=
– article number in the given code base; e.g, Modèle:Pval, Modèle:Pval. Required. Aliases: 'numéro', 'num'.|text=
– display text; visible text underlying the wikilink to the article at Légifrance. Optional.Default: <base> 'art.' <number>. Alias: 'texte'.|url=
– optional url of the Légifrance article to display. Normally this param should be omitted, as the url value is calculated by the template as a function of base and number. However if required,|url=
may be used to override the default value, such as to create a link to a page grouping several related articles; see Example 4 below.|lang=
– optional language code to use to generate the default value for|text=
, when only base and number are given, and text is omitted. Values: Modèle:Pval or Modèle:Pval; default: Modèle:Pval.
- Param notes
|base=
– see the table in Modèle:Slink.|number=
– adjustments for punctuation and embedded spaces: as a general rule, drop them:- for legislative acts beginning with Modèle:Pval – drop the punctuation and embedded space: Modèle:Pval ⟶ Modèle:Pval.
- for regulatory acts beginning with Modèle:Pval – drop the space and punct., i.e., Modèle:Pval ⟶ Modèle:Pval
- for embedded spaces prior to a suffix, url encode the space; e.g., Modèle:Pval ⟶ Modèle:Pval
- sometimes add a slash in the suffix, instead of url-encoded space, e.g., Modèle:Pval ⟶ Modèle:Pval
In footnotes
modifierTwo templates are available for generating footnotes related to Légifrance:
- (tl) – generates a full citation for the Légifrance website (wraps (tl)Modèle:Hairspace); may be used either for inline citations, or in the reference list to anchor a short citation;
- (tl) – generates a short citation to a French law or legal text indexed in Légifrance (wraps (tl)Modèle:Hairspace).
Usage notes
modifier- Why use this template?
The Légifrance website provides a search interface to the entire body of French law going back to 1529, including every version and every amendment of every bill. The underlying database is comprehensive, but this also means finding a specific law may be difficult; simple keyword search may turn up thousands of similar results. This template, in many cases, will do the work of finding the correct item for you, and create a link to it. Three templates are available: one to create an external link to the law, one to create a full citation to the Légifrance website appropriate for the "References" section, and one to generate a short citation.
If you know how to find the law you are interested in on the Légifrance website and how to create a citation for it using either an inline reference, or a short citation ((tl)), then you don't need this template, although it makes the procedure easier, as it does much of the work for you.
- What's the relation between this template and the other Legifrance templates?
- (tl) – generates an external link (not a citation) to a specific law, calculating the external link based on the 'base' and 'number' params to locate a specific law. It could be used in the , and is used by the other two templates to calculate the external link to the law on the Légifrance website.
- (tl) wraps template (tl) to generate a short citation. It links the short citation to the full citation lower on the page as defined by the (tl) template, and also names and links to the externally defined French law.
- (tl) – generates a full citation to the Legifrance website. This may be used in two ways: when used with no parameters and placed in the "References" or "Works cited" section, it fully specifies the source and provides an anchor for short citations generated by (tl); when used this way, it may be paired with (tl) and provides automatic linkage for it. Secondly, when used inline with 'base' and 'number' parameters and embedded in <ref>...</ref> tags, it generates a full inline reference to a specific law, suitable for pairing with named references inline, if desired.
Examples
modifierTo cite article 62-2 of the CPP (French criminal procedure code) about garde à vue, or the law about dol, you could code:
- 1a.
{{[[:Modèle:Legifrance|LegifranceModèle:!))|base=CPP |number=62-2 |text=CPP Art. 62-2 }}
- 1b.
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CC |number=1137 |text=Art. 1137 of the Civil Code }}
You can use the accented "é" version, and param aliases to generate the same link as above, using original French param names, if you've copy/pasted directly from an article on French Wikipedia to generate the same link:
- 2.
{{[[:Modèle:Légifrance|LégifranceModèle:!))|base=CPP |numéro=62-2 |texte=CPP Art. 62-2 }}
Or, use with only two params, and allow the template to default the value of param |text=
:
- 3a.
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CC |number=1137 }}
- 3b.
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CTRANSP|number=L1000-2}}
- 3c.
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CPEN|number=R622-1}}
The following demonstrates the use of optional param |url=
to supply a link to a group of related articles:
- 4. {{legifrance |base=CPP|num=75|url=https://www.legifrance.gouv.fr/codes/section_lc/LEGITEXT000006071154/LEGISCTA000006151877/#LEGISCTA000006151877}} → ??? Légifrance : texte oublié
Add the |lang=fr
param, if you want the base token to expand in French instead:
- 5a
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CGCT|number=LO1114-1}}
- 5b
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CGCT|number=LO1114-1|lang=fr}}
- 5c
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CPEN|number=L112-1}}
- 5d
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CTRANSP|number=R1112-11|lang=fr}}
Some error cases: if the value of |base=
is not valid, you get this:
- 6a
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=NOGUD |number=123-4 }}
If the value of |number=
is not a real article in the code, for pre-2008 codes (pre-modernization), you get a link that looks legitimate, but clicking it goes to an "Erreur 500" page at Légifrance:
- 6b
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CPP |number=9876-54321 }}
For post-2008 codes (e.g., Transport, Penitentiary, etc.), you get a link that also gives an "Erreur 500" if you click, but the error is detected in advance, and the article id is all zeroes (mouse over to see it) (this behavior will change going forward):
- 6c
{{[[:Modèle:Legifrance|legifranceModèle:!))|base=CPEN|number=L9999-888}}
Legifrance databases and 'base' values
modifierThis template creates a direct link to a legal text or law. There are numerous different portions of French legal code which can have long names, like the Code général des collectivités territoriales. To avoid having to have such a long name as a template parameter, this template uses a short token which is used for the 'base' parameter instead of the long name; this base token is shown in all caps in the table below. Choose one of these tokens as the value for the 'base' parameter . Note: these tokens apply only to portions of the Legifrance database that existed in 2008 or earlier.[note 1] As a result, the syntax described here cannot be used to create links to portions of the code created since 2008, such as the code de transport.
To create a link to a legal text or law which is part of one of the post-2008 codes, find the link to the law of interest at Légifrance, and use optional template parameter |url=
to specify its value. (Or, just use the url directly, in template (tl) or (tl).)
Table
modifierLaw database to search | Detail | 'base' value | Example |
---|---|---|---|
Code de l'action sociale et des familles(br) Social action and family code | Legislative part | CACTSOCL | |
Code de l'aviation civile
Civil aviation code |
Legislative part | CAVIAL | |
decrees by the Conseil d'État | CAVIAR | ||
Simple decrees part | CAVIAD | ||
Code civil Civil code | CC | ??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié | |
Code de commerce Commercial code | CCOM | ??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié | |
Code de la consommation
Consumer code |
Legislative part | CONSO | |
decrees of the Conseil d'État | CONSO(R) | ||
Simple decrees part | CONSO(D) | ||
Code de la construction et de l'habitation
Construction and housing code |
Legislative part | CCONSTRL | |
Regulatory part - décrets en Conseil d'État | CCONSTRR | ||
Code de la défense
Defense code |
Legislative part | CDEF | |
Regulatory part | CDEF(R) | ||
Code de l'éducation
Education code |
Legislative part | CEDU | ??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié |
Regulatory part | CEDU(R) | ||
Code de l'entrée et du séjour(br) des étrangers et du droit d'asile
Entry, foreign residence, and right of asylum code |
Legislative part | CESEDA(L) | |
Regulatory part | CESEDA(R) | ||
Code de l'environnement
Environment code |
Legislative part | CE | |
Regulatory part | CE(R) | ||
Code électoral
Electoral code |
Legislative part | CELE | |
Regulatory part | CELE(R) | ||
Code général des collectivités territoriales
General code of Territorial Authorities code |
Legislative part | CGCT | ??? Légifrance : numéro oublié |
Regulatory part | CGCT(R) | ||
Code général des impôts General tax code | CGI | ||
Code général de la propriété(br)des personnes publiques
General code of public property |
CGPPP | ||
Code des juridictions financières
Financial jurisdiction code |
Legislative part | CJF(L) | |
Regulatory part | CJF(R) | ||
Code de justice administrative
Administrative justice code |
Legislative part | CJA | ??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié |
Regulatory part | CJA(R) | ||
Code monétaire et financier
Monetary and financial code |
Legislative part | CMONFIL | |
Regulatory part | CMONFIR | ||
Code de l'organisation judiciaire
Judicial Organization code |
new Legislative part | COJ | |
Legislative part | COJ(L) | ||
Regulatory part | COJ(R) | ||
Code du patrimoine Heritage code | CPAT | ||
Code pénal Penal code | Legislative part | CP | ??? Légifrance : numéro oublié |
Regulatory part | CP(R) | ||
Code pénal (ancien) Penal code of 1810 | CP1810 | ||
Code pénitentiaire Penitentiary code | CPEN | ??? Légifrance : base non référencée [??? ???] Légifrance : numéro oublié(br)??? Légifrance : base non référencée [??? ???] Légifrance : numéro oublié(br)??? Légifrance : base non référencée [??? ???] Légifrance : numéro oublié | |
Code des postes et des(br)communications électroniques
Post and electronic communications code |
Legislative part | CPOSTESL | |
Regulatory part | CPOSTESR | ||
Code de procédure civile
Civil procedure code |
NCPC | ??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié | |
Code de procédure civile (ancien)
Civil procedure code (old) |
CPC | ||
Code de procédure pénale
Criminal procedure code |
Legislative part | CPP | ??? Légifrance : numéro oublié(br) ??? Légifrance : texte oublié |
Regulatory part | CPP(R) | ||
Simple decrees part | CPP(D) | ||
partie arrêtés | CPP(A) | ||
Code de la propriété intellectuelle
Intellectual property code |
Legislative part | CPROINTL | |
Regulatory part | CPROINTR | ||
Code de la route
Highway code |
new Legislative part | CRO | |
Legislative part | CROUTEL | ||
new regulatory part | CRO(M) | ||
Regulatory part | CROUTER | ||
Code rural et de la pêche maritime
Rural and maritime fisheries code |
Legislative part | CR | |
Regulatory part | CR(R) | ||
Code de la santé publique
Public health code |
new legislative part | CSP | |
Legislative part | CSP(L) | ||
Regulatory part | CSP(R) | ||
nouvelle Regulatory part | CSP(NR) | ||
Code de la Sécurité sociale
Social security code |
Legislative part | CSS(L) | |
Simple decrees part | CSS(D) | ||
Regulatory part | CSS(R) | ||
Code du sport
Sports code |
Legislative part | CSPORTPL | |
Regulatory part | CSPORTPR | ||
partie arrêtés | CSPORTPA | ||
Code du travail
Labor code |
new legislative part from 1 May 2008 | CT(NL) | |
Legislative part | CT | ??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié | |
Regulatory part | CT(R) | ||
Simple decrees part | CT(D) | ||
Code des transports
Transport code |
CTRANSP | ??? Légifrance : base non référencée [??? ???] Légifrance : numéro oublié(br)??? Légifrance : base non référencée [??? ???] Légifrance : numéro oublié(br)??? Légifrance : base non référencée [??? ???] Légifrance : numéro oublié | |
Code de l'urbanisme
Urban planning code |
Legislative part | URBA(L) | |
Regulatory part | URBA(R) | ||
Code de la voirie routière
Roads and highways code |
Legislative part | CVOIRIEL | |
Regulatory part | CVOIRIER | ||
Livre des procédures fiscales
Tax procedure book |
Legislative part | CGLIVP | |
Regulatory part | CGLIVPFM | ||
partie arrêtés | CGLIVPFA | ||
Journal officiel de la République française | JORF | ??? Légifrance : numéro oublié(br)??? Légifrance : numéro oublié |
Other codes
modifier- Code de la sécurité intérieure (2012)
- Code des relations entre le public et l'administration (2016)
- Code des procédures civiles d'exécution (2012)
- Code de la justice pénale des mineurs (2021)
- Code des impositions sur les biens et services (2022)
- Code général de la fonction publique (2022)
- Code forestier (nouveau) (2012)
- Code de l'énergie (2011)
- Code de la commande publique (2019)
See also
modifier- (tl)
- (tl)
- (tl)
- (tl)
- (tl)
Notes
modifier- The rules regarding the permanence of pre-2008 urls were formerly indicated at the following address: Anciennes et nouvelles adresses ('Old and new addresses'; dead link). Currently, the page Etablir-un-lien ('Establish a link') indicates that the permanence of pre-2008 urls is guaranteed for two types of documents: texts published in the Journal officiel having a NOR number on the one hand, and codes or specific articles of codes existing in January 2008 on the other hand (which, apparently, does not include consolidated texts).
TemplateData
modifierAucune description.
Paramètre | Description | Type | État | |
---|---|---|---|---|
base | base | Legislation Database name
| Chaîne | suggéré |
url | url | Override url to use to link to the Légifrance article | Chaîne | facultatif |
text | text texte | Display text for the link to the article at Légifrance
| Chaîne | suggéré |
number | number num numéro | Article number in the given code base
| Chaîne | facultatif |
language | lang | Language in which the database section should be named when no 'text' param is provided
| Chaîne | facultatif |
La documentation de ce modèle est générée par le modèle {{Documentation}}.
Elle est incluse depuis sa sous-page de documentation. Veuillez placer les catégories sur cette page-là.
Les éditeurs peuvent travailler dans le bac à sable (créer) et la page de test (créer).
Voir les statistiques d'utilisation du modèle sur l'outil wstat.