--- /dev/null
+<?php
+ $fp=fopen("/etc/ssl/xorgCA/cacert.pem","r");
+ $data=fread($fp,10000);
+ fclose($fp);
+ Header("Content-Type: application/x-x509-ca-cert");
+ Header("Content-Length: ".strlen($data));
+ echo $data;
+?>
--- /dev/null
+<?php
+require("db_connect.inc.php");
+require("controlpermanent.inc.php");
+require_once("appel.inc.php");
+require_once("validations.inc.php");
+
+// getdata.php3 - by Florian Dittmer <dittmer@gmx.net>
+// Example php script to demonstrate the direct passing of binary data
+// to the user. More infos at http://www.phpbuilder.com
+// Syntax: getdata.php3?id=<id>
+
+if(isset($_REQUEST['x'])) {
+ if(isset($_REQUEST['req']) && $_REQUEST['req']="true") {
+ $myphoto = PhotoReq::get_unique_request($_REQUEST['x']);
+ Header("Content-type: image/".$myphoto->mimetype);
+ echo $myphoto->data;
+ } else {
+ $result = mysql_query("SELECT attachmime, attach FROM photo WHERE uid = '{$_REQUEST['x']}'");
+
+ if( list($type,$data) = @mysql_fetch_row($result) ) {
+ Header( "Content-type: image/$type");
+ echo $data;
+ } else {
+ Header( "Content-type: image/png");
+ $f=fopen(url("none.png"),"r");
+ echo fread($f,30000);
+ fclose($f);
+ }
+ }
+}
+?>
--- /dev/null
+<?php
+require("auto.prepend.inc.php");
+new_skinned_page('stats/nb_by_promo.tpl', AUTH_COOKIE);
+
+$result = mysql_query("SELECT promo,COUNT(*) FROM auth_user_md5 WHERE promo > 1900 GROUP BY promo ORDER BY promo");
+$max=0; $min=3000;
+while(list($promo,$nb)=mysql_fetch_row($result)) {
+ $promo=intval($promo);
+ if(!isset($nbpromo[$promo/10]))
+ $nbpromo[$promo/10] = Array('','', '','', '','', '','', '','');
+ $nbpromo[$promo/10][$promo%10]=$nb;
+}
+
+$page->assign_by_ref('nbs', $nbpromo);
+$page->assign('min', $min-$min % 10);
+$page->assign('max', $max+10-$max%10);
+
+$page->display();
+?>
--- /dev/null
+{* $Id: nb_by_promo.tpl,v 1.1 2004-01-27 21:17:43 x2000habouzit Exp $ *}
+
+<div class="rubrique">
+ Inscrits par promo
+</div>
+
+<p class="normal">
+Voici le nombre d'inscrits par promo :
+</p>
+
+{dynamic}
+<table class="bicol" cellpadding="3" cellspacing="0" summary="Statistiques">
+ <tr>
+ <th></th>
+ <th>0</th><th>1</th><th>2</th><th>3</th><th>4</th>
+ <th>5</th><th>6</th><th>7</th><th>8</th><th>9</th>
+ </tr>
+ {foreach item=nb10 key=lustre from=$nbs}
+ <tr>
+ <th>{$lustre}-</th>
+ {foreach item=nb from=$nb10}
+ <td class="center">{$nb|default:"-"}</td>
+ {/foreach}
+ </tr>
+ {/foreach}
+</table>
+{/dynamic}
+
+<div class="rubrique">
+ Inscrits par promo en (%)
+</div>
+
+<img src="/stats/graph-promo2.png" />
+
+{* vim:set et sw=2 sts=2 sws=2: *}