Rev 264 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed
<?php/*mychanges.phpCopyright (c) 2003, Carlo ZottmannCopyright 2003 David DELONCopyright 2003 Charles NEPOTEAll rights reserved.Redistribution and use in source and binary forms, with or withoutmodification, are permitted provided that the following conditionsare met:1. Redistributions of source code must retain the above copyrightnotice, this list of conditions and the following disclaimer.2. Redistributions in binary form must reproduce the above copyrightnotice, this list of conditions and the following disclaimer in thedocumentation and/or other materials provided with the distribution.3. The name of the author may not be used to endorse or promote productsderived from this software without specific prior written permission.THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS ORIMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIESOF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUTNOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANYTHEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OFTHIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.*/if ($user = $this->GetUser()){$my_edits_count = 0;if (($bydate = $this->GetParameter("bydate"))){echo "<b>Liste des pages que vous avez modifiées, triée par date de modification.</b><br /><br />\n";if ($pages = $this->LoadAll("SELECT tag, time FROM ".$this->config["table_prefix"]."pages WHERE user = '".mysql_escape_string($this->UserName())."' AND tag NOT LIKE 'Comment%' ORDER BY time ASC, tag ASC")){foreach ($pages as $page){$edited_pages[$page["tag"]] = $page["time"];}arsort($edited_pages);foreach ($edited_pages as $page["tag"] => $page["time"]){// day headerlist($day, $time) = explode(" ", $page["time"]);if ($day != $curday){if ($curday) echo "<br />\n";echo "<b>$day:</b><br />\n";$curday = $day;}// echo entryecho " ($time) (",$this->ComposeLinkToPage($page["tag"], "revisions", "history", 0),") ",$this->ComposeLinkToPage($page["tag"], "", "", 0),"<br />\n";$my_edits_count++;}if ($my_edits_count == 0){echo "<i>Vous n'avez pas modifié de page.</i>";}}else{echo "<i>Aucune page trouvée.</i>";}}else{echo "<b>Liste des pages que vous avez modifiées, triée par ordre alphabétique.</b><br /><br />\n";if ($pages = $this->LoadAll("SELECT tag, time FROM ".$this->config["table_prefix"]."pages WHERE user = '".mysql_escape_string($this->UserName())."' AND tag NOT LIKE 'Comment%' ORDER BY tag ASC, time DESC")){foreach ($pages as $page){if ($last_tag != $page["tag"]) {$last_tag = $page["tag"];$firstChar = strtoupper($page["tag"][0]);if (!preg_match("/[A-Z,a-z]/", $firstChar)) {$firstChar = "#";}if ($firstChar != $curChar) {if ($curChar) echo "<br />\n";echo "<b>$firstChar</b><br />\n";$curChar = $firstChar;}// echo entryecho " (",$page["time"],") (",$this->ComposeLinkToPage($page["tag"], "revisions", "history", 0),") ",$this->ComposeLinkToPage($page["tag"], "", "", 0),"<br />\n";$my_edits_count++;}}if ($my_edits_count == 0){echo "<i>Vous n'avez pas modifié de page.</i>";}}else{echo "<i>Aucune page trouvée.</i>";}}}else{echo "<i>Vous n'êtes pas identifié : impossible d'afficher la liste des pages que vous avez modifiées.</i>";}?>