%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /home/devcapijob/.trash/modules.2/block/
Upload File :
Create Path :
Current File : /home/devcapijob/.trash/modules.2/block/index.php

<?php

/**

* @version		1

* @package		yassir

* @copyright	Copyright (C) 2011 Open Source Matters. All rights reserved.

* @license		sharware

*

*

* @ FOOTER MODULE

*/





class blockModule extends Module{



	

	

		

	function display(){

		$this->js='';

		$this->css='';

		return $this->html();}

		

	

	function html(){

		$data=$this->liste_image_page(0,100,8,1);



		function replaceHtml( $texte, $link = '' ) {

			// Use $link when there is no "url" in the description field :)

			$texte = htmlentities( $texte );

			$texte = preg_replace( "#\[br\]#", '<br><br>', $texte );
			
			if ( preg_match( "#\[url\=(.*)\](.*)\[\/url\]#S", $texte ) ) {

				$texte = preg_replace( "#\[url\=(.*)\](.*)\[\/url\]#S", '<a href="$1">$2</a>', $texte );
			}
			else {
				$texte = preg_replace( "#(.*)#i", "<a href=\"$link\">$1</a>", $texte );
			}

			return $texte;

		}

		

		$i=1;



		$colors = 1;

		

		foreach($data as $li){

			$list.='<li>';

			$list.='<h3>'.htmlentities( $li[2] ).'</h3>';

			$list.='<a href="'.$li[1].'" rel="p'.$i.'">

						<img class="color-'. $colors .'" src="'.URL_BASE.'files_perso/realisations/big/'.$li[0].'" alt="'.htmlentities( $li[2] ).'" /><!--style="max-height:81px;max-width:196px;"-->

					</a>

					<p>'. replaceHtml( $li[3], $li[1] ) .'</p>';

			$list.='</li>';

			$i+=1;



			if ( $colors > 4 ) {

				$colors = 0;

			}

			else {

				$colors++;

			}

		}

		$affichage = '<ul id="slider-menu">' . $list . '</ul>';

		return $affichage;

		}

	

}

?>

Zerion Mini Shell 1.0