Forum

Please make sure that you have read the documentation and extensive resources provided on this site before posting your question!

Dynamic Content Gallery Resources

DCG Version 4.0 beta is now available for download and testing. This is a development version and not recommended for live sites. Read more here.

Note that the current stable release of the DCG is version 3.3.5.

Please consider registering
guest

Log In Register

Register | Lost password?
Advanced Search:

— Forum Scope —



— Match —



— Forum Options —




Wildcard usage:
*  matches any number of characters    %  matches exactly one character

Minimum search word length is 3 characters - maximum search word length is 84 characters

Topic RSS
Issue adding it to static page
Status: fixed
December 29, 2011
3:34 am
Sabrina
Member
Forum Posts: 3
Member Since:
December 29, 2011
Offline

I am using the default twenty eleven theme. My site is http://stellarbeam.com, using 3.0 version of wordpress (whatever the latest version is). I am using a static page for homepage. My email address is thunderseed@gmail.com

If this means anything, I am locating and editing my themes files through my web server c panel.

Right now I have the Dynamic Content Gallery displayed under index.php, it shows up fine for my blog page, so it works. It works fine.

Ideally, I want it to show up on my static home page. Not my blog page.

But when I add both versions of to "page.php" nothing shows up. It doesn't do any thing.

When I add it to "content-page.php" the gallery shows up but it messes up my page content and replaces it all with a random post.

I can't figure out where else to add it, i've tried all files, and the only one that comes close is content-page.php under my theme files, it shows up there, but still messes up all my content.

I have the script restrict loading set to "home page only", and i've tried all the other settings too but they make the gallery appear dysfunctional.

I also tried downloading plugin "widgets for pages" to manually stick this content gallery under my header, but that didn't work either. Well it did, i had the gallery working fine, but that widget for pages plugin was dysfunctional, it erased all my sidebar widgets. And i cant have that.
Otherwise, i don't see how else using dynamic content gallery as a widget is even applicable, used as side widgets you can't see it, and i don't have use for it at the bottom of the page.

So basically i've wasted 74 hours trying to figure this out, very frustrated, without getting anywhere, im done lol, and i would very much appreciate some help.

PS i am not technically inclined. So if you do respond, i need basic instructions. Thanks,

- Sabrina Geiger

December 29, 2011
9:09 am
Ade
Admin
Forum Posts: 2493
Member Since:
August 25, 2008
Offline

Hi,

Assuming your Dashboard > Settings > Reading > Front page displays option is set to static, and you have created a Page called "Home", then the front page of your site is being output by page.php, not index.php. The Template Hierarchy is a useful resource for understanding WP templating.

So, you can add the DCG template tag to page.php but, as mentioned in the Configuration Guide, the template must not be used within the Loop. The file content-page.php is entirely within the Loop, hence the layout problems you described. This part of the Configuration Guide covers this.

Therefore, add the DCG template tag to page.php, but above this line:

<div id="content" role="main">

You also need to wrap the template in Conditional Tags so that it only appears on the front page. You can use is_front_page() for that, like this:

<?php if( is_front_page() ) {
dynamic_content_gallery();
} ?>

You will then have to change the DCG Settings > Load Scripts setting to "other" – which is not a recommended setting.

My advice is to remove the DCG from index.php and only display it on your home page, as describing above. You can then change the DCG Settings > Load Scripts option to "homepage".

BTW, TwentyEleven is a surprisingly difficult theme to work with if you want more than "just" a blog. Its templating is, IMO, overly complicated and frustrating – as demonstarted by your experience.

Dynamic Content Gallery: Have you read the Configuration Guide and FAQ?
December 29, 2011
10:52 am
Sabrina
Member
Forum Posts: 3
Member Since:
December 29, 2011
Offline

Thanks for the fast response Ade,

I wish I could say it is working now, but it's still the same. I followed your instructions to a T. I'm sure I even did this millions of times already. The weird thing is when I put the code into page.php where it is supposed to go, it does absolutely nothing, but it also doesn't do anything when i place it anywhere else under page.php. It doesn't mess up there.

It messes up under "content-page.php" but at least it shows the gallery there. I know content-page.php isn't the right place to put it. Content-page.php is basically the content page file for page.php so I thought i would try it there in the beginning when page.php wasn't working.

