This file contains 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
wp_register_style( | |
'ag7/ag7-pdf-viewer-editor-css', // Handle. | |
MY_PLUGIN_URL . 'blocks/dist/blocks.editor.build.css', // Block editor CSS. | |
array('wp-edit-blocks'), // Dependency to include the CSS after it. | |
null // filemtime( plugin_dir_path( __DIR__ ) . 'dist/blocks.editor.build.css' ) // Version: File modification time. | |
); |
This file contains 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
map $sent_http_content_type $expires { | |
default off; | |
text/html epoch; | |
text/css max; | |
application/javascript max; | |
~image/ max; | |
} | |
server { |
This file contains 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
function main() { | |
const sheet = SpreadsheetApp.getActiveSheet(); | |
const [columns, ...data] = sheet.getDataRange().getValues(); | |
data.forEach(function (row, i) { | |
let y = 0; | |
const values = columns.reduce((prev, column, i) => { | |
y = i; | |
return { ...prev, [column]: row[i] } |
This file contains 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
function onFormSubmit(e) { | |
var values = e.namedValues; | |
Logger.log(values); | |
var email = values["Adresse e-mail"][0]; // L'adresse email de la personne qui a répondu est stockée dans la deuxième colonne du formulaire | |
var sujet = "Merci d'avoir répondu à notre formulaire"; | |
var corps = "Bonjour,Merci d'avoir répondu. Nous avons bien reçu vos réponses. Voici vos réponses : "; | |
corps += "<ul>"; | |
for (Key in values) { | |
var label = Key; |
This file contains 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
function sendEmails(sheet = SpreadsheetApp.getActiveSheet()) { | |
const emailTemplate = getGmailTemplateFromDrafts_("test email"); | |
const RECIPIENT_COL = "Adresse e-mail"; | |
const dataRange = sheet.getDataRange(); | |
const data = dataRange.getDisplayValues(); | |
const rowNumber = dataRange.getLastRow(); | |
const heads = data.shift(); | |
const obj = data.map(r => (heads.reduce((o, k, i) => (o[k] = r[i] || '', o), {}))); | |
const row = obj[rowNumber - 2]; |
This file contains 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
const MAIN_SHEET = "Feuille 1" | |
function createEvenements() { | |
let ss = SpreadsheetApp.getActive(); | |
let spreadSheet = SpreadsheetApp.getActiveSheet(); | |
let lastRow = spreadSheet.getLastRow(); | |
let data = spreadSheet.getRange("A1:E" + lastRow).getValues(); | |
const agenda = CalendarApp.getCalendarById('xxxxx@gmail.com'); | |
const evenements = [] | |
for (var i = 1; i < data.length; i++) { |