FIX problème de gestion du profile, après ouverture d'une conversation puis enregistr...
[euphorik.git] / index.yaws
1 <?xml version="1.0" encoding="UTF-8" ?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
3 "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
4 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" >
5 <head>
6    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7    <title>euphorik.ch</title>
8    <erl>
9       % prédéfinit la feuille de style
10       out(A) -> 
11          CSS = case euphorik_bd:css_from_user_cookie(yaws_api:find_cookie_val("cookie", A)) of
12             undefined -> "styles/1/euphorik.css";
13             C -> C
14          end,
15          {ehtml, {link ,
16             [
17                {id, "cssPrincipale" },
18                {rel, "stylesheet"},
19                {href, CSS},
20                {type, "text/css"},
21                {media, "screen"}
22             ], []}
23          }.
24    </erl>
25    <link rel="stylesheet" href="css/jquery.lightbox.css" type="text/css" media="screen" ></link>
26
27    <script type="text/javascript" src="js/jquery.js" prod="delete"></script>
28    <script type="text/javascript" src="js/jquery.lightbox.js" prod="delete"></script>
29    <script type="text/javascript" src="js/md5.js" prod="delete"></script>
30    <script type="text/javascript" src="js/json2.js" prod="delete"></script>
31    <script type="text/javascript" src="js/comet.js" prod="delete"></script>
32
33    <script type="text/javascript" src="js/euphorik.js" ></script>
34
35    <script type="text/javascript" src="js/conf.js" prod="delete"></script>
36    <script type="text/javascript" src="js/util.js" prod="delete"></script>
37    <script type="text/javascript" src="js/formateur.js" prod="delete"></script>
38    <script type="text/javascript" src="js/pages.js" prod="delete"></script>
39    <script type="text/javascript" src="js/client.js" prod="delete"></script>
40
41    <script type="text/javascript" src="js/pageMinichat/pageMinichat.js" prod="delete"></script>
42    <script type="text/javascript" src="js/pageMinichat/conversation.js" prod="delete"></script>
43    <script type="text/javascript" src="js/pageMinichat/conversations.js" prod="delete"></script>
44    <script type="text/javascript" src="js/pageMinichat/message.js" prod="delete"></script>
45    <script type="text/javascript" src="js/pageMinichat/commandes.js" prod="delete"></script>
46    <script type="text/javascript" src="js/pageAdmin.js" prod="delete"></script>
47    <script type="text/javascript" src="js/pageProfile.js" prod="delete"></script>
48    <script type="text/javascript" src="js/pageRegister.js" prod="delete"></script>
49    <script type="text/javascript" src="js/pageAbout.js" prod="delete"></script>
50
51 </head>
52    <body>
53       <div id="container">
54          <erl>
55             % permet de prédéfinir la "class" du logo pour un ekMaster...
56             out(A) -> 
57                Est_ek_master = euphorik_bd:is_ek_master_from_cookie(yaws_api:find_cookie_val("cookie", A)),
58                {ehtml, {'div', [{id, "logo"}] ++ if Est_ek_master -> [{class, "ekMaster"}]; true -> [] end}}.
59                    
60          </erl>
61          <div id="info" style="display:none" ><div id="icone"></div><div class="fermer" ></div><div class="message" ></div><div class="boutons"></div></div>
62          <ul id="menu">
63             <li class="minichat">chat</li><li class="admin" style="display:none">admin</li><li class="profile"></li><li class="register">register</li><li class="logout">logout</li><li class="about">about</li>
64          </ul>
65          <form action="" id="formMenuCss">
66             <p>
67                <select id="menuCss">
68                   <erl>
69                      % parse les styles disponible
70                      out(A) ->
71                         Stlyes_dir = A#arg.docroot ++ "/styles",
72                         {ok, Liste_dir} = file:list_dir(Stlyes_dir),
73                         {ehtml, 
74                            lists:foldr(
75                               fun(Dir, Acc) ->
76                                  case file:consult(Stlyes_dir ++ "/" ++ Dir ++ "/infos.txt") of
77                                     {ok, [{nom, Nom}]} ->
78                                        [{option, [{value, Dir}], Nom} | Acc];
79                                     _ -> 
80                                        Acc
81                                  end
82                               end,
83                               [],
84                               Liste_dir
85                            )
86                         }.
87                   </erl>
88                   <!-- option value="1" selected="selected">Retro</option>
89                   <option value="2">Dark</option -->
90                </select>
91             </p>
92          </form> 
93          <div id="page"></div>
94          <div id="footer"><span class="copyright">copyright 2008 euphorik.ch</span><span class="conditions lien">conditions d'utilisation</span><a href="http://yaws.hyber.org"><img src="img/powered-by-yaws.gif" alt="powered by Yaws" /></a></div>
95       </div>
96    </body>
97 </html>