viewing albums in the "Albums" menu viewing albums in the "Albums" menu
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

viewing albums in the "Albums" menu

Started by philippefx, September 02, 2010, 02:27:04 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

philippefx

Hi All,

Gallery http://photo.grangeneuve.ch/, login "test", passwd "testforum"

In the past few weeks, I changed my home page in the following ways :
1. copy/paste the content of "search.php" in "anycontent.php"
2. add "define("SEARCH_PHP", true)" in "index.php"

(and averything works so far)

3. In menu Config => Album list view =>  The content of the main page, I change this parameter to "anycontent", because I just want this content on my home page.

Works as intended, but the main menu "Albums" doesn't work anymore => no album is displayed here.

It doen't feel very coherent. An "Album" menu should display the albums right ? Even if I change the content of the home page ?

Could anyone help me here ?


Thanks a lot,

Philippe



Αndré

Try to remove
pageheader($lang_search_php['title']);
and
pagefooter();
in your anycontent.php file.

Joe Carver

Quote from: philippefx on September 02, 2010, 02:27:04 PM
Works as intended, but the main menu "Albums" doesn't work anymore => no album is displayed here.

It doen't feel very coherent. An "Album" menu should display the albums right ? Even if I change the content of the home page ?

You do have album pages, such as:
http://photo.grangeneuve.ch/index.php?cat=2

The 'Content of the main page' includes index.php?cat=0 - the link from the home page.
So if you have nothing in there except anycontent that is all you should expect to see. Other cat pages also use that setting.

But since I owe you a small debt of gratitude for an idea to make a Home Page Search plugin.

Use this plugin Album List - Change Page Layout (Album list link).
You will be able to add what you want on index.php?cat=0

In any case the suggestion above must be applied first.



philippefx

Quote from: Αndré on September 02, 2010, 02:47:43 PM
Try to remove
pageheader($lang_search_php['title']);
and
pagefooter();
in your anycontent.php file.

Sorry André, I wasn't explicit enought. It's already done (see the file attached to this post : http://forum.coppermine-gallery.net/index.php/topic,66580.msg330931.html#msg330931 )

The problem is I removed every parameters but "anycontent" from "The content of the main page", and then the main menu "Albums" doesn't show anything.

Given the tip above from Joe Carver, I can use "/index.php?cat=2", but it's not a really good solution :

  • I can't display every albums (only one by one, and we have tu guess the album's number first...)
  • I still believe an "Album" menu has to show albums, and should not be influenced by the content of the home page

If anybody has a better solution...

Thanks all,
Philippe

Αndré

Quote from: philippefx on September 03, 2010, 02:22:41 PM
I removed every parameters but "anycontent" from "The content of the main page", and then the main menu "Albums" doesn't show anything.
That's the expected behavior. Just add anycontent/breadcrumb/catlist/alblist to 'The content of the main page' and everything should work fine.

philippefx

Quote from: Αndré on September 03, 2010, 02:27:47 PM
That's the expected behavior. Just add anycontent/breadcrumb/catlist/alblist to 'The content of the main page' and everything should work fine.

Mhh doesn't work :/

I added "anycontent/breadcrumb/catlist/alblist", the home page is ok (=> http://photo.grangeneuve.ch/index.php), but the album page is still empty (but there are albums in it => http://photo.grangeneuve.ch/index.php?cat=2).

As the home page and the albums page are the same URL, it's not very surprising, but there is a point here I don't get.

Αndré

Maybe we're talking about different things. Please see the attached screenshot (anycontent_search_index.png). I added 'anycontent/breadcrumb/catlist/alblist' to 'The content of the main page' and it shows exactly what I entered:
- Your search form
- The categories and albums

When I visit your gallery, I don't see what I would expect (see attachment 'philipps.png'). So maybe it's time to explain what you mean with 'album page'. Maybe it helps when you draw me a picture ;)

philippefx

Quote from: Αndré on September 03, 2010, 03:37:44 PM
Maybe we're talking about different things. Please see the attached screenshot (anycontent_search_index.png). I added 'anycontent/breadcrumb/catlist/alblist' to 'The content of the main page' and it shows exactly what I entered:
- Your search form
- The categories and albums

When I visit your gallery, I don't see what I would expect (see attachment 'philipps.png'). So maybe it's time to explain what you mean with 'album page'. Maybe it helps when you draw me a picture ;)

Very frustrating. My english is too bad. Or my brain.

This is the problem (attached file where_are_the_albums.png) :)

  • I dont want : the albums on the "home" page
  • I want : the albums on the "albums" page

If I understand you correctly so far, the design of the Home and the Albums pages are just the same, and it's not possible for them to be different ?



Αndré

In your case I would create a rewrite rule like:
RewriteEngine on
RewriteBase /
RewriteRule ^$ search.php [NC]


So your visitors always start with the search form. If you need more content on that page, create a new file, copy the whole content of search.php to that file and add your extra content. Then modify the rewrite rule to use that file.

philippefx

Not bad, but the "home" menu button point to "index.php" and not to "/"

Ok, I will not fill your forum with this question :) I'll wait until Monday then mark it as "solved", I can live with it as it is now.

(But I continue thinking that "home" and "albums" pages should not share their config :) )



Αndré

Quote from: philippefx on September 03, 2010, 04:37:00 PM
the "home" menu button point to "index.php" and not to "/"
Then configure it that it points to / with the setting 'URL of your home page' 8)

philippefx

Quote from: Αndré on September 03, 2010, 04:39:52 PM
Then configure it that it points to / with the setting 'URL of your home page' 8)

ohhhh so wonderfull.

I could even write "search.php" in here :)


You solved all the problems. I don't know how to thank you ("Will you marry me", etc.), but thank you :)

Philippe

Αndré