PEAK XOOPS - Displaying myAlbum-P photos in 2 columns on viewcat.php in englishin japanese

Displaying myAlbum-P photos in 2 columns on viewcat.php

  • You cannot open a new topic into this forum
  • Guests cannot post into this forum
Previous post - Next post | Parent - Children.1 | Posted on 2004/12/12 7:38
FutureSpy  伍長 From: 世界のどっかで  Posts: 70
Hi.

I was testing myAlbum-P. I should confess that I didn't like it from a first sight, but after testing it I decided to use it over xcGal.

Now, I'm editting the templates. I wanna have viewcat.php to show the photos in 2 columns, but I don't seem to be doing it correctly.

Here's the code of viewcat_list.html I'm trying to modify:
        <table width='100%' cellspacing='0' cellpadding='10' border='0'>
<tr>
          <{foreach from=$photos item=photo}>
            <{include file="db:myalbum_photo_in_list.html"}>
<{if $count is div by 2}>
</tr><tr>
<{/if}>
          <{/foreach}>
</tr>
        </table>

Instead of showing the tags inside "$count is div by 2" only in one of the photos of a column, it's displaying for every photo. I wonder if I have to touch the code too, or am I using the wrong variable?


Thanks in advance
-Yuji
Votes:3 Average:0.00
Previous post - Next post | Parent - Children.1 | Posted on 2004/12/14 6:35
GIJOE  先任軍曹   Posts: 4110
hi Yuji.

I'm sorry that I have no time to check your code.

But if you want 2 columns of viwcat, you'd better edit it with myalbum*_viewcat_table.html as base.

After this, copy some codes from myalbum_viewcat_list.html.

I think it's the easiest way.
Votes:0 Average:0.00
Previous post - Next post | Parent - Children.1 | Posted on 2004/12/15 7:49
FutureSpy  伍長 From: 世界のどっかで  Posts: 70
Thanks for your reply.

Actually I was using the wrong variable to divide in 2 columns... It's now fixed! ^__^

But now you said, I looked at the tables template. I didn't know if I select it to show in table I would have it divided in columns...

-Yuji
Votes:0 Average:0.00
Previous post - Next post | Parent - Children.1 | Posted on 2004/12/15 10:08
FutureSpy  伍長 From: 世界のどっかで  Posts: 70
So I ended up editting myalbum_viewcat_table.html instead. But when I use <{$photo.datetime}> it won't display the date of the photo.

That's weird, 'cause it worked on myalbum_viewcat_table.html.

Can't find anything that would be "blocking" it...

Thanks.
Votes:0 Average:0.00
Previous post - Next post | Parent - Children.1 | Posted on 2004/12/24 6:35
GIJOE  先任軍曹   Posts: 4110
I meant that copy from the body of myalbum_viewcat_table.html to myalbum_viewcat_list.html.

It is different assignment between list view and table view.

If you want full assignment with table view, edit this.

line 28 of viewcat.php
if( $view == 'table' ) {
	$xoopsOption['template_main'] = "{$mydirname}_viewcat_table.html" ;
	$function_assigning = 'myalbum_get_array_for_photo_assign_light' ;
} else {
	$xoopsOption['template_main'] = "{$mydirname}_viewcat_list.html" ;
	$function_assigning = 'myalbum_get_array_for_photo_assign' ;
}
Votes:0 Average:0.00
Previous post - Next post | Parent - No child | Posted on 2005/1/28 1:00
Hetti  二等兵   Posts: 3
Hello there

I asked the same question ... well ... I was too blind to see this posting. SORRY!!!

Is it possible, that you could post the changes (the code) you made to have the cats shown in 2 columns? I must admit I often make mistakes when I want to change code so Iエm a bit afraid that I could do anything wrong...

THANKS very much

Hetti
Votes:0 Average:0.00

  Advanced search


Login
Username or e-mail:

Password:

Remember Me

Lost Password?

Register now!