Jump to content
Latest News: (loading..)

Jonojamesmac

Members
  • Content count

    145
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by Jonojamesmac


  1. You just need a space between php and echo like

    this

    <?phpecho tep_draw_separator('pixel_trans.gif', '24', '15') . ' '?>

    to this

    <?php echo tep_draw_separator('pixel_trans.gif', '24', '15') . ' '; ?>


  2. Please tell me if i'm not helping, i'm wanting to use this contribution and obviously i want to help towards making this perfect.

     

    I've tested this out on a varchar field in database containing the values below.

     

    $var = 'fgrgwwf' returns 3 (string)

    $var = '443810371015' returns 1 (float)

    $var = '8024' returns 2 (int)

     

    	function convert_type( $var )
    {
    if( is_numeric( $var ) )
    {
    	if( (float)$var != (int)$var )
    	{ // Float
    		return '1';
    	}
    	else
    	{
    		// Is Int
    		return '2';
    	}
    }
      if (($var != '1') && ($var != '2')) {
       // Is String
       return '3';
    
      }
    }


  3. You may have missed this step.

     

    open admin/includes/functions/html_output.php

     

    add before the final ?>

     

    ////
    // Creates a pull-down list for dates	
    function tep_pull_down_date($name='date', $day='', $month='', $year='', $full=false, $mnth=false, $starty=''){
    if ($day=='') {$day=date('d');}
    if ($month=='') {$month=date('m');}
    if ($year=='') {$year=date('Y');}
    $endy=date('Y')-8;
    if ($starty=='') {$starty=date('Y')-1;$endy=date('Y')+2;} 
    $named = $name . 'd';
    $namem = $name . 'm';
    // Array for days
    $days=array();
    $days[] = array('id' => '00', 'text' => 'not');
    for($i=1; $i<=31; $i++){
    if(strlen($i)!= 2){
    $j = '0' . $i;
    } else {
    $j = $i;
    } 
    $days[] = array('id' => $j, 'text' => $j); }
    
    if ($mnth) {
    $months = array(
    array('id' => '00', 'text' => 'month'),
    array('id' => '01', 'text' => TEXT_DATE_JAN),
    array('id' => '02', 'text' => TEXT_DATE_FEB),
    array('id' => '03', 'text' => TEXT_DATE_MAR),
    array('id' => '04', 'text' => TEXT_DATE_APR),
    array('id' => '05', 'text' => TEXT_DATE_MAY),
    array('id' => '06', 'text' => TEXT_DATE_JUN),
    array('id' => '07', 'text' => TEXT_DATE_JUL),
    array('id' => '08', 'text' => TEXT_DATE_AUG),
    array('id' => '09', 'text' => TEXT_DATE_SEP),
    array('id' => '10', 'text' => TEXT_DATE_OCT),
    array('id' => '11', 'text' => TEXT_DATE_NOV),
    array('id' => '12', 'text' => TEXT_DATE_DEC));
    } else {
    $months[] = array('id' => '00', 'text' => 'set');
    for($i=1; $i<=12; $i++){
    if(strlen($i)!= 2){
    $j = '0' . $i;
    } else {
    $j = $i;
    } 
    $months[] = array('id' => $j, 'text' => $j); }}
    
    for($i=$starty; $i<=$endy; $i++){
    $j = $i;
    if ($full) {
    $y = $i - 2000;
    if(strlen($y)!= 2){
    $j = '0' . $y;
    } else {
    $j = $y;
    } }
    $years[] = array('id' => $i, 'text' => $j); }
    $field='';
    // mm dd yy contries = 38 canada,139 Micronesia,163 Palau,168 Philippines,223 & 224 United States
    if(STORE_COUNTRY == 223 || STORE_COUNTRY == 224 || STORE_COUNTRY == 38 || STORE_COUNTRY == 139 || STORE_COUNTRY == 163 || STORE_COUNTRY == 168) {
    $field .= tep_draw_pull_down_menu($named, $months, $month);
    $field .= tep_draw_pull_down_menu($namem, $days, $day); }
    else {
    $field .= tep_draw_pull_down_menu($named, $days, $day);
    $field .= tep_draw_pull_down_menu($namem, $months, $month); }
    $field .= tep_draw_pull_down_menu($name, $years, $year);
    
    return $field;
    }


  4. Yipes, I don't think I'm getting this right. Unless it takes Google hours to upload the catalog ... ??

     

    Maybe you can take one more peek and tell me if you see a problem? Here's exactly what is now in my .htaccess file:

     

    # $Id: .htaccess 1739 2007-12-20 00:52:16Z hpdl $
    #
    # This is used with Apache WebServers
    #
    # For this to work, you must include the parameter 'Options' to
    # the AllowOverride configuration
    #
    # Example:
    #
    # <Directory "/usr/local/apache/htdocs">
    #   AllowOverride Options
    # </Directory>
    #
    # 'All' with also work. (This configuration is in the
    # apache/conf/httpd.conf file)
    # The following makes adjustments to the SSL protocol for Internet
    # Explorer browsers
    #<IfModule mod_setenvif.c>
    #  <IfDefine SSL>
    #	SetEnvIf User-Agent ".*MSIE.*" \
    #			 nokeepalive ssl-unclean-shutdown \
    #			 downgrade-1.0 force-response-1.0
    #  </IfDefine>
    #</IfModule>
    # If Search Engine Friendly URLs do not work, try enabling the
    # following Apache configuration parameter
    # AcceptPathInfo On
    # Fix certain PHP values
    # (commented out by default to prevent errors occuring on certain
    # servers)
    # php_value session.use_trans_sid 0
    # php_value register_globals 1
    RewriteBase /
    RewriteRule feed.txt googlebase.php

     

    Thanks again, really. I am quite inept at all of this. :-P

     

    Browse to http://www.yoursite.com/feed.txt what do you see? If you see a lines of text, it works.

     

    Just point google base to that link and google will pick it up.


  5. Step 2

     

    Upload googlebase.php to your site root, this is where files such as index.php and product_info.php are.

     

    Step 3

     

    Edit .htaccess file in your root directory (the file may look like it has no name and the extension type will be HTACCESS ) with notepad or other editor and copy/paste the following after RewriteBase /

    #############################
    # Begin Google Base File Rewrite Code
    RewriteRule your-outfile.txt googlebase.php
    # End Google Base File Rewrite Code
    #############################

     

    When you configure Google Base data feed to read information from your store, you set it to look for a certain text file.

     

    So if you call that text file feed.txt then you would replace your-outfile.txt in the above code with feed.txt and then make sure in Google Base it is linked to http://www.yoursite.com/feed.txt

     

    Hope this helps..


  6. I am using the Stirling Product Tabs contribution and have managed to customize it so that I can also have reviews pulled up in it.

     

    My problem though is that I can't seem to get rid of the blue background in the iframe:

     

    See here...

     

    any suggestions? I've tried adding a background of white or #ffffff to almost everything but it's still not ficing the blue

     

    Thanks.

     

    It is most likely set in your css file


  7. As the title says, does this contribution already exist and i just can't find it or how easy could it be to make?

     

    For example, i have 2 products, 1 is blue, 1 is red and they are called Product Blue and Product Red, i search for Product and both of the products appear.

     

    I want to be able to refine the search result for the color red, so Product Red is only displayed.

     

    I would also want it appear when browsing through categories to help find what im looking for also, not just using the search function.

     

    Anyone? :)

×