View Artist 4/?
This commit is contained in:
parent
a5e3920fb0
commit
72deabb88f
application
@ -3,28 +3,18 @@ defined('BASEPATH') OR exit('No direct script access allowed');
|
|||||||
|
|
||||||
class Artist extends CI_Controller {
|
class Artist extends CI_Controller {
|
||||||
|
|
||||||
public function __construct(){
|
public function __construct(){
|
||||||
parent::__construct();
|
parent::__construct();
|
||||||
$this->load->model('model_music');
|
$this->load->model('model_music');
|
||||||
}
|
}
|
||||||
public function index(){
|
public function index(){
|
||||||
$genre = $this->input->get('genre');
|
$genre = $this->input->get('genre');
|
||||||
$order = $this->input->get('order');
|
$order = $this->input->get('order');
|
||||||
$artists = $this->model_music->getArtists($genre, $order);
|
$artists = $this->model_music->getArtists($genre, $order);
|
||||||
$genres = $this->model_music->researchtype();
|
$genres = $this->model_music->researchtype();
|
||||||
$is_logged_in = $this->session->userdata('logged_in');
|
$this->load->view('layout/header',['genres'=>$genres]);
|
||||||
|
$this->load->view('artists_name',['artists'=>$artists]);
|
||||||
$data = array(
|
$this->load->view('layout/footer');
|
||||||
'artists' => $artists,
|
}
|
||||||
'genres' => $genres,
|
|
||||||
'is_logged_in' => $is_logged_in
|
|
||||||
);
|
|
||||||
|
|
||||||
$this->load->view('layout/header', $data);
|
|
||||||
$this->load->view('artistes_list', $data);
|
|
||||||
$this->load->view('layout/footer');
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
}
|
@ -1,13 +0,0 @@
|
|||||||
<h5>Artists List</h5>
|
|
||||||
<section class="list">
|
|
||||||
|
|
||||||
<?php
|
|
||||||
foreach($artists as $artist){
|
|
||||||
echo "<div><article>";
|
|
||||||
echo "<header class='short-text'>";
|
|
||||||
echo anchor("artistes/view/{$artistes->artistId}","{$artist->artistName}");
|
|
||||||
echo "</header>";
|
|
||||||
echo "</article></div>";
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
</section>
|
|
11
application/views/artistes_name.php
Normal file
11
application/views/artistes_name.php
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
<h5>Artists list</h5>
|
||||||
|
<section class="list">
|
||||||
|
<?php
|
||||||
|
foreach($artists as $artist){
|
||||||
|
echo "<div><article>";
|
||||||
|
echo "<header class='short-text'>";
|
||||||
|
echo anchor("artist/view/{$artist->artistId}","{$artist->artistName}");
|
||||||
|
echo "</header></article></div>";
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
</section>
|
Loading…
x
Reference in New Issue
Block a user