Member
Member
gschultz   2011-04-16, 03:44
#1

I know there are ways to integrate Zenphoto with Wordpress but are there ways to do the opposite? I'm looking for a way to show the first ten albums in the sidebar of my blog, either with a plug or coding that the loads the database and displays the albums with php shortcodes.

Thanks,
Greg

Administrator
Administrator
acrylian   2011-04-16, 08:37
#2

There are tools for similar things this on the extensions section. Since they are 3rd party I can't tell you if they still work.

Member
Member
gschultz   2011-04-19, 04:24
#3

The plugins didn't work but I was able to find a solution to my problem with this:

            " title="View album: ">



                " title="View album: ">

Only problem is that it displays all the albums. How do I fix it to display the first ten?

Thanks,
Greg

Member
Member
gschultz   2011-04-19, 04:40
#4

I found a solution and now I have another problem. The code I'm using displays all the albums. Is there a way to show a certain number of albums instead of all?

Thanks,
Greg

Administrator
Administrator
acrylian   2011-04-19, 08:15
#5

Stop the loop after the number you wish. Sorry this is basic php...

Member
Member
gschultz   2011-04-19, 19:16
#6

How do I stop the loop?

Member
Member
sbillard   2011-04-19, 19:34
#7

This is pretty much basic programming, not even basic PHP. If you do not know at least this much, then you really need to do some learning.

Besides, since you did not show the solution you found there is no way anyone here can provide you with an answer. These things really depend on what has gone on before.

Member
Member
gschultz   2011-04-19, 21:05
#8

OK, I'll try again. I'm trying to make a page outside of Zenphoto that shows the last ten albums and then use php include to add that page to my WordPress sidebar.

I've tried using plugins and many didn't work.

Here's what I have so far: http://gregschultz.net/gallery.php

With this code:
'

" title="View album: ">

" title="View album: ">

'
It displays all of my albums.

With this code:
'

" title="View album: ">

'
It displays the first album only.

I'm not familiar with PHP programming so this is why I'm asking for help.

Thanks,
Greg

Member
Member
sbillard   2011-04-20, 00:03
#9

First, for this forum, it is best to use the code deliminating "peck marks" or "back tick" (on the US PC keyboard it is the left most key on the numberic row.)

This takes care of insuring that your HTML markup in the code shows up.

Unless some of your code has been swallowed because of the HTML interpretation, the two loops you show would process exactly the same number of albums. The only significant difference between the two is the HTML brackets in the first loop. This would lead one to beleive there might be a mis-balanced set of tags.

Member
Member
gschultz   2011-04-20, 01:19
#10

Found the fix.

`

">

`
x10

  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.