Hiding an Answer field until the user opens it.

I post photographs with science questions, and I would like for users to be able to click "See Answer" to expose the answer.

http://thehappyscientist.com/blog/science-photo-day-963

I am currently doing this by making the "See Answer" a link to a new page, with the same photo, the same question, and the answer, but it would be so much easier if it could be done on a single page. I have been trying to set it up in Views, but I just can't figure out how to make it work. Anyone have any suggestions?

How do I apply this patch to fix an error?

https://www.drupal.org/node/2458737

I searched and found the link above which shows an error identical to the one that just happened with my site.

The page went white showing only the error. Administration is not accessible.

I am very much a novice. If someone will explain how to use the patch at the link above, I would greatly appreciate your effort.

Thank you!

~Catherine

Getting Default Image URI

Hello,

I'm noticing some weird behavior with getting the path to an image. I have a field called "field_image" on my nodes.

When I edit a node template, I can get the value (path) simply with this:

$uri = $node->field_image['und'][0]['uri'];

This will give me something like "public://sites/default/files/whatever.jpg." If there is no value, it will default to whatever I have set up in that field configuration and point to "public://sites/default/files/default_images/default-image.jpg".

Perfect!

a weird problem with drupal 7

i have a drupal 7.36 installed and working
when one night something happen without i changed anything
and this is the result:

Menu opens article List in one block opens content in second on same page

Hello everyone!

I'm making a bit of progress in learning Drupal and have a few modules installed and have learned the basic stuff to set up a simple site. But I can't quite figure out how to setup the site how I want it to.

What I'm going for is a Microsoft Outlook type layout. I need three columns
First Column - Navigation
Second Column - List of Articles/Content - Based on menu item clicked
Third Column - Content - Loads when clicked from second column but it doesn't change the second column

How to use Cpanel and database password in settings.php

Hi,

In my settings.php I have the following:

$databases = array (
'default' =>
array (
'default' =>
array (
'database' => 'my_databasename_D7',
'username' => 'myusername',
'password' => 'my Cpanel Password',
'host' => 'localhost',
'port' => '',
'driver' => 'mysql',
'prefix' => '',
),
),
);

Pages

Subscribe with RSS Subscribe to RSS - Drupal 7.x