News:

Support the VirtueMart project and become a member

Main Menu

Social Share inline with Ask about product!

Started by kelecz, June 14, 2014, 01:29:58 AM

Previous topic - Next topic

kelecz

Hello,

please help me about this. i want to put it in same line:


?>
<?php $modules =& JModuleHelper::getModules('social');
    foreach (
$modules as $module) {
echo "<div>";
echo JModuleHelper::renderModule($module);
echo "</div>";
?>

<?php
// Ask a question about this product
if (VmConfig::get('ask_question'0) == 1) {
    
?>

    <div class="ask-a-question">
        <a class="ask-a-question" href="<?php echo $this->askquestion_url ?>" rel="nofollow" style="display:inline"; ><?php echo JText::_('COM_VIRTUEMART_PRODUCT_ENQUIRY_LBL'?></a>
        <!--<a class="ask-a-question modal" rel="{handler: 'iframe', size: {x: 700, y: 550}}" href="<?php echo $this->askquestion_url ?>"><?php echo JText::_('COM_VIRTUEMART_PRODUCT_ENQUIRY_LBL'?></a>-->
        </div>
<?php }
?>





Thx in advance!

[attachment cleanup by admin]

GJC Web Design

standard html techniques

surround both elements in a div  - give it a width that fits both

float one left and the other right
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

kelecz

Quote from: GJC Web Design on June 14, 2014, 01:39:16 AM
standard html techniques

surround both elements in a div  - give it a width that fits both

float one left and the other right

Can you please show me how on that example. I really do not know.

Thank you.

GJC Web Design

come on - Google this and u will find it - this isn't really a html 101 forum!


<div class="holder">
  <div class="leftme">
    Share stuff
  </div>
  <div class="rightme">
    Ask stuff
  </div>

</div>


css

.holder{width:100%;}
.leftme{float:left;width:50%;}
.rightme{float:right;width:50%;}


GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation


kelecz

Default file:

?>
   <?php $modules =& JModuleHelper::getModules('social');
    foreach ($modules as $module) {
   echo "<div>";
   echo JModuleHelper::renderModule($module);
   echo "</div>";
} ?>   
   
   
   <?php
// Ask a question about this product
if (VmConfig::get('ask_question', 0) == 1) {
    ?>         
         <div class="ask-a-question">
              <a class="ask-a-question" href="<?php echo $this->askquestion_url ?>" rel="nofollow" style="display:inline"; ><?php echo JText::_('COM_VIRTUEMART_PRODUCT_ENQUIRY_LBL') ?></a>
              <!--<a class="ask-a-question modal" rel="{handler: 'iframe', size: {x: 700, y: 550}}" href="<?php echo $this->askquestion_url ?>"><?php echo JText::_('COM_VIRTUEMART_PRODUCT_ENQUIRY_LBL') ?></a>-->
              </div>
      <?php }
      ?>
   
   </div>
   </div>

CSS:

/*Social*/

.nsb_container {
  float: right;
margin-right: -30px !important;display:inline;
margin-top: 5px;clear:both;
  content:".";
  display:block;
  height:0;
  line-height:0;
}


I did it this way and works. Hope somebody can use it.





[attachment cleanup by admin]