It's probably something to do with the theme. Yeah I am getting frustrated with this default twentyeleven theme, but I love the look and even the "best top themes" I've tried on don't come close to it. I don't plan on making any other changes to it thankfully, just really like this content slider. I've posted a support thread in the wordpress.org forums about how to find the static page file for twenty eleven. I am thinking that maybe it has a separate place in the theme where the static page is effected. Because I have tried everything… and this should work.

Perhaps I will test that theory out, try on a new theme and see if page.php works. Then I will know for sure it's the theme and not some stupid mistake im making. I'll keep ya posted.

December 29, 2011
11:02 am
Sabrina
Member
Forum Posts: 3
Member Since:
December 29, 2011
Offline

Okay, well i quickly changed themes and inserted the code. Took me 2 seconds. Page.php works in that theme. The dynamic content gallery showed up fine on static page. I wish I thought of doing this test sooner.

Because now I know my problem is my theme. Not the dynamic content gallery. Seriously wish i thought of doing this sooner.

Stupid twentyeleven theme. Good idea that i brought this issue to the wordpress.org forums, because there is not much you can help me with here now! Thanks for the support!

I've got it figured out. Well, resolved that it's something in my theme that's being dysfunctional not the slider.

Thanks :)
Sabrina

December 29, 2011
2:15 pm
Ade
Admin
Forum Posts: 2493
Member Since:
August 25, 2008
Offline

Hi Sabrina,

Glad you found a solution!

The theme isn't dysfunctional, it's just damn difficult to work with in cases like this. So, don't be too hard on TwentyEleven – it does what it does, but it's not user-friendly at all. :-)

Dynamic Content Gallery: Have you read the Configuration Guide and FAQ?
January 15, 2012
2:17 am
friforjindam
New Member
Forum Posts: 1
Member Since:
January 15, 2012
Offline

Hi,

This tutorial seems very informative. I too am experiencing the same issues, however, I'm on thesis (not twenty eleven). Is there an equivalent to "page.php" for Thesis. All I'm finding in my file manager is options_page.php and am having difficulties figuring out where to insert the dynamic content gallery tag in order to make it show up solely on my static front page. (weddingnouveau.com). Note, I haven't activated the static page yet, as I would like to get this resolved before I do. Please help.

January 18, 2012
2:14 pm
Ade
Admin
Forum Posts: 2493
Member Since:
August 25, 2008
Offline

friforjindam said:

Hi,

This tutorial seems very informative. I too am experiencing the same issues, however, I'm on thesis (not twenty eleven). Is there an equivalent to "page.php" for Thesis. All I'm finding in my file manager is options_page.php and am having difficulties figuring out where to insert the dynamic content gallery tag in order to make it show up solely on my static front page. (weddingnouveau.com). Note, I haven't activated the static page yet, as I would like to get this resolved before I do. Please help.

Hi,

I haven't played with Thesis for a while but I seem to recall there is a Features box or similar, in Thesis options, which can be used for custom code. If so, you can use use the code shown earlier in this thread.

Dynamic Content Gallery: Have you read the Configuration Guide and FAQ?
May 16, 2012
3:54 pm
robert
New Member
Forum Posts: 1
Member Since:
May 16, 2012
Offline

Hi Ade,

 

Any update or ideas about the apparent incompatibility between DCG and Twenty Eleven? I've tried placing the appropriate code in every possible place in page.php and Twenty Eleven just won't respond. Nobody at Wordpress seems to have any ideas as to how to get DCG working in Twenty Eleven via shortcode. If one uses it as a plugin, DCG works just fine; but I would really like to use this lovely plugin via shortcode.

Forum Timezone: UTC 1

Most Users Ever Online: 28

Currently Online:
10 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

johnbroome: 13

speedyp: 12

sjpeaches: 12

CherylMcL: 10

gscorp: 8

lsnoei: 8

Member Stats:

Guest Posters: 770

Members: 1300

Moderators: 0

Admins: 1

Forum Stats:

Groups: 2

Forums: 7

Topics: 980

Posts: 4299

Newest Members: jochris26, eva-aa, Tushar, chargers3, jwhetstone, robert

Moderators:

Administrators: Ade (2493)