Page 3 of 4 FirstFirst 1234 LastLast
Results 21 to 30 of 38
  1. #21
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Facebook/Twitter Module

    Get rid of the <tr> <td> <center> stuff - you don't need it, and it is currently invalid HTML due to missing elements.

    You pulled the <div but then put in an extra </div>, so it is now unbalanced in the other direction.
    PHP Code:
    <?php
    /**
     * blank sidebox - allows a blank sidebox to be added to your site
     *
     * @package templateSystem
     * @copyright 2007 Kuroi Web Design
     * @copyright Portions Copyright 2003-2007 Zen Cart Development Team
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: blank_sidebox.php 2007-05-26 kuroi $
     */

      // test if box should display
      
    $show_social true;

      if (
    $show_social == true) {
         
    $title =  BOX_HEADING_SOCIAL;
         
    $title_link false;
         require(
    $template->get_template_dir($column_box_defaultDIR_WS_TEMPLATE$current_page_base,'common') . '/' $column_box_default);
      }
     
    ?>
      <div id="Facebook">
        <a href="http://www.facebook.com/pages/The-Esoteric-Emporium/145421388812693?sk=wall"><img src="images/fb.png" width="50" height="50" alt="Facebook" /></a>&nbsp;&nbsp;<a href="http://twitter.com/YOUR-TWITTER-HERE"><img src="images/tw.png" width="50" height="50" /></a>
      </div>

  2. #22
    Join Date
    May 2006
    Location
    Queensland, Australia
    Posts
    248
    Plugin Contributions
    0

    Default Re: Facebook/Twitter Module

    Quote Originally Posted by gjh42 View Post
    Get rid of the <tr> <td> <center> stuff - you don't need it, and it is currently invalid HTML due to missing elements.

    You pulled the <div but then put in an extra </div>, so it is now unbalanced in the other direction.
    PHP Code:
    <?php
    /**
     * blank sidebox - allows a blank sidebox to be added to your site
     *
     * @package templateSystem
     * @copyright 2007 Kuroi Web Design
     * @copyright Portions Copyright 2003-2007 Zen Cart Development Team
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: blank_sidebox.php 2007-05-26 kuroi $
     */

      // test if box should display
      
    $show_social true;

      if (
    $show_social == true) {
         
    $title =  BOX_HEADING_SOCIAL;
         
    $title_link false;
         require(
    $template->get_template_dir($column_box_defaultDIR_WS_TEMPLATE$current_page_base,'common') . '/' $column_box_default);
      }
     
    ?>
      <div id="Facebook">
        <a href="http://www.facebook.com/pages/The-Esoteric-Emporium/145421388812693?sk=wall"><img src="images/fb.png" width="50" height="50" alt="Facebook" /></a>&nbsp;&nbsp;<a href="http://twitter.com/YOUR-TWITTER-HERE"><img src="images/tw.png" width="50" height="50" /></a>
      </div>
    The Problem is now i still dont have a heading and now the icons are up the top instead of taking notice of the sort order and are off center.

  3. #23
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Facebook/Twitter Module

    So add rules to your stylesheet, like

    #Facebook {text-align: center; margin-top: 1.5em;}
    #Facebook a img {margin: 0.5em;}

    The heading I'm not sure about. Can you let us see your site?

  4. #24
    Join Date
    May 2006
    Location
    Queensland, Australia
    Posts
    248
    Plugin Contributions
    0

    Default Re: Facebook/Twitter Module


  5. #25
    Join Date
    May 2006
    Location
    Queensland, Australia
    Posts
    248
    Plugin Contributions
    0

    Default Re: Facebook/Twitter Module

    Quote Originally Posted by gjh42 View Post
    So add rules to your stylesheet, like

    #Facebook {text-align: center; margin-top: 1.5em;}
    #Facebook a img {margin: 0.5em;}

    The heading I'm not sure about. Can you let us see your site?
    That fixes the alignment but still dosnt solve the problem of it ignoring the sort Order and the heading.

  6. #26
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Facebook/Twitter Module

    By "ignoring the sort Order", do you mean that it isn't set to be at the top of the column? The social container is not inside the regular structure of the sidebar as it should be, but loose in the sidebar container, at the same depth as the regular structure itself. The template is such a strange and antiquated mess of nested tables that I don't know if a properly constructed modern sidebox can work in it. I'm also not sure you have a properly constructed sidebox; what do you have for /includes/templates/your_template/sideboxes/tpl_social.php? Do you have any other sidebox mods installed? What version of Zen Cart are you running?

  7. #27
    Join Date
    May 2006
    Location
    Queensland, Australia
    Posts
    248
    Plugin Contributions
    0

    Default Re: Facebook/Twitter Module

    Quote Originally Posted by gjh42 View Post
    By "ignoring the sort Order", do you mean that it isn't set to be at the top of the column? The social container is not inside the regular structure of the sidebar as it should be, but loose in the sidebar container, at the same depth as the regular structure itself. The template is such a strange and antiquated mess of nested tables that I don't know if a properly constructed modern sidebox can work in it. I'm also not sure you have a properly constructed sidebox; what do you have for /includes/templates/your_template/sideboxes/tpl_social.php? Do you have any other sidebox mods installed? What version of Zen Cart are you running?
    Yea, it is suppose to be down near the information side box instead of being up the top..

    However when i use my coding;

    Code:
    <?php
    /**
     * blank sidebox - allows a blank sidebox to be added to your site
     *
     * @package templateSystem
     * @copyright 2007 Kuroi Web Design
      * @copyright Portions Copyright 2003-2007 Zen Cart Development Team
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: blank_sidebox.php 2007-05-26 kuroi $
     */
    
      // test if box should display
      $show_social = true;
    
      if ($show_social == true) {
          $title =  BOX_HEADING_SOCIAL;
          $title_link = false;
          require($template->get_template_dir($column_box_default, DIR_WS_TEMPLATE, $current_page_base,'common') . '/' . $column_box_default);
     }
     ?>
     	<tr>
      	<td>
    		<div id="Facebook">
    		<a href="http://www.facebook.com/pages/The-Esoteric-Emporium/145421388812693?sk=wall"><img src="images/fb.png" width="50" height="50" alt="Facebook" /></a>&nbsp;&nbsp;<a href="http://twitter.com/YOUR-TWITTER-HERE"><img src="images/tw.png" width="50" height="50" /></a></div>
    		</div>
        </td>
      </tr>
    It is in the right place...

    As for /includes/templates/your_template/sideboxes/tpl_social.php?, nope dont have the file, dont need it.

  8. #28
    Join Date
    May 2006
    Location
    Queensland, Australia
    Posts
    248
    Plugin Contributions
    0

    Default Re: Facebook/Twitter Module

    I was just looking at the site again and notice that it is importing the information from "Information" into the box for Social Networking..

    WTF ?

  9. #29
    Join Date
    May 2006
    Location
    Queensland, Australia
    Posts
    248
    Plugin Contributions
    0

    Default Re: Facebook/Twitter Module

    Okay, i just noticed that my coding seems to cause a bug where it copies the information from "Information" and puts it into the box listed Social....



    So reverting back to blank sidebox;

    tpl_social.php

    Code:
    <?php
    /**
     * Product Type - allows you to show a sidebox that will list Product Types.
     *
     * @package templateSystem
     * @copyright 2007 Kuroi Web Design
      * @copyright Portions Copyright 2003-2007 Zen Cart Development Team
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: product_type.php 2007-05-26 kuroi $
     */
    
      $content = '';
      $content .= '<div id="' . str_replace('_', '-', $box_id . 'Content') . '" class="sideBoxContent">';
    
      // Replace the text and HTML tags between the apostophes on lines 19 and 20.
      // Use as many or as few lines using this model as you need for your custom content.
      // If you have a multilingual site define your text in the languages/YOUR_LANGUAGE/extra_definitions/blank_sidebox_defines.php and include it as shown in line 19.
      // If your site is monolingual, you can put the text right here as shown on line 20 (and nobody will know!)
      $content .= '<p>' . TEXT_BLANK_SIDEBOX . '</p>';
      $content .= '<p>You can include text, links, images, HTML markup and even PHP code</p>';
    
      $content .= '</div>';
    ?>
    and

    social.php

    Code:
    <?php
    /**
     * blank sidebox - allows a blank sidebox to be added to your site
     *
     * @package templateSystem
     * @copyright 2007 Kuroi Web Design
      * @copyright Portions Copyright 2003-2007 Zen Cart Development Team
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: blank_sidebox.php 2007-05-26 kuroi $
     */
    
      // test if box should display
      $show_social = true;
    
      if ($show_social == true) {
          require($template->get_template_dir('tpl_social.php',DIR_WS_TEMPLATE, $current_page_base,'sideboxes'). '/tpl_social.php');
    	  $title =  BOX_HEADING_SOCIAL;
          $title_link = false;
          require($template->get_template_dir($column_box_default, DIR_WS_TEMPLATE, $current_page_base,'common') . '/' . $column_box_default);
     }
     ?>

  10. #30
    Join Date
    May 2006
    Location
    Queensland, Australia
    Posts
    248
    Plugin Contributions
    0

    Default Re: Facebook/Twitter Module

    Now i just need to change tpl_social.php to show the images... right ?

 

 
Page 3 of 4 FirstFirst 1234 LastLast

Similar Threads

  1. v151 Facebook, Twitter, Youtube
    By missnura_com in forum General Questions
    Replies: 1
    Last Post: 14 Jan 2013, 06:56 AM
  2. v150 Facebook google plus twitter
    By oitem in forum General Questions
    Replies: 0
    Last Post: 4 Jun 2012, 06:56 PM
  3. facebook and twitter buttons
    By alfonso99 in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 19 Jul 2011, 02:23 PM
  4. facebook and twitter
    By deemurphy in forum General Questions
    Replies: 2
    Last Post: 9 Apr 2010, 09:20 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg