How do I display an image from my custom theme file?

(Or: AHHHHHHH! Does everything in Drupal have to be this hard???! *forehead-keyboard-slam*)

Trying to get two sizes of an image in a custom template, one for a custom <img> tag and the other for an <a> link. Eventually it'll launch a sweet Lightbox style image archive. Same image, two different sizes. The size names were defined in the Image module's control panel. Simple enough goal. (It's part of a "Photo" custom content type I made.)

Hours spent looking through documentation, not one single page on how to get the URLs for an <img src="..."> tag and <a href="..."> tag! Found this page (Imagecache), and another page claims that Imagecache is now part of Core in D7, but none of its instructions work. For example, it doesn't even say how to get that "$image" variable it uses to begin with! In my theme override file for the Photo content type, no global variable "$image" is defined, and I no idea how to get it. (I do have the core Image module active.) Spent a few hours last night on this too.

Multisite Total Confusion

I just upgraded my site to v7 and I am total confused by the instructions I have read about setting up a multisite. In v6, I simple created a folder under ~/public_html/sites with the same named as the domain and then I copied the settings.php into the new domain's folder. Then I navigated to the the new domain.com/install.php and I finished up. Now, I keep finding references to symbolic links, etc and none of it makes since to me. Nor does it work.

This is what I have right now:

Creating page with list of node article teasers

I am trying to create a list of article teasers a bit like this: http://www.ocduk.org/ProductionDemo/ocduk-news But this link only shows the list from a certain tag category.

What I want to do is create the same list but with all tag categories.

Is there an easy way to do this? Or would I need to create it through views?

Delete Fields Revisions in Drupal 7!

How Can I delete all field revisions in Drupal 7? I could not find any option for this in Drupal Administration.

I still can empty all field_revision_* tables and also delete all record from field_data_* which their revision_id > 1, But I'm wondering is there any way to Delete Revisions from Drupal Administration?

Problem with adding images in drupal 7

Hi
I have got a problem with drupal 7. When a I added images by WYSWIG module (ckeditor) that images is not show in post. I can not see any images in any content when I added it by edytor. But If I added images by upload i can see it. Anybody know how to resolve this problem? I sorry for my English.

Darek

SOLVED (maybe): D7 submit-driven AJAX form with command list and no wrapper

I'm trying to reproduce the 'wrapper'-based behavior in my submit-driven AJAX form so I can add more AJAX commands. I started with something like:

$form['submit']['#ajax'] = array( 'callback' => 'my_callback', 'wrapper' => 'my_wrapper' );

(note: All the code is pretty much the same as what I have, with IDs and function names replaced)

Pages

Subscribe with RSS Subscribe to RSS - Drupal 7.x