CSS Dosyası (/css/style.css):
[sourcecode language="css"]
body
{
font-family: "Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
font-size: 12px;
}
#main
{
width: 95%;
margin: auto;
}
#header
{
width:100%;
}
#content
{
width:100%;
margin: auto;
}
#footer
{
width:100%;
clear: both;
}
#box-table-a
{
font-family: "Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
font-size: 12px;
width: 95%;
margin:auto;
text-align:left;
border-collapse: collapse;
}
#box-table-a th
{
font-size: 13px;
font-weight: normal;
padding: 8px;
background: #b9c9fe;
border-top: 4px solid #aabcfe;
border-bottom: 1px solid #fff;
color: #039;
}
#box-table-a td
{
padding: 8px;
background: #e8edff;
border-bottom: 1px solid #fff;
color: #669;
border-top: 1px solid transparent;
}
#box-table-a tr:hover td
{
background: #d0dafd;
color: #339;
}
a
{
font-family: "Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
font-size: 12px;
color: #669;
text-decoration:none;
}
a:hover
{
color: #339;
text-decoration:underline;
}
h5
{
font-family: "Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
font-size: 12px;
color: #669;
margin-top:5px;
margin-bottom:5px;
}
.element {
font-family:"Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
font-size:12px;
color:#339;
background-color:#fff;
border:1px #339 solid;
}
[/sourcecode]
Kaynaklar
http://www.smashingmagazine.com/2008/08/13/top-10-css-table-designs/
24 Mayıs 2010 Pazartesi
CodeIgniter Temel Veritabanı İşlemleri (CRUD) – VIII
CodeIgniter Temel Veritabanı İşlemleri (CRUD) – VII
Layout Dosyası (views/layout_main.php):
[sourcecode language="php"]
<html>
<head>
<title><?=$title_for_layout?></title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<link rel="stylesheet" type="text/css" href="<?php echo base_url();?>css/style.css"/>
</head>
<body>
<center>
<div id="main" >
<div id="header" ></div>
<div id="content"> <?php echo $content_for_layout?> </div>
<div id="footer" > </div>
</div>
</center>
</body>
</html>
[/sourcecode]
[sourcecode language="php"]
<html>
<head>
<title><?=$title_for_layout?></title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<link rel="stylesheet" type="text/css" href="<?php echo base_url();?>css/style.css"/>
</head>
<body>
<center>
<div id="main" >
<div id="header" ></div>
<div id="content"> <?php echo $content_for_layout?> </div>
<div id="footer" > </div>
</div>
</center>
</body>
</html>
[/sourcecode]
CodeIgniter Temel Veritabanı İşlemleri (CRUD) – VI
Layout Kütüphanesi (libraries/layout.php) [1]:
[sourcecode language="php"]
<?php
if (!defined('BASEPATH')) exit('No direct script access allowed');
class Layout
{
var $obj;
var $layout;
function Layout($layout = "layout_main")
{
$this->obj =& get_instance();
$this->layout = $layout;
}
function setLayout($layout)
{
$this->layout = $layout;
}
function view($view, $data=null, $return=false)
{
$loadedData = array();
$loadedData['content_for_layout'] = $this->obj->load->view($view,$data,true);
if($return)
{
$output = $this->obj->load->view($this->layout, $loadedData, true);
return $output;
}
else
{
$this->obj->load->view($this->layout, $loadedData, false);
}
}
}
?>
[/sourcecode]
Kaynaklar
[1] http://codeigniter.com/wiki/layout_library/
[sourcecode language="php"]
<?php
if (!defined('BASEPATH')) exit('No direct script access allowed');
class Layout
{
var $obj;
var $layout;
function Layout($layout = "layout_main")
{
$this->obj =& get_instance();
$this->layout = $layout;
}
function setLayout($layout)
{
$this->layout = $layout;
}
function view($view, $data=null, $return=false)
{
$loadedData = array();
$loadedData['content_for_layout'] = $this->obj->load->view($view,$data,true);
if($return)
{
$output = $this->obj->load->view($this->layout, $loadedData, true);
return $output;
}
else
{
$this->obj->load->view($this->layout, $loadedData, false);
}
}
}
?>
[/sourcecode]
Kaynaklar
[1] http://codeigniter.com/wiki/layout_library/
CodeIgniter Temel Veritabanı İşlemleri (CRUD) - V
Controller Dosyası (controllers/announcements.php):
[sourcecode language="php"]
<?php
class Announcements extends Controller {
var $table = 'announcements';
var $fields = array ();
var $data = array();
function Announcements ()
{
parent::Controller();
$this->load->database();
$this->load->library(array('layout', 'form_validation', 'pagination'));
$this->load->helper(array('form', 'url', 'date'));
$this->load->model('Announcements_Model');
}
function index()
{
$this->view();
}
function view ($offset = 0)
{
$this->data['records'] = $this->Announcements_Model->get_all_records($this->table, $offset);
$config['base_url'] = site_url($this->table.'/view');
$config['total_rows'] = $this->Announcements_Model->get_all_record_count($this->table);
$config['per_page'] = '10';
$this->pagination->initialize($config);
$this->layout->view($this->table.'/records', $this->data);
}
function insert ()
{
$this->data['action'] = 'insert';
if ($this->_validate())
{
$this->Announcements_Model->insert_entry($this->table, $this->fields);
$this->view();
} else
{
$this->data['title'] = '';
$this->data['body'] = '';
$this->data['date'] = unix_to_human(now());
$this->data['status'] = 1;
$this->data['position'] = '';
$this->data['color'] = '';
$this->data['password'] = '';
$this->layout->view($this->table.'/form', $this->data);
}
}
function update ($id)
{
$this->data['action'] = 'update/'.$id;
if ($this->_validate())
{
$this->Announcements_Model->update_entry($this->table, $this->fields, $id);
$this->view();
} else
{
$record = $this->Announcements_Model->get_record($this->table, $id);
$this->data['title'] = $record[0]['title'];
$this->data['body'] = $record[0]['body'];
$this->data['date'] = unix_to_human($record[0]['date']);
$this->data['status'] = $record[0]['status'];
$this->data['position'] = $record[0]['position'];
$this->data['color'] = $record[0]['color'];
$this->data['password'] = $record[0]['password'];
$this->layout->view($this->table.'/form', $this->data);
}
}
function delete ($id)
{
$this->Announcements_Model->delete_entry($this->table, $id);
$this->view();
}
function _validate ()
{
$this->form_validation->set_rules('title', 'Title', 'required');
$this->form_validation->set_rules('body', 'Body', 'required');
$this->form_validation->set_rules('date', 'Date', 'required');
$this->form_validation->set_rules('status', 'Status');
$this->form_validation->set_rules('position', 'Position', 'required');
$this->form_validation->set_rules('color', 'Color', 'required');
$this->form_validation->set_rules('password', 'Password', 'required');
if ($this->form_validation->run())
{
$this->fields['title'] = $this->input->post('title');
$this->fields['body'] = $this->input->post('body');
$this->fields['date'] = human_to_unix($this->input->post('date'));
$this->fields['status'] = $this->input->post('status');
$this->fields['position'] = $this->input->post('position');
$this->fields['color'] = $this->input->post('color');
$this->fields['password'] = $this->input->post('password');
return TRUE;
} else return FALSE;
}
}
?>
[/sourcecode]
[sourcecode language="php"]
<?php
class Announcements extends Controller {
var $table = 'announcements';
var $fields = array ();
var $data = array();
function Announcements ()
{
parent::Controller();
$this->load->database();
$this->load->library(array('layout', 'form_validation', 'pagination'));
$this->load->helper(array('form', 'url', 'date'));
$this->load->model('Announcements_Model');
}
function index()
{
$this->view();
}
function view ($offset = 0)
{
$this->data['records'] = $this->Announcements_Model->get_all_records($this->table, $offset);
$config['base_url'] = site_url($this->table.'/view');
$config['total_rows'] = $this->Announcements_Model->get_all_record_count($this->table);
$config['per_page'] = '10';
$this->pagination->initialize($config);
$this->layout->view($this->table.'/records', $this->data);
}
function insert ()
{
$this->data['action'] = 'insert';
if ($this->_validate())
{
$this->Announcements_Model->insert_entry($this->table, $this->fields);
$this->view();
} else
{
$this->data['title'] = '';
$this->data['body'] = '';
$this->data['date'] = unix_to_human(now());
$this->data['status'] = 1;
$this->data['position'] = '';
$this->data['color'] = '';
$this->data['password'] = '';
$this->layout->view($this->table.'/form', $this->data);
}
}
function update ($id)
{
$this->data['action'] = 'update/'.$id;
if ($this->_validate())
{
$this->Announcements_Model->update_entry($this->table, $this->fields, $id);
$this->view();
} else
{
$record = $this->Announcements_Model->get_record($this->table, $id);
$this->data['title'] = $record[0]['title'];
$this->data['body'] = $record[0]['body'];
$this->data['date'] = unix_to_human($record[0]['date']);
$this->data['status'] = $record[0]['status'];
$this->data['position'] = $record[0]['position'];
$this->data['color'] = $record[0]['color'];
$this->data['password'] = $record[0]['password'];
$this->layout->view($this->table.'/form', $this->data);
}
}
function delete ($id)
{
$this->Announcements_Model->delete_entry($this->table, $id);
$this->view();
}
function _validate ()
{
$this->form_validation->set_rules('title', 'Title', 'required');
$this->form_validation->set_rules('body', 'Body', 'required');
$this->form_validation->set_rules('date', 'Date', 'required');
$this->form_validation->set_rules('status', 'Status');
$this->form_validation->set_rules('position', 'Position', 'required');
$this->form_validation->set_rules('color', 'Color', 'required');
$this->form_validation->set_rules('password', 'Password', 'required');
if ($this->form_validation->run())
{
$this->fields['title'] = $this->input->post('title');
$this->fields['body'] = $this->input->post('body');
$this->fields['date'] = human_to_unix($this->input->post('date'));
$this->fields['status'] = $this->input->post('status');
$this->fields['position'] = $this->input->post('position');
$this->fields['color'] = $this->input->post('color');
$this->fields['password'] = $this->input->post('password');
return TRUE;
} else return FALSE;
}
}
?>
[/sourcecode]
CodeIgniter Temel Veritabanı İşlemleri (CRUD) - IV
View Dosyası (views/announcements/form.php):
[sourcecode language="php"]
<?php echo form_open($this->table.'/'.$action); ?>
<table id="box-table-a">
<tr>
<td>
<h5>Title</h5>
</td>
<td>
<?php echo form_error('title'); ?>
<input type="text" name="title" value="<?php echo set_value('title', $title); ?>" size="40" />
</td>
</tr>
<tr>
<td>
<h5>Body</h5>
</td>
<td>
<?php echo form_error('body'); ?>
<textarea name="body" rows="5" cols="50"><?php echo set_value('body', $body);?></textarea>
</td>
</tr>
<tr>
<td>
<h5>Date</h5>
</td>
<td>
<?php echo form_error('date'); ?>
<input type="text" name="date" value="<?php echo set_value('date', $date); ?>" size="40" />
</td>
</tr>
<tr>
<td>
<h5>Status</h5>
</td>
<td>
<?php echo form_error('status'); ?>
<input type="checkbox" name="status" value="1" <?php echo set_checkbox('status', 1, $status == 1 ? TRUE : FALSE); ?> />
</td>
</tr>
<tr>
<td>
<h5>Position</h5>
</td>
<td>
<?php echo form_error('position'); ?>
<select name="position">
<option value="left" <?php echo set_select('position', 'left', $position == 'left' ? TRUE : FALSE); ?> >Left</option>
<option value="right" <?php echo set_select('position', 'right', $position == 'right' ? TRUE : FALSE); ?> >Right</option>
<option value="top" <?php echo set_select('position', 'top', $position == 'top' ? TRUE : FALSE); ?> >Top</option>
</select>
</td>
</tr>
<tr>
<td>
<h5>Color</h5>
</td>
<td>
<?php echo form_error('color'); ?>
<input type="radio" name="color" value="red" <?php echo set_radio('color', 'red', $color == 'red' ? TRUE : FALSE); ?> >Red
<input type="radio" name="color" value="blue" <?php echo set_radio('color', 'blue', $color == 'blue' ? TRUE : FALSE); ?> >Blue
<input type="radio" name="color" value="green" <?php echo set_radio('color', 'green', $color == 'green' ? TRUE : FALSE); ?> >Green
</td>
</tr>
<tr>
<td>
<h5>Password</h5>
</td>
<td>
<?php echo form_error('password'); ?>
<input type="password" name="password" value="" size="40" />
</td>
</tr>
<tr>
<td colspan="2" align="center">
<input type="submit" value="OK"/>
</td>
</tr>
</table>
</form>
[/sourcecode]
[sourcecode language="php"]
<?php echo form_open($this->table.'/'.$action); ?>
<table id="box-table-a">
<tr>
<td>
<h5>Title</h5>
</td>
<td>
<?php echo form_error('title'); ?>
<input type="text" name="title" value="<?php echo set_value('title', $title); ?>" size="40" />
</td>
</tr>
<tr>
<td>
<h5>Body</h5>
</td>
<td>
<?php echo form_error('body'); ?>
<textarea name="body" rows="5" cols="50"><?php echo set_value('body', $body);?></textarea>
</td>
</tr>
<tr>
<td>
<h5>Date</h5>
</td>
<td>
<?php echo form_error('date'); ?>
<input type="text" name="date" value="<?php echo set_value('date', $date); ?>" size="40" />
</td>
</tr>
<tr>
<td>
<h5>Status</h5>
</td>
<td>
<?php echo form_error('status'); ?>
<input type="checkbox" name="status" value="1" <?php echo set_checkbox('status', 1, $status == 1 ? TRUE : FALSE); ?> />
</td>
</tr>
<tr>
<td>
<h5>Position</h5>
</td>
<td>
<?php echo form_error('position'); ?>
<select name="position">
<option value="left" <?php echo set_select('position', 'left', $position == 'left' ? TRUE : FALSE); ?> >Left</option>
<option value="right" <?php echo set_select('position', 'right', $position == 'right' ? TRUE : FALSE); ?> >Right</option>
<option value="top" <?php echo set_select('position', 'top', $position == 'top' ? TRUE : FALSE); ?> >Top</option>
</select>
</td>
</tr>
<tr>
<td>
<h5>Color</h5>
</td>
<td>
<?php echo form_error('color'); ?>
<input type="radio" name="color" value="red" <?php echo set_radio('color', 'red', $color == 'red' ? TRUE : FALSE); ?> >Red
<input type="radio" name="color" value="blue" <?php echo set_radio('color', 'blue', $color == 'blue' ? TRUE : FALSE); ?> >Blue
<input type="radio" name="color" value="green" <?php echo set_radio('color', 'green', $color == 'green' ? TRUE : FALSE); ?> >Green
</td>
</tr>
<tr>
<td>
<h5>Password</h5>
</td>
<td>
<?php echo form_error('password'); ?>
<input type="password" name="password" value="" size="40" />
</td>
</tr>
<tr>
<td colspan="2" align="center">
<input type="submit" value="OK"/>
</td>
</tr>
</table>
</form>
[/sourcecode]
CodeIgniter Temel Veritabanı İşlemleri (CRUD) - III
View Dosyası (views/announcements/records.php):
[sourcecode language="php"]
<?php echo anchor($this->table.'/insert', '[Insert Record]').'<p/>'; ?>
<table id="box-table-a">
<tr>
<th>Title</th>
<th>Date</th>
<th>Status</th>
<th>Position</th>
<th>Color</th>
<th>Password</th>
<th colspan="2">Action</th>
</tr>
<?php
foreach ($records as $rec)
{
echo '<tr>';
echo '<td>'.$rec['title'].'</td>';
echo '<td>'.unix_to_human($rec['date']).'</td>';
echo '<td>'.$rec['status'].'</td>';
echo '<td>'.$rec['position'].'</td>';
echo '<td>'.$rec['color'].'</td>';
echo '<td>'.$rec['password'].'</td>';
echo '<td>'.anchor($this->table.'/update/'.$rec['id'], '[edit]').'</td>';
echo '<td>'.anchor($this->table.'/delete/'.$rec['id'], '[delete]', array('onclick'=>"return confirm('Are you sure?')")).'</td>';
echo '</tr>';
}
?>
</table><p/>
<?php echo $this->pagination->create_links(); ?>
[/sourcecode]
[sourcecode language="php"]
<?php echo anchor($this->table.'/insert', '[Insert Record]').'<p/>'; ?>
<table id="box-table-a">
<tr>
<th>Title</th>
<th>Date</th>
<th>Status</th>
<th>Position</th>
<th>Color</th>
<th>Password</th>
<th colspan="2">Action</th>
</tr>
<?php
foreach ($records as $rec)
{
echo '<tr>';
echo '<td>'.$rec['title'].'</td>';
echo '<td>'.unix_to_human($rec['date']).'</td>';
echo '<td>'.$rec['status'].'</td>';
echo '<td>'.$rec['position'].'</td>';
echo '<td>'.$rec['color'].'</td>';
echo '<td>'.$rec['password'].'</td>';
echo '<td>'.anchor($this->table.'/update/'.$rec['id'], '[edit]').'</td>';
echo '<td>'.anchor($this->table.'/delete/'.$rec['id'], '[delete]', array('onclick'=>"return confirm('Are you sure?')")).'</td>';
echo '</tr>';
}
?>
</table><p/>
<?php echo $this->pagination->create_links(); ?>
[/sourcecode]
CodeIgniter Temel Veritabanı İşlemleri (CRUD) - II
Model Dosyası (models/announcements_model.php):
[sourcecode language="php"]
<?php
if (!defined('BASEPATH')) exit('No direct script access allowed');
class Announcements_Model extends Model {
function Announcements_Model()
{
parent::Model();
}
function get_all_records($table, $offset)
{
return $this->db->get($table, 10, $offset)->result_array();
}
function get_record ($table, $id)
{
$this->db->where('id', $id);
return $this->db->get($table)->result_array();
}
function get_all_record_count($table)
{
return $this->db->count_all($table);
}
function insert_entry($table, $data)
{
$this->db->insert($table, $data);
}
function update_entry($table, $data, $id)
{
$this->db->update($table, $data, array('id' => $id));
}
function delete_entry($table, $id)
{
return $this->db->delete($table, array('id' => $id)) ? TRUE : FALSE;
}
}
[/sourcecode]
[sourcecode language="php"]
<?php
if (!defined('BASEPATH')) exit('No direct script access allowed');
class Announcements_Model extends Model {
function Announcements_Model()
{
parent::Model();
}
function get_all_records($table, $offset)
{
return $this->db->get($table, 10, $offset)->result_array();
}
function get_record ($table, $id)
{
$this->db->where('id', $id);
return $this->db->get($table)->result_array();
}
function get_all_record_count($table)
{
return $this->db->count_all($table);
}
function insert_entry($table, $data)
{
$this->db->insert($table, $data);
}
function update_entry($table, $data, $id)
{
$this->db->update($table, $data, array('id' => $id));
}
function delete_entry($table, $id)
{
return $this->db->delete($table, array('id' => $id)) ? TRUE : FALSE;
}
}
[/sourcecode]
CodeIgniter Temel Veritabanı İşlemleri (CRUD) - I
Tablo:
announcements
[sourcecode language="sql"]
CREATE TABLE IF NOT EXISTS `announcements` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`title` varchar(50) NOT NULL,
`body` text NOT NULL,
`date` int(11) NOT NULL,
`status` char(1) NOT NULL,
`position` varchar(10) NOT NULL,
`color` varchar(15) NOT NULL,
`password` varchar(32) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
[/sourcecode]
Dizin Yapısı:
application/models/announcements_model.php
application/views/announcements/recors.php
application/views/announcements/form.php
application/controllers/announcements.php
application/libraries/layout.php
application/views/layout_main.php
/css/style.css
announcements
[sourcecode language="sql"]
CREATE TABLE IF NOT EXISTS `announcements` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`title` varchar(50) NOT NULL,
`body` text NOT NULL,
`date` int(11) NOT NULL,
`status` char(1) NOT NULL,
`position` varchar(10) NOT NULL,
`color` varchar(15) NOT NULL,
`password` varchar(32) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
[/sourcecode]
Dizin Yapısı:
application/models/announcements_model.php
application/views/announcements/recors.php
application/views/announcements/form.php
application/controllers/announcements.php
application/libraries/layout.php
application/views/layout_main.php
/css/style.css
FormIgniter - Easy Form Generator
CodeIgniter çatısı için Ollie Rattue tarafından geliştirilmiş; ağırlıklı olarak MVC formlarını otomatik olarak oluşturması için düşünülmüş güzel bir uygulama: http://formigniter.org/
Uygulamanız için belirttiğiniz field adları ile tablonuz için SQL kodları, Controller, Form ve Model dosyaları otomatik üretiliyor ve indirilebiliyor.
Uygulamanız için belirttiğiniz field adları ile tablonuz için SQL kodları, Controller, Form ve Model dosyaları otomatik üretiliyor ve indirilebiliyor.
Etiketler:
CodeIgniter,
Form Generator,
FormIgniter
Web Sayfası Değerlendirme Aracı
ÖZET
KAMU KURUM VE KURULUŞLARI İNTERNET SİTELERİNİN
2007/4 SAYILI GENELGE KAPSAMINDA DEĞERLENDİRİLMESİNE
YÖNELİK BİR ARAÇ GELİŞTİRİLMESİ
2007/4 SAYILI GENELGE KAPSAMINDA DEĞERLENDİRİLMESİNE
YÖNELİK BİR ARAÇ GELİŞTİRİLMESİ
Erkan DURAN
Balıkesir Üniversitesi, Fen Bilimleri Enstitüsü,
Bilgisayar ve Öğretim Teknolojileri Eğitimi Anabilim Dalı
Bilgisayar ve Öğretim Teknolojileri Eğitimi Anabilim Dalı
(Yüksek Lisans Tezi / Tez Danışmanı: Yrd. Doç. Dr. Taner TANRISEVER)
Balıkesir, 2008
Bu çalışmanın amacı, Türkiye Bilimsel ve Teknolojik Araştırma Kurumu - Marmara Araştırma Merkezi tarafından hazırlanan ve 2007/4 sayılı Başbakanlık genelgesi ile yayımlanan “Kamu Kurumları İnternet Sitesi Kılavuzu” kapsamında kamu kurum ve kuruluşları internet sitelerini değerlendirmeye yönelik bir araç geliştirilmesidir.
Çalışmada öncelikle söz konusu kılavuz kapsamında belirlenen kriterlere göre değerlendirme işlemlerini yapabilen bir PHP class’ı (sınıf’ı) yazılmış, sonra da bu class’ı kullanarak çalışan bir araç geliştirilmiştir.
Class’ın ve aracın geliştirilmesinin ardından, 35 kamu kurum ve kuruluşu internet sitesi ana sayfası, “http://webtest.balikesir.edu.tr” adresinde yer alan geliştirilmiş bu araç ile “İçerik (Asgari)”, “Tasarım (Erişilebilirlik)”, “Tasarım (Teknik Özellikler)” ve “Genel Görünüm” olmak üzere dört ana başlıktaki kriterlere göre değerlendirilmiştir. Değerlendirmeler sonucunda, bu web sayfalarının; asgari içerik ile ilgili kriterleri büyük ölçüde sağladıkları ancak diğer üç ana başlıkta yer alan kriterlere göre hem standartlar yönünden, hem de erişilebilirlik yönünden eksiklerinin olduğu ortaya çıkmıştır.
Anahtar Sözcükler: Web Sayfası Değerlendirme Aracı, İnternet Siteleri Kılavuzu, W3C, Web Standartları, Erişilebilirlik, e-Devlet
Etiketler:
Akademik,
e-Devlet,
Erişilebilirlik,
İnternet Siteleri Kılavuzu,
W3C,
Web Sayfası Değerlendirme,
Web Sayfası Değerlendirme Aracı,
Web Standartları
Web Page Evaluation Tool
ABSTRACT
THE DEVELOPMENT OF A TOOL AIMED AT
THE EVALUATION OF THE PUBLIC INSTITUTIONS WEBSITES
UNDER THE CIRCULAR 2007/4
THE EVALUATION OF THE PUBLIC INSTITUTIONS WEBSITES
UNDER THE CIRCULAR 2007/4
Erkan DURAN
Balıkesir University, Institute of Science
Department of Computer Education and Instructional Technology
Department of Computer Education and Instructional Technology
(M. Sc. Thesis / Supervisor: Assist. Prof. Dr. Taner TANRISEVER)
Balıkesir, 2008
The aim of this study is developing a tool aimed at evaluation of public institutions websites according to “Public Institutions Websites Guide” which is prepared by The Scientific and Technological Research Council of Turkey – Marmara Research Center and published with circular 2007/4 of The Office of The Prime Minister.
Firstly in this study, a PHP class which is able to evaluate according to criterions which determined under the guide was written. Afterwards, a tool works by using this PHP class was developed.
After developing PHP class and the tool, 35 public institutions website main pages were evaluated with this developed tool which is available at “http://webtest.balikesir.edu.tr” according to criterions in four main categories as being “Content (Minimum)” , “Design (Accessibility)” , “Design (Techinical Properties) ” and “General View ”. At the result of evaluations, it was come out that these web pages provided almost all of the criterions related with minimum content. But, it was also come out that these web pages have deficiencies for both standards and accessibility according to criterions in other three main categories.
Keywords: Webpage Evaluation Tool, Websites Guide, W3C, Web Standards, Accessibility, e-Government
Etiketler:
Accessibility,
Akademik,
e-Government,
W3C,
Web Sayfası Değerlendirme,
Web Standards,
Webpage Evaluation Tool,
Websites Guide
23 Mayıs 2010 Pazar
XSLT 1.0 Split İşlemi
Aşağıdaki kod recursive (yinelemeli) method ile XML dosyasında belirli bir karakter ile birbirinden ayrılarak oluşturulmuş bir elementin içeriğini (ör: <photos>1.jpg|2.jpg|3.jpg|</photos>) aynı karakterden (|) yararlanıp ayırarak (split) yeni içeriğin kullanılmasına bir örnek [1]:
[sourcecode language="xml"]
<xsl:template name="output-tokens">
<xsl:param name="list" select="/album/photos"/>
<xsl:variable name="first" select="substring-before($list, '|')" />
<xsl:variable name="remaining" select="substring-after($list, '|')" />
<xsl:if test="$first">
<img src="{$first}" width="240" height="155"/>
</xsl:if>
<xsl:if test="$remaining">
<xsl:call-template name="output-tokens">
<xsl:with-param name="list" select="$remaining" />
</xsl:call-template>
</xsl:if>
</xsl:template>
[/sourcecode]
<xsl:call-template name="output-tokens"/> ile şablon, XSL içinden çağrılarak çalıştırılıyor.
Kaynaklar:
[1] http://stackoverflow.com/questions/136500/does-xslt-have-a-split-function
[sourcecode language="xml"]
<xsl:template name="output-tokens">
<xsl:param name="list" select="/album/photos"/>
<xsl:variable name="first" select="substring-before($list, '|')" />
<xsl:variable name="remaining" select="substring-after($list, '|')" />
<xsl:if test="$first">
<img src="{$first}" width="240" height="155"/>
</xsl:if>
<xsl:if test="$remaining">
<xsl:call-template name="output-tokens">
<xsl:with-param name="list" select="$remaining" />
</xsl:call-template>
</xsl:if>
</xsl:template>
[/sourcecode]
<xsl:call-template name="output-tokens"/> ile şablon, XSL içinden çağrılarak çalıştırılıyor.
Kaynaklar:
[1] http://stackoverflow.com/questions/136500/does-xslt-have-a-split-function
Kaydol:
Kayıtlar (Atom)