Closed (fixed)
Project:
Share
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
6 Nov 2007 at 05:19 UTC
Updated:
21 Nov 2007 at 15:48 UTC
I like your demo with the 2 columns of links. How did you do that? My list is pretty long.
Thanks
Comments
Comment #1
greenskin commentedThe 2 columns is done with a little css trickery. If you install the share module, it will do the same as the demo. Or if you are wanting your own custom style for your popup but would like to use the two columns, I would suggest copying the share.css file then making your modifications to that file as you see fit. But in simplest form, to generate the two columns you would apply the following css to the li tags:
Of course you would specify a width for the ul tag so that the 45% is of the ul width and not a different parent width.
Comment #2
rtdean93 commentedThanks - this worked... Now another CSS question....
I added the Message field back to the Share-form for the email this form. My textarea that I added is extending past the box. The width setting didn't fix it. Here's my code...
function share_form($nid = null) {
global $base_url, $user;
$form = array();
if ($nid != '') {
$emailtype = 'email';
$form['node'] = array('#type' => 'value', '#value' => node_load((int)$nid));
}
else {
$emailtype = 'postcard';
}
$form['yemail'] = array(
'#type' => 'textfield',
'#title' => t('Your Email'),
'#default_value' => $user->mail,
'#size' => 24,
'#maxlength' => 256,
'#description' => null,
'#attributes' => null,
'#required' => true,
);
$form['yname'] = array(
'#type' => 'textfield',
'#title' => t('Your Name'),
'#default_value' => $user->name,
'#size' => 24,
'#maxlength' => 256,
'#description' => null,
'#attributes' => null,
'#required' => true,
);
$form['recipients'] = array(
'#type' => 'textfield',
'#title' => t('Send To'),
'#default_value' => str_replace(', ', "\n", $recipients),
'#size' => 24,
'#description' => t('Enter one address or multiple addresses separated with commas.'),
'#attributes' => null,
'#required' => true,
);
$form['message'] = array(
'#type' => 'textarea',
'#title' => t('Personal Message'),
'#size' => 24,
);
$form['nid'] = array(
'#type' => 'hidden',
'#value' => $nid,
);
$form['forward_footer'] = array(
'#type' => 'hidden',
'#value' => variable_get('forward_footer', ''),
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Send'),
);
Comment #3
greenskin commentedFor the textarea type, #size is not a valid property. Textarea's size is defined by #rows and #cols.
http://api.drupal.org/?q=api/file/developer/topics/forms_api_reference.h...
Comment #4
rtdean93 commentedthanks. its fixed.
Comment #5
greenskin commented