Hello, I have problems trying to install an advanced ddblock slideshow. First of all, I get no response from drupal after I uncomment those lines in the template.php file of my theme (white jazz)
I get this error: warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\infolog\sites\all\themes\mywhitejazz\custom\modules\ddblock\ddblock-cycle-block-content-upright20.tpl.php on line 47.
What I see is a white space (I did not checked the custom slide content, but one of those given with "upright 10-50" file), with its title above ("ddblock News Item slideshow"), the two lines of the pager (prev and next, at bottom of the block, as I've set up into config. steps) and no images...... since I selected "display on front page" I also see in the body of the front page the two images I added to create a "News Item" content, all surrounded by what I wrote into body and slide textarea. I'm pretty sure I installed the custom directory in the right place (sites/all/themes/mytheme)
The tutorial says I should uncomment those lines in template.php, and that's what I do, but then as I refresh nothing happens.
I need help, cause I don't understand one line of this code, and I know this ddblock can work right after a little trial and adjustment! if someone has a little time to waste, I beg your help!!!!!!!!!!!!
I also changed the path settings into the image field for the "News Item" content type. Another detail is that I have created a field "image resized", relative to "pages" content type... can this be a problem? I don't think so but who knows....... maybe a set the view uncorrectly.... ah and I enabled as a block the one called "ddblock news Item slideshow", and not the other "News Item slideshow".. so I wonder how it is that I see it displayed on body of front page........ Maybe there's a problem with the view settings??

thanks for your help, I really really appreciate....... and tell me if you need more details.. unfortunately I'm on local so I can't give you a link...

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

giozzz’s picture

Title: Can't end the installations, cause I can't see debug lines after uncommenting in template.php » Can't end the installation, cause I can't see debug lines after uncommenting in template.php
giozzz’s picture

I've just noticed that something very strange happens, but regarding tha creation og a basic ddblock (that I can't make work too...): when I go to delete the basic ddblock block I've created, because it doesn't work, it appears in the region of the page where I placed it, right after I delete it............. there no pager and, only two slides (instead of 4) but at least it appears.. then I go on and change node and it disappears....

ppblaauw’s picture

Status: Active » Postponed (maintainer needs more info)

Can you send a screenshot of what you see?
Did you check the troubleshooting part of the faq at ddblock.myalbums.biz?

More information about #2 you can find in the issue: http://drupal.org/node/491876

giozzz’s picture

Yes I went to the troubleshooting and couldn't find nothing useful... now I'll try out this solution you suggest me for the basic ddblock, then I decided to try to build an advanced one in a plain drupal site... maybe I'll see what I make wrong then... I'll post here again later, maybe with the screenshot: anyway when I try with the advanced ddblock the only thing I see it's the pager, and only the "Prev,Next." PAger, not the one with numbers...and instead of images a white space. thanks for your answer, I hope I'll figure it out with a little help.

ppblaauw’s picture

Version: 6.x-1.x-dev » 6.x-1.0-rc6

Your template file looks ok.
Your custom folder is at the right place.

Why does it not use the template.php file?
The template.php file is at: C:\xampp\htdocs\infolog\sites\all\themes\mywhitejazz\ ?

Could you copy the drupal_set_message lines to the first line in the preprocess functions, so it becomes:

function mywhitejazz_preprocess_ddblock_cycle_pager_content(&$vars) {
  drupal_set_message('<pre>' . var_export($vars['settings']['view_name'], true) . '</pre>');
  drupal_set_message('<pre>' . var_export($vars['content'][0], true) . '</pre>');
  if (($vars['output_type'] == 'view_fields') && ($vars['pager_settings']['pager'] == 'custom-pager')){

Hope this will show the variables and we can pinpoint where the issue comes from.

giozzz’s picture

Yes the template file of my whitejazz theme is in the path you pointed, exactly where it should be.
I'm not sure I fully understood what you just suggested me, do I have to copy those lines you wrote at the beginning of the first set of "preprocess functions" lines, or in the second set.. (you know there's two couples of them to uncomment..)? it'll be very kind of you if you could explain it better (sorry if I don't catch it immediatly, but between english language and code lines I get a little dizzy sometimes;))
would be great if I could have debug messages displayed after uncommenting.
Anyway right now I was trying to get around the obstacle this way:
I've emptied my site of all its modules, changed theme to garland, and managed to build an advanced slideshow which actually works (... well, I still have problems with slide text boxes but sure I messed up something, I must check it out better). So I've copied the debug messages given by drupal after uncommenting garland ' template, and now I'm ready to start over on mywhitejazz: I'll add those lines you gave me, if nothing comes out I'll copy the code I obtained after rearranging garland... will sure be trickier but anything to make this slideshow work!!!! Thanx everybody, I'll be back later to tell you what happened.

ppblaauw’s picture

I just suggested to copy the drupal_set_message lines I mentioned before to the if statement in the content preprocess function to see if this function is called or not.

Good you got it working on a fresh install, so you know it works.
Now to find out what is the difference on your other installation.

Hope this explains what I wanted to accomplish and hopefully you also get it working with the other theme.

Clearing the cache will also help sometimes.
Administer > Site configuration > Performance
Clear cache at the bottom of the page

giozzz’s picture

What I didn't say before, is that also garland theme gave me problems with the debugging part: I could uncomment only first preprocess function, not the second one(or better: I obtain debug infos only with the uncommenting of first one, as for the second part, nothing happens after deleting the two slashes...)

<blockquote>I just suggested to copy the drupal_set_message lines I mentioned before to the if statement in the content preprocess function to see if this function is called or not.</blockquote>

now I did this, and I am finally able to obtain infos after uncommenting second part of template.php
but
I still can't have the pager text boxes displayed near my slideshow block (which is always working allright, cycling and with its"read more.." button, "slide text" and everything).... I've tried a lot of different combinations always following the tutorial and faqs, but nothing works.
I give up garland now, and go with mywhitejazz. thanks again for your explanations (very very useful!!)

giozzz’s picture

Hello.... unfortunately adding that code in mywhitejazz template.php doesn't make the debug appear... and also my method failed, cause I've copied the lines I obtained on garland after the uncommenting, but nothing happens on mywhitejazz: I only get a white space instead of the slideshow, and the text from the pager at bottom (or top) of this empty white space, prev. next. Nothing more.
What should I do?
Now I'm disconnecting, but tomorrow I'll try again... I hope you can help me some more!!!Thanks again

-----------------------
I confirm that with the whitejazz theme debug lines won't come out, while with garland they do. Even if I add lines at the beginning of preprocess functions lines, it's the same... hope someone has an idea..... thanks everybody anyway

ppblaauw’s picture

Can you send the result of the debug lines, so I can help you better.

giozzz’s picture

this is the result of the debug after I uncomment first part in Garland. In Whitejazz no debug lines are ever displayed, also when I paste those two lines (

drupal_set_message('<pre>' . var_export($vars['settings']['view_name'], true) . '</pre>');
  drupal_set_message('<pre>' . var_export($vars['content'][0], true) . '</pre>');

) right at the beginning of preprocess function.

'news_items'


stdClass::__set_state(array(
   'nid' => '72',
   'node_title' => 'News item 1',
   'node_data_field_pager_item_text_field_pager_item_text_value' => 'News Item pager 1',
   'node_type' => 'ddblock_news_item',
   'node_vid' => '72',
   'node_data_field_pager_item_text_field_slide_text_value' => 'News item slide 1',
   'node_data_field_pager_item_text_field_image_fid' => '140',
   'node_data_field_pager_item_text_field_image_list' => '1',
   'node_data_field_pager_item_text_field_image_data' => 'a:3:{s:11:"description";s:0:"";s:3:"alt";s:0:"";s:5:"title";s:0:"";}',
   'node_revisions_body' => 'News Item 1  News Item 1  News Item 1  News Item 1  News Item 1 News Item 1 News Item 1 News Item 1 ',
   'node_revisions_format' => '1',
   'node_created' => '1247470921',
))

uncommenting the second part won't show me nothing until I do what you suggested, copy the lines right after first sentence of preprocess. That done, I have this code (all this always in Garland):

 array (
  'delta' => '5',
  'output_type' => 'view_fields',
  'pager' => 'prev-next-pager',
  'pager_container' => NULL,
  'pager_event' => NULL,
  'pager_height' => 63,
  'pager_width' => 195,
  'imgcache_pager_item' => '',
  'pager_position' => 'top',
  'template' => 'upright20',
  'custom_template' => NULL,
  'view_name' => 'news_items',
)stdClass::__set_state(array(
   'nid' => '72',
   'node_title' => 'News item 1',
   'node_data_field_pager_item_text_field_pager_item_text_value' => 'News Item pager 1',
   'node_type' => 'ddblock_news_item',
   'node_vid' => '72',
   'node_data_field_pager_item_text_field_slide_text_value' => 'News item slide 1',
   'node_data_field_pager_item_text_field_image_fid' => '140',
   'node_data_field_pager_item_text_field_image_list' => '1',
   'node_data_field_pager_item_text_field_image_data' => 'a:3:{s:11:"description";s:0:"";s:3:"alt";s:0:"";s:5:"title";s:0:"";}',
   'node_revisions_body' => 'News Item 1  News Item 1  News Item 1  News Item 1  News Item 1 News Item 1 News Item 1 News Item 1 ',
   'node_revisions_format' => '1',
   'node_created' => '1247470921',
))'news_items'stdClass::__set_state(array(
   'nid' => '72',
   'node_title' => 'News item 1',
   'node_data_field_pager_item_text_field_pager_item_text_value' => 'News Item pager 1',
   'node_type' => 'ddblock_news_item',
   'node_vid' => '72',
   'node_data_field_pager_item_text_field_slide_text_value' => 'News item slide 1',
   'node_data_field_pager_item_text_field_image_fid' => '140',
   'node_data_field_pager_item_text_field_image_list' => '1',
   'node_data_field_pager_item_text_field_image_data' => 'a:3:{s:11:"description";s:0:"";s:3:"alt";s:0:"";s:5:"title";s:0:"";}',
   'node_revisions_body' => 'News Item 1  News Item 1  News Item 1  News Item 1  News Item 1 News Item 1 News Item 1 News Item 1 ',
   'node_revisions_format' => '1',
   'node_created' => '1247470921',
))

with whitejazz there's nothing to do, drupal doesn't give any kind of debug....... thank you for your time, you're really kind!!!!

ppblaauw’s picture

What I understand is that the slideshow works in your Garland theme.

The code in the debug lines looks ok.

That you did not see the debug lines for the pager, is because in your example you use the prev/next pager which does not need pager items. The first if statement in the pager preprocess function fails.

That you don't see debug lines in your mywhitejazz theme suggests that the functions are never called.

Is the other part of the template.php file called?
Or just try to make an error occur in the template file to see if it is called at all, just by putting some random text in it.

giozzz’s picture

oh I see, now I'll change the pager, just to try. In Garland the slideshow works partially, cause I can't have the slide text boxes displayed... since they come out after uncommenting second statement of preprocess, I was thinking they won't show up because of some kind of error. I've tried every combination, really, but can't have those slide navigation buttons displayed .....
If I put random text into template.php of white jazz I get the error message on white page, so I guess it works...
but if I try to copy the debug I got from garland uncommenting into whitejazz nothing happens: still the ddblock remains all white, only one black line which displays "prev" and "next" buttons.
Any Idea? (drop the theme..? uff.....) thanks again anyhow!!!!

ppblaauw’s picture

Just to make sure: Your theme name is mywhitejazz not whitejazz?
The template.php file is still the same as you send in your first message?

Try also to use another pager in the settings.
Clear the cache.
Have a look at the sourcecode.
What do you see there.

Also you could add a line like this at the top of the preprocess function to find out if it is called:

drupal_set_message('<pre>This function [function name] is called</pre>');

How do you show your slideshow. In a region or in a node?

Just trying to come up with suggestions to find out what the cause of the issue could be.

giozzz’s picture

FileSize
8.15 KB

sure, we have to go on the trialsN' errors way!
now I switched to litejazztheme... and there the ddblock works (same problem with slide text boxes, so now it's sure it's my fault, I've messed up something).
The theme is renamed as mywhitejazz, the template.php is still the same, no changes. I clear the cache many many times, everytime I refresh after changing files.. I put the slideshow in the header block.. anyway always in a region ( but the view I referred it to a page, as shown in the tutorial).
I've tried to add the line you wrote.. but since I really don't know how to adjust it (what "function"? what "function name"?) it can't be useful for me.
I really have no more time to spend on this, so I guess in the end I'll stay on the litejazz and quit the whitejazz.. there's obviously something in it that prevents the ddblock from working.
Now I'll try to solve the question about the slide text boxes, searching the net... or posting again here.
I thank you for your time. Anyway If you've got some more ideas post it, I'll come and see and sure give it a try.
It's not that I want to give up, but I have too little time, you know! So I must pass through this issue....

I stick here the template.php of mywhitejazz

Dennis Cohn’s picture

Giozzz?

Maybe you've forgotten to check the views - News: Block in admin/settings/ddblock/settings
I've had the same problem and when I checked this option, everything works fine!

ppblaauw’s picture

@MacDennis

Thank you for sharing your solution

giozzz’s picture

Hello MacDennis and tnx for the tip!! as soon as I've a little time I'll try this out... now Iswitched to another time (litejazz) but I've kept all mywhitejazz files so I'll sure give it a try.. infact, I think the view was set by default on "pages" and not "blocks".. but I ain't sure, must see!! thanks again!!!

linitrex’s picture

PROBLEM:

I do install a new Drupal.
Then I do install and enable the modules needed.
I create the Content type and the view by importing files from
Export_files_V1.6.zip
and copy/paste the functions to the zen theme tamplate.php with the proper
theme name replacement.

I follow all the steps from the documentation.
When I create a ddblock from /admin/settings/ddblock and place it in the
right region from admin/build/block it does not appear.

When I go back to admin/settings/ddblock and delete the block it
surprisingly appears and displays correctly in the proper region although
it should not appear at all because it is deleted.

When I go to admin/build/block again the block disappears and never shows
again.

So the only way to show a ddblock is to make it and then delete it!

SOLUTION:

Just solved the problem!!!

When I import the Content type, by default the Nodes created are
unpublished. When I published the nodes it is ok.

ppblaauw’s picture

Can other users having this issue confirm what linitrex says in Post #19, solves the issue.

bstrange’s picture

I am having the issue where uncommenting does not display the error. Have cleared cache, have added rndom chars to make sure the template.php is being called (shows whitescreen error with random text), just can't seeem to get the messages needed to debug.

Named everything exactly like the tutorial, just chose upright 50 in place of the custom template used in the screencast. Still get the error message:

warning: Invalid argument supplied for foreach() in /home/villacol/public_html/thenewvilla/sites/all/themes/villa-custom-01122009/custom/ddblock-cycle-block-content-upright50.tpl.php on line 47. No matter what I try. (attached template.php)

bstrange’s picture

FileSize
8.35 KB

oops forgot to change template php

Edit to add link to test node: http://www.thenewvilla.villacollectionsdesign.com/content/dd-block-test

ppblaauw’s picture

#21,22, thanks for the detailed issue post!

In the warning I see that your theme_name is: villa-custom-01122009
In the template file you use: VillaCustom2010

VillaCustom2010

needs to be changed in both preprocess functions to:

villa-custom-01122009

Note:The theme_name to use is case sensitive, so it needs to be exactly the name you use for your theme.

Hope this helps you further, please let me know.

bstrange’s picture

The theme name has actually been changed to VillaCustom2010 as template php doesn't support dashes (see .info file attached)

To be safe, I am changing the .info name that was villa-custom-01122009.info to VillaCustom2010.info in the meantime.

bstrange’s picture

; $Id: garland.info,v 1.5 2007/07/01 23:27:32 goba Exp $
name = VillaCustom2010
description = Tableless, recolorable, multi-column, fluid width theme (default).
version = VERSION
core = 6.x
engine = phptemplate
stylesheets[all][] = style.css
stylesheets[print][] = print.css

; Information added by drupal.org packaging script on 2009-12-16
version = "6.15"
project = "drupal"
datestamp = "1260996916"

at least I *think* the line 2 entry for name determines the theme name

You should add to faq that template.php doesn't support dashes or spaces in theme name in the preprocess statement

Edit to add: I also wanted to confirm #19 assertion that the default state of the nodes is unpublished and they have to be changed to published before athe display block will even appear.

bstrange’s picture

Ok, NOW we are getting somewhere, and this is the answer to another couple issue queues semi related to this as well (where you had given similar responses to what you gave me) and I have pieced this together.

You keep telling people to change the theme name, and that is being interputed as "change the theme name *WITHIN* the .info file (line 2) to 'yourthemename' however the error isn't throwing an error on the theme name within the .info, it is throwing the name *OF* the .info

In my case, my .info was called villa-custom-01122009.info (it was also informally named villa-custom-01122009 on line 2 of the .info file).

I originally tried to add that name to the preprocess function; however, because template.php does not support either dashes or spaces in the theme name, I changed the theme name on line 2 of the .info file to VillaCustom2010

This allowed the template.php to be called and the container to show up but throws the error you related in #23

Now this has been a source of confusion in several similar issues, by changing the name on line 2 INSIDE the .info I allowed the container to load and it threw the error

warning: Invalid argument supplied for foreach() in /home/villacol/public_html/thenewvilla/sites/all/themes/villa-custom-01122009/custom/ddblock-cycle-block-content-upright50.tpl.php on line 47.

HOWEVER, uncommenting the template.php lines as in the video showed NO code.

After reading your reply; however, I thought, "maybe I should try changing the actual name OF the .info file to match" making it VillaCustom2010.info and

viola! the uncommented lines now produce code for me!!!

Of course, this broke my theme as I was using a colorized/customized version of Garland and most of the graphics and css, etc is saved in /sites/default/files/color/villa-custom-01122009-d19de82a and references the old villa-custom-01122009.info that no longer exists... howeverI can rebuild my theme and resolve this issue :)

I am so pleased we figured this out!! :)

On a side note, in retrospect, I need to figure out a way to customize a Garland theme for color and css and have it save to sites/all/themes/mycustom themename rather than in /sites/default/files/color/referencetocustomtheme, but that is not your issue :)

bstrange’s picture

So some of the other's I see with issues that I *think* are this issue are:

candres0115's issue http://drupal.org/node/678952

and drecute and amyl issues (in particular #5-8 between you and drecute) http://drupal.org/node/543318

I think, judging from the number of similar issues, the following should be added to the FAQ:

1. Your theme name must NOT contain dashes or spaces as it will be used as code within the template.php when adding it to the preprocess functions. Template.php does NOT accept spaces or dashes in the theme name.

2. If you are having this issue, you must make 2 changes to your .info file. The first being, change the name of the .info to mythemenamewithoutspacesordashes.info AS WELL AS line 2 within the .info to

; $Id: garland.info,v 1.5 2007/07/01 23:27:32 goba Exp $
name = mythemenamewithoutdashesorspaces
description = Tableless, recolorable, multi-column, fluid width theme (default).
version = VERSION
core = 6.x
engine = phptemplate
stylesheets[all][] = style.css
stylesheets[print][] = print.css

; Information added by drupal.org packaging script on 2009-12-16
version = "6.15"
project = "drupal"
datestamp = "1260996916"

*Note, intire .info code posted for demonstration, however, the change will be specific to your theme's .info and only line 2

name = mythemenamewithoutdashesorspaces

will need to be changed

:)

Edit to add: there may be others in the issue queue with this problem, the ones I listed were just the ones I remember coming across while reading issues trying to troubleshoot last night.

ppblaauw’s picture

In cases where I say to users: You need to change the theme name according to the theme you use. I always mean to change the themename in the preprocess function. Not in the themes .info file.

Maybe this is confusing for some users, and I should say:

change [THEME_NAME] in the preprocess functions into the name of the theme you use. 

Edit:Will add your suggestion about themenames with dashes and spaces to the FAQ that you can not add preprocess functions for the theme because PHP does not allow dashes (-) or spaces in function names.

Thanks for your help with pinpointing the issues users have with there themes.

bstrange’s picture

Ok, I went from feeling smart and being pleased with getting the debug code to show up to being unsure of what to do with it lol!

The debug code is as follows, but I am not sure what parts of it I am supposed to put into template.php or where exactly to place it within template.php

array (
  'delta' => '4',
  'output_type' => 'view_fields',
  'pager' => 'custom-pager',
  'pager_container' => NULL,
  'pager_event' => NULL,
  'pager_height' => 63,
  'pager_width' => 195,
  'imgcache_pager_item' => '',
  'pager_position' => 'bottom',
  'template' => 'upright50',
  'custom_template' => NULL,
  'view_name' => 'news_items',
)
stdClass::__set_state(array(
   'nid' => '95',
   'node_title' => 'The Lull lamp',
   'node_data_field_pager_item_text_field_pager_item_text_value' => 'The Lull Lamp',
   'node_type' => 'ddblock_news_item',
   'node_vid' => '95',
   'node_data_field_pager_item_text_field_slide_text_value' => 'The Lull Lamp is a concept lamp that opens slowly in the morning, getting brighter as it expands. In the evening, it contracts and gently dims, much like a flower.',
   'node_data_field_image_field_image_fid' => '109',
   'node_data_field_image_field_image_list' => '1',
   'node_data_field_image_field_image_data' => 'a:3:{s:11:"description";s:0:"";s:3:"alt";s:0:"";s:5:"title";s:0:"";}',
   'node_revisions_body' => 'The Lull lamp is a concept lamp created by 3 designers, Marianne Varmo,
Heidi Buene and Audun Kollstad. In the morning the light opens slowly,
getting brighter as it expands; then, in the evening, it contracts and
gently dims, much like a flower. The Lull lamp produces a gradually dim
instead of the abrupt dark you get from a normal lamp when it gets
switched off or the instant glaring brightness when a light is switched
on in the morning. Shaped like a flower, the Lull lamp has a calm and
soothing appearance when it\'s closed and a bright energetic appearance
when it is fully \'blossomed\'. Currently, Lull is still a concept, but
if everything goes as planned, this award winning lamp design should be
put into production and available in stores in 2010.',
   'node_revisions_format' => '1',
   'node_created' => '1263722695',
))
'news_items'
stdClass::__set_state(array(
   'nid' => '95',
   'node_title' => 'The Lull lamp',
   'node_data_field_pager_item_text_field_pager_item_text_value' => 'The Lull Lamp',
   'node_type' => 'ddblock_news_item',
   'node_vid' => '95',
   'node_data_field_pager_item_text_field_slide_text_value' => 'The Lull Lamp is a concept lamp that opens slowly in the morning, getting brighter as it expands. In the evening, it contracts and gently dims, much like a flower.',
   'node_data_field_image_field_image_fid' => '109',
   'node_data_field_image_field_image_list' => '1',
   'node_data_field_image_field_image_data' => 'a:3:{s:11:"description";s:0:"";s:3:"alt";s:0:"";s:5:"title";s:0:"";}',
   'node_revisions_body' => 'The Lull lamp is a concept lamp created by 3 designers, Marianne Varmo,
Heidi Buene and Audun Kollstad. In the morning the light opens slowly,
getting brighter as it expands; then, in the evening, it contracts and
gently dims, much like a flower. The Lull lamp produces a gradually dim
instead of the abrupt dark you get from a normal lamp when it gets
switched off or the instant glaring brightness when a light is switched
on in the morning. Shaped like a flower, the Lull lamp has a calm and
soothing appearance when it\'s closed and a bright energetic appearance
when it is fully \'blossomed\'. Currently, Lull is still a concept, but
if everything goes as planned, this award winning lamp design should be
put into production and available in stores in 2010.',
   'node_revisions_format' => '1',
   'node_created' => '1263722695',
))
ppblaauw’s picture

You need to change in both preprocess functions. in both 2x:

node_data_field_pager_item_text_field_image_fid

into:

node_data_field_image_field_image_fid

Hope this helps you further, please let me know

bstrange’s picture

Ok I got most of it... just the pager item text and the slide text seem to be reversed

see: http://www.thenewvilla.villacollectionsdesign.com/content/dd-block-test

If I understand correctly, the node's "Pager Item Text" should be the text name for the pager button and the "Slide Text" should be what shows up in the dark grey section of the main image correct?

EDIT TO ADD: Lol, nm, I'm an idiot and reversed my code changes :P

ppblaauw’s picture

What I see in the result of the debug line is that you don't have fields for pager-item-text and for the slide-text.

When you want to use separate fields for the pager-item-text and slide-text you need to add this fields to your content type and the view.

What you see as slidetext (is the title of the node) set with this code in the content preprocess function:

          // add slide_title variable
          if (isset($result->node_title)) {
            $slider_items[$key1]['slide_title'] =  check_plain($result->node_title);
          }

When you e.g. want to use the title also as the text in the pager-item then you need to change this code in the pager preprocess function:

         // add pager_item _text variable
          if (isset($result->node_data_field_pager_item_text_field_pager_item_text_value)) {
            $pager_items[$key1]['text'] =  check_plain($result->node_data_field_pager_item_text_field_pager_item_text_value);
          }

into

         // add pager_item _text variable
          if (isset($result->node_title)) {
            $pager_items[$key1]['text'] =  check_plain($result->node_title);
          }

Hope this explains more how the preprocess functions work and how to map fields from CCK/Views to fields used in the ddblock template files.

bstrange’s picture

Ok, thank you for being so very patient, I seem to have screwed it up even more... now the slide text is correct, but it is still showing up on the pager...I am still working on it.

I have been taking detailed notes on my process and will try to submit a writen (detailed with screenshots) tutorial on my process as a way to give back to the module and the time you have spent with me :)

I am re-reading your last post and muttling through it but I know my code is still messed up atm.

bstrange’s picture

Ok got it all and am working on really getting to know the process on 2 different sites. I learned a lot from your tutorial and from the issues queue and troubleshooting and I feel i have my head almost wrapped around this process thanks so much.

One question, how do I make it so it only changes images on mouseover instead of randomly switching back and forth until someone mouses over the pager?

Thanks again!

ppblaauw’s picture

To change images on mouseover only and not automatically switch from image to image you can set the timeout to 0 (no automatic transitions) or use a longer timeout of e.g. 10 seconds between slides (so it does not switch that quickly and users have more time to read the text) and set the pager effect to mouseover in the ddblock configuration page (I think you already did this last thing).

Hope this helps you further, please let me know.

bstrange’s picture

Outstanding! Will play around with it a bit :)

I actually fixed my theme in retro to reapply itself to the dd block I got working; however, it added some extra pager area...not sure how that happened.

I will shoot you a message when I get a print/screenshot tutorial finished, I want to build several more and make sure I am fully comfortable with it before I do.

bstrange’s picture

Actually...it didn't add extra pager area... when I got it working it was on the 'broken' garland that used the stock garland colors/properties i.e. the background was white and I could not see the extra pager area. Once I fixed my custom garland and the background changed back to black, the extra pager area became noticable.

The next thing I am going to work on is having the 2 (either 'most recent' or preferrably random if that is possible) articles from each of the 3 'story type' choices (custom CCK field for story content type that users can choose 'designer's blog', 'design tips', or 'cutting edge') promote to the dd block container.

Do you have a tutorial for that yet? Is it possible?

(I will probably really play with the simple advanced dd block for a while until I am very comfortable with it before I try what I described above so I don't end up bombarding you with questions!)

ppblaauw’s picture

#27

Changed the faq question: warning: Invalid argument supplied for foreach() in... solution?
Added a faq question: ">When I uncomment the drupal_set_message debug lines I don't see the result.

#36

Actually the extra pager area was already there I think only you did not see it because your background was white before. Have a look at the number of items in the custom/modules/ddblock/ddblock-cycle-pager-content-[ddblock_theme_name].tpl.php file.

$number_of_items = 6; // total number of items to show
$number_of_items_per_row=3; // number of items to show in a row

Probably this will be a setting on the config page in future versions of the module.

Tip or request:
When you have different support request, please create a new issue so they stay helpful for other users.
They will e.g not find this support question in #36 under the title Can't end the installation, cause I can't see debug lines after uncommenting in template.php

bstrange’s picture

A very strange new aspect to this issue... I moved my site form the subdirectory 'sandbox' to the primary domain. The views and content types were exported directly from the sandbox site we got working earlier in this thread. The template file was coppied directly and put into sites/all/theme. Nothing was changed: template.php, the .info file... nothing, yet the ddblock doesn't show the container or pager and uncommenting the lines in template.php does not generate error messages...

I'm kindof stumped, as it was / is working still on http://www.thenewvilla.villacollections.com (in panel on the home page) as well in it's node http://www.thenewvilla.villacollectionsdesign.com/content/dd-block-test ; however it is not working in the primary domain at http://www.villacollectionsdesign.com/content/ddblocktest

Sorry to revive this issue but I'm totally at a loss here :(

Edit to add: It is currently set on the custom theme that was working when we got it working before; however, switching to any of the default upright themes makes no difference.

bstrange’s picture

OK, so I figured it out. I rushed it because I thought everything should be set since I coppied everything straight over and it was except for the block configuration.

When you are configuring a block for the first time on a new site, everything is reset, so basically, the pager position and Display Method were both set to their defaults. Now while this doesn't hurt anything with the pager, it gives us a display 'similar' to when the container isn't configured correctly and also prevents debug code from showing.

It was a stupid mistake on my part, but you might want to add "Make sure Display method is set to "Cycleblock" in the FAQ on debug code not coming up, as this would also be an issue when creating new block/instances and if you are used to just changing the effects and the templates, that selection is easy to overlook.. well at least for short bus riders like myself :P