Sidebar Image Block does not display.

Siggy
Siggy's picture

Joined: 2008-02-23
Posts: 6
Posted: Sat, 2008-02-23 14:36

I'm getting some strange behavior with WPG2 3.0.2.

I placed <?php print g2_sidebarimageblock(); ?> in my header.php file to display a Random Image below my navigation. This used to work perfectly fine but has not been functioning correctly lately.

The only change I remember making related to this is that I reinstalled Gallery2 recently. Even after I did this, the Random Image block was functioning fine.

I've tried everything on the Gallery2 System Maintenance menu and the WPG2 options. The strange behavior is that the image block will display correctly after refreshing in the browser I'm using but will not load at all on other browsers. The page source will not even have any reference to the image block on the other browsers.

Even stranger, when I deactivate the plugin and refresh on the other browsers, it displays a fatal error: Fatal error: Call to undefined function g2_sidebarimageblock() in .../header.php on line 52. This tells me that it is trying to pull up the Random Image but won't display the data at the same time.

In other words, I have vicious circle going on here. Could this be something related to a PHP configuration? If not, what's going on?!

Sig
www.ModernSoapbox.com

 
ozgreg
ozgreg's picture

Joined: 2003-10-18
Posts: 1378
Posted: Sun, 2008-02-24 22:13

I would expect the Fatal error: Call to undefined function g2_sidebarimageblock() if you deactivate the WPG2 plugin as the function would no longer exist..

What permission have you set your photos to? Guest access or do you lock down the view access??

____________________________________
Wordpress / Gallery2 (WPG2) Plugin, , WPG2 Documentation, WPG2 Demo

 
Siggy
Siggy's picture

Joined: 2008-02-23
Posts: 6
Posted: Sun, 2008-02-24 23:44

Thank you for helping me find what I had set incorrectly.

I had the main album hidden. Gallery2 must have set a cookie that let the machine I was working on see the Random Image block on my blog and not on other machines.

What I was trying to accomplish was making the Gallery2 main page just a login page. What do I need to do to achieve this? Could you direct me to a post that outlines how?

Sig
www.ModernSoapbox.com

 
ozgreg
ozgreg's picture

Joined: 2003-10-18
Posts: 1378
Posted: Sun, 2008-02-24 23:48

I am a little confused at your requirement, you do not want to display any albums to guest, you must be a registered user?

____________________________________
Wordpress / Gallery2 (WPG2) Plugin, , WPG2 Documentation, WPG2 Demo

 
Siggy
Siggy's picture

Joined: 2008-02-23
Posts: 6
Posted: Mon, 2008-02-25 00:26

I just want the Gallery2 main page to be a login page rather than display the albums when someone visits the Gallery2 site. Can that be done?

Sig
www.ModernSoapbox.com

 
ozgreg
ozgreg's picture

Joined: 2003-10-18
Posts: 1378
Posted: Mon, 2008-02-25 01:58

Hmmm I am not sure if I can, can I suggest you try posting in the Customization forum instead, as this is not really WPG2 related..

____________________________________
Wordpress / Gallery2 (WPG2) Plugin, , WPG2 Documentation, WPG2 Demo

 
Siggy
Siggy's picture

Joined: 2008-02-23
Posts: 6
Posted: Mon, 2008-02-25 07:16

Will do. Thanks again for the help, ozgreg.

Sig
www.ModernSoapbox.com