Enlightenment CVS committal
Author : mej
Project : web
Module : www
Dir : web/www/p/news
Modified Files:
class.news.php latestnews.php
Log Message:
Wed May 30 20:03:24 2007 Michael Jennings (mej)
Clean up Inc's mess.
----------------------------------------------------------------------
===================================================================
RCS file: /cvs/e/web/www/p/news/class.news.php,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- class.news.php 27 May 2007 13:00:16 -0000 1.2
+++ class.news.php 31 May 2007 00:03:25 -0000 1.3
@@ -5,10 +5,14 @@
var $list = array();
var $dirnews;
var $limit = 0;
+ var $lang = "en";
function __construct() {
$i = 0;
- $this->dirnews = "p/news/".$_GET['l'];
+ if (isset($_GET['l']) && (strlen($_GET['l']) == 2)) {
+ $this->lang = $_GET['l'];
+ }
+ $this->dirnews = "p/news/" . $this->lang;
if(!($dp = opendir($this->dirnews)))
return NULL;
===================================================================
RCS file: /cvs/e/web/www/p/news/latestnews.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -3 -r1.3 -r1.4
--- latestnews.php 30 May 2007 22:59:30 -0000 1.3
+++ latestnews.php 31 May 2007 00:03:25 -0000 1.4
@@ -9,13 +9,13 @@
{
if (($new = $news->read_content($new)) !== NULL)
{
- echo "<p><a
href='p.php?p=news/show&l=".$_GET['l']."&news_id=$new[id]'>".$new['title']."</a>
- <em>".$new['date']."</em></p>";
+ echo "<p><a
href='p.php?p=news/show&l=".$news->lang."&news_id=$new[id]'>".$new['title']."</a>
- <em>".$new['date']."</em></p>";
echo "<p>".$new['content']."</p>\n";
}
}
-echo "<p align='right'><a href='p.php?p=news&l=".$_GET['l']."'
title='News'>More news ... </a></p>";
+echo "<p align='right'><a href='p.php?p=news&l=".$news->lang."'
title='News'>More news ... </a></p>";
?>
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs