Hi Friends ,
Hi any one pleas say me how to create a new region in blocks like already we have leftbar rightbar..
Thanks in advance
Regards Ram Prasath
The INTERNET now has a personality. YOURS! See your Yahoo! Homepage. http://in.yahoo.com/
1. Make a copy of the theme you are using and put it into a folder called themes, this folder should be in the site/all/, 2. Open the theme_name.info inside notepad or notepad++ (not Word or a word processor) 3. Add a line under the description line: regions[new_region] = New Region 4. Open page.tpl.php inside notepad or notepad++ (not Word or a word processor) 5. Add the lines:
<?php if ($new_region) { ?><div id="new_region" class="new_region_class_name"> <?php print $new_region ?> </div><?php ? ?>
6. Go to the blocks layout page and add blocks to your New Region
You might have to flush all of your caches depending upon how you have your caching settings.
On Thu, Dec 10, 2009 at 3:14 AM, ram prasath < ramprasath_explicit@yahoo.co.in> wrote:
Hi Friends ,
Hi any one pleas say me how to create a new region in blocks like already we have leftbar rightbar..
Thanks in advance
Regards Ram Prasath
The INTERNET now has a personality. YOURS! See your Yahoo! Homepagehttp://in.rd.yahoo.com/tagline_yyi_1/*http://in.yahoo.com/ .
-- [ Drupal support list | http://lists.drupal.org/ ]
Hi,
I'm trying to add a Flash object to an existing module.
I've tried a couple of ways without success.
I've created a module.
I have SWFTool with SWFObject2 enabled
Using JS as per this
$(document).ready(function(){
var flashtags = $('<div>[swf file="http://XXX/sites/all/modules/flashtags/flash/flashtags.swf"]</div>').a ppendTo('#privatemsg-new').get(0);
if (Drupal.jsEnabled) {
Drupal.attachBehaviors(flashtags);
}
});
By doing that I end up with this printed at the bottom of the form
[swf file="http://XXX/sites/all/modules/flashtags/flash/flashtags.swf"]
But no Flash object.
I tried this approach.
function privatemsg_form_alter(&$form, $form_state, $form_id) {
$vars['swf_tags'] = swf("http://XXX/sites/all/modules/flashtags/flash/flashtags.swf",
array('width' => '420', 'height' => '140', 'bgcolor' => '#336699'), FALSE,
array('html_alt' => 'Name of site if flash is disabled.')
);
if ($form_id == 'privatemsg_new' && user_access('create flashtags')) {
$form['privatemsg']['flashtags'] = array(
'#type' => 'fieldset',
'#access' => user_access('create flashtags'),
'#title' => t('Flash Tags'),
'#collapsible' => FALSE,
'#collapsed' => empty($form['#privatemsg_message']['flashtags']),
'#description' => t('Flashtags are used to add a context to a message and only viewable by the sender.'),
'#prefix' => '<div class="flashtags">',
'#value' => print $swf_tags,
'#suffix' => '</div>',
'#weight' => 1,
);
}
}
Obviously I'm missing something in understanding how to make that work. It's creating a field set on the form but no Flash object. Value is unlikely to be the right name. I'm not sure what this should be.
Anyone got some clues for me on this?
Yani
I know how you set it up WITHOUT SWFtools / SWFObject2, but that might not be the answer you are looking for:
Views->theme field [op populate value from variables]:
<script type="text/javascript">swfobject.embedSWF("<?php print trim($output;) ?>", "replaceSWF", "720", "640", "10.0.0"); </script> <div id="replaceSWF" class="swftools swfobject2"> </div>
this assumes you are loading swfobject.js, size would obviously need to be configured/altered; and the content of the div you want to show if the swf is not loaded [and before load is done]
Seb.
Yani wrote:
Hi,
I’m trying to add a Flash object to an existing module.
I’ve tried a couple of ways without success.
I’ve created a module.
I have SWFTool with SWFObject2 enabled
Using JS as per this
$(document).ready(*function*(){
*var* flashtags = $('<div>[swf file="http://XXX/sites/all/modules/flashtags/flash/flashtags.swf"]</div>').appendTo('#privatemsg-new').get(0);
*if* (Drupal.jsEnabled) {
Drupal.attachBehaviors(flashtags);}
});
By doing that I end up with this printed at the bottom of the form
[swf file="http://XXX/sites/all/modules/flashtags/flash/flashtags.swf"]
But no Flash object.
I tried this approach…
function privatemsg_form_alter(&$form, $form_state, $form_id) {
$vars['swf_tags'] = swf("http://XXX/sites/all/modules/flashtags/flash/flashtags.swf",
array('width' => '420', 'height' => '140', 'bgcolor' => '#336699'), FALSE,
array('html_alt' => 'Name of site if flash is disabled.')
);
if ($form_id == 'privatemsg_new' && user_access('create flashtags')) {
$form['privatemsg']['flashtags'] = array( '#type' => 'fieldset', '#access' => user_access('create flashtags'), '#title' => t('Flash Tags'), '#collapsible' => FALSE, '#collapsed' => empty($form['#privatemsg_message']['flashtags']), '#description' => t('Flashtags are used to add a context to amessage and only viewable by the sender.'),
'#prefix' => '<div class="flashtags">', *'#value' => print $swf_tags,*** '#suffix' => '</div>', '#weight' => 1, );}
}
Obviously I’m missing something in understanding how to make that work. It’s creating a field set on the form but no Flash object. Value is unlikely to be the right name. I’m not sure what this should be.
Anyone got some clues for me on this?
Yani
sorry typo:
<script type="text/javascript">swfobject.embedSWF("<?php print trim($output); ?>", "replaceSWF", "720", "640", "10.0.0"); </script> <div id="replaceSWF" class="swftools swfobject2"> </div>
sebastian wrote:
I know how you set it up WITHOUT SWFtools / SWFObject2, but that might not be the answer you are looking for:
Views->theme field [op populate value from variables]:
<script type="text/javascript">swfobject.embedSWF("<?php print trim($output;) ?>", "replaceSWF", "720", "640", "10.0.0"); </script>
<div id="replaceSWF" class="swftools swfobject2"> </div>
this assumes you are loading swfobject.js, size would obviously need to be configured/altered; and the content of the div you want to show if the swf is not loaded [and before load is done]
Seb.
Yani wrote:
Hi,
I’m trying to add a Flash object to an existing module.
I’ve tried a couple of ways without success.
I’ve created a module.
I have SWFTool with SWFObject2 enabled
Using JS as per this
$(document).ready(*function*(){
*var* flashtags = $('<div>[swf file="http://XXX/sites/all/modules/flashtags/flash/flashtags.swf"]</div>').appendTo('#privatemsg-new').get(0);
*if* (Drupal.jsEnabled) {
Drupal.attachBehaviors(flashtags);}
});
By doing that I end up with this printed at the bottom of the form
[swf file="http://XXX/sites/all/modules/flashtags/flash/flashtags.swf"]
But no Flash object.
I tried this approach…
function privatemsg_form_alter(&$form, $form_state, $form_id) {
$vars['swf_tags'] = swf("http://XXX/sites/all/modules/flashtags/flash/flashtags.swf",
array('width' => '420', 'height' => '140', 'bgcolor' => '#336699'), FALSE,
array('html_alt' => 'Name of site if flash is disabled.')
);
if ($form_id == 'privatemsg_new' && user_access('create flashtags')) {
$form['privatemsg']['flashtags'] = array( '#type' => 'fieldset', '#access' => user_access('create flashtags'), '#title' => t('Flash Tags'), '#collapsible' => FALSE, '#collapsed' => empty($form['#privatemsg_message']['flashtags']), '#description' => t('Flashtags are used to add a context to amessage and only viewable by the sender.'),
'#prefix' => '<div class="flashtags">', *'#value' => print $swf_tags,*** '#suffix' => '</div>', '#weight' => 1, );}
}
Obviously I’m missing something in understanding how to make that work. It’s creating a field set on the form but no Flash object. Value is unlikely to be the right name. I’m not sure what this should be.
Anyone got some clues for me on this?
Yani