11 years ago
Topic

Hello,

Thank you inadvance for your help.

I'm facing the following issue:

I'm trying to personnalize a List Search Module using Seblod 2 with a Custom Intro Seb_One Template.

Now:

If i have 2 articles (Article 1 and Article 2).
Seblod will call my file "positions/ [ nameofmysearchform ] /intro/ [ myphpfile] " for Article 1 then again for the Article 2, and so on.

Using this way i'm stuck because i only can personnalize my article presentation itself. I mean only the presentation of the fields in the articles.
But not the article together with the fields in it.
 If i wan't to use a different layout structure with javascript scrolling for exemple i can't anymore.

Witch was possible in SEBLOD previous versions.


So do you think it is possible under this latest version to get all the articles 1, 2, ... data directly trought a variable.
Then using while or foreach, read this variable and then get my own layout structure for List Module Template.

I have many website exemple using this while solutions under your previous versions 1.x

NB: In a  word, i would like to know if it is possible to get ride of the Module List default loop and i have my own loop for articles data ?

PS: At the moment for exemple, i have no solution to delete the article title in the List Module of my SearchForm.
I've tried positions, variations, but the loop $cck is called before that.


Thank you very much for your help and your answers

Kind Regards,
Hugo.

Get a Book for SEBLOD
85 Posts
Jpeg
11 years ago
5
Level 1

Hi Hugo,

If I understand, you need to create a custom template list (like seb_one, seb_table), not just a position override for seb_one.

Template contains all contents repeat one time.

Position contains fields in one content and repeat X times.

I hope i'm clear :)

Jpeg


11 years ago
4
Level 2

Thank you for your great help !!!

Exactly i need to create my own list template.
And i tried today without any success because i have no idea how to create my own custom SEBLOD list template.

I tried to duplicate seb_one and change xml details ... Did not appear anywere
Then i tried In SEBLOD -> Template -> New template based on seb_one SQL error allready exist.

So some ideas will be welcomed :)
Thank you again.

85 Posts
Jpeg
11 years ago
3
Level 3

Hi,

you have start to helping your in documentation -> "Template" on the old seblod website

don't forget to use the old forum to search many information ;)

Jpeg

11 years ago
2
Level 4

Thank you for the link.

I allready followed all of those tutorials ...
As i can't find i'll back to version 1.x ...

85 Posts
Jpeg
11 years ago
1
Level 5

humm...

I give you my code for my index.php todo a caroussel content in module.... is just a example !!!!! I willingly truncate js/css files calls

defined( '_JEXEC' ) or die;
?>

<?php
require_once dirname(__FILE__).'/config.php';
$cck   =   CCK_Rendering::getInstance( $this->template );
if ( $cck->initialize() === false ) { return; }

$doc=& JFactory::getDocument();
 
 $doc ->addScriptDeclaration('
 
 jQuery(document).ready(function() {
   jQuery(".'.$cck->id.'").simpleSlider({
       navigation: true,
       prevText: "<",
       nextText: ">",
       pagination: true,
       autoplay: true,
       delay: 6000,
       speed: 500,
       numItems: 1
     });
   
  jQuery(".'.$cck->id.'>.slide").each(function() {
       var $this = jQuery(this);
       var precedent = $this.parent().parent().parent().find(".carousel-nav .precedent");
       var suivant = $this.parent().parent().parent().find(".carousel-nav .suivant");
     });

 });');

$items     =   $cck->getItems();

//language
$lang = & JFactory::getLanguage();
$langTag = $lang->getTag();

?>

  <div class="carousel">
     <div class="carousel-container">
       <div class="carousel-wrapper <?php echo $cck->id; ?>">
  <?php
  foreach( $items as $item )
    {
  $title = $item->get("art_title")->value;
  $corps = strip_tags($item->get("infocampus_corpsfr")->value);

  if($langTag == "en-GB")
  {
  $title = $item->get("infocampus_titleen")->value;
  $coprs = strip_tags($item->get("infocampus_corpsen")->value);
  }
   
        ?>
        <div class="carousel-element">   
          <p><span class="carousel-title"><?php echo $title ?></span>
          <span class="carousel-corps"><?php echo $corps ?></span></p>
        </div>
        <?php
    }
  ?>
       </div> <!-- End Wrapper -->
             
       <div class="infos"></div>
     </div> <!-- End Container -->
   </div> <!-- End Carousel -->

   
<?php $cck->finalize(); ?>





is not complicated :)

11 years ago
0
Level 6

Great thank you !! This is definitly a solution.

And one little things, how can do you declare your new List Template in Joomla ?
I mean what did you do to declare your new seblod template ?

Regards,

Get a VIP membership