24 lines
571 B
Python
24 lines
571 B
Python
|
#!/usr/bin/env python
|
||
|
# encoding: utf-8
|
||
|
|
||
|
|
||
|
FILENAME="3ePro.csv"
|
||
|
|
||
|
lgn_tpl = '<li><a href="http://192.168.230.4/~{id}" > {nom} {prenom} </a> </li>'
|
||
|
|
||
|
with open(FILENAME,'r') as f:
|
||
|
for l in f.readlines():
|
||
|
nom, prenom = l.split(',')
|
||
|
prenom = prenom[:-1]
|
||
|
#print(nom)
|
||
|
#print(prenom)
|
||
|
id = prenom.lower()[0] + nom.lower()
|
||
|
#print(id)
|
||
|
print(lgn_tpl.format(id = id, nom = nom, prenom = prenom))
|
||
|
|
||
|
|
||
|
# -----------------------------
|
||
|
# Reglages pour 'vim'
|
||
|
# vim:set autoindent expandtab tabstop=4 shiftwidth=4:
|
||
|
# cursor: 16 del
|