Jump to content



Latest News: (loading..)

- - - - -

Adding Image Code in static page "shiping & return" etc


  • Please log in to reply
8 replies to this topic

#1   sepatufutsal

sepatufutsal

    dr.

  • Members
  • 5 posts
  • Real Name:sepatufutsal
  • Gender:Male
  • Location:Indonesia

Posted Yesterday, 02:15 PM

Hi I am curious about add image comand in shiping & returns or custome static page in my web

this is my code


<?php
/*
  $Id$

  osCommerce, Open Source E-Commerce Solutions
  http://www.oscommerce.com

  Copyright © 2002 osCommerce

  Released under the GNU General Public License
*/

define('NAVBAR_TITLE', 'Testimonial');
define('HEADING_TITLE', 'Testimonial');
define('TEXT_INFORMATION', '<UL type="disc"><center><B>CELOTEH CLIENT TENTANG PRODIRECTSOCCER INDONESIA</B></center>');
echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'up.jpg', 'osCommerce') . '</a>';
tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'class="single-product"')
?>

the result is in my attachment file.

all I want is the image show in the below of "CELOTEH CLIENT TENTANG PRODIRECTSOCCER INDONESIA"
so what is the corect code php one ?

thx for your attention  :)
----------------------------------------------------------------------------------------------------------------------------------------------------------------------
TOKO ONLINE SEPATU FUTSAL, SEPATU BOLA, BASELAYER, GLOVE, JERSEY, JAKET, ACCESORIES, ORIGINAL TERLENGKAP JUGA MENERIMA JASA ORDER PRODIRECTSOCCER, STARTFOOTBALL, EBAY, AMAZON DAN SELURUH OL STORE DI SELURUH DUNIA.

COME VISIT TO http://www.prodirectsoccerindonesia.com
FOR THE GREAT DISKON EVERYDAY !

Attached Files



#2 ONLINE   DunWeb

DunWeb

    The Censored One

  • Members
  • 12,720 posts
  • Real Name:Chris
  • Gender:Male
  • Location:Ontario, Canada

Posted Yesterday, 02:17 PM

@sepatufutsal

You are going to want to add the image to /testimonial.php file, not the language definition file.



Chris

Edited by DunWeb, Yesterday, 02:18 PM.

:|: Was this post helpful ? Click the LIKE THIS button :|:

See my Profile (click here)

#3 ONLINE   multimixer

multimixer

    Lemons or Melons ?

  • Partner
  • 4,387 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted Yesterday, 02:30 PM

You need to add the image within TEXT_INFORMATION

Now you have (leaning out the product image that is wrong)
define('TEXT_INFORMATION', '<UL type="disc"><center><B>CELOTEH CLIENT TENTANG PRODIRECTSOCCER INDONESIA</B></center>');
echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'up.jpg', 'osCommerce') . '</a>';

Should be
define('TEXT_INFORMATION', '
<UL type="disc"><center><B>CELOTEH CLIENT TENTANG PRODIRECTSOCCER INDONESIA</B></center>
<br />
<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'up.jpg', 'osCommerce') . '</a>
');

Not sure what this strange markup is, why not use proper html tags and style in css, eg a <h2>...</h2>

Edited by multimixer, Yesterday, 02:30 PM.


#4   sepatufutsal

sepatufutsal

    dr.

  • Members
  • 5 posts
  • Real Name:sepatufutsal
  • Gender:Male
  • Location:Indonesia

Posted Yesterday, 02:37 PM

great, thx for your advice, I have made it
but because of I got this code copy paste from google,
I have problem to change the paramater for the code
1. My image is in folder \images\testimonial,
2. I want to change the image widht and height in precent scale

so what is the correct code for php newby like me

this is my google code >>>


echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'up.jpg', 'osCommerce') . '</a>';
tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT, 'class="single-product"')


thx

#5   sepatufutsal

sepatufutsal

    dr.

  • Members
  • 5 posts
  • Real Name:sepatufutsal
  • Gender:Male
  • Location:Indonesia

Posted Today, 07:19 AM

great, thx for your advice, I have made it
but because of I got this code copy paste from google,
I have problem to change the paramater for the code
1. My image is in folder \images\testimonial,
2. I want to change the image widht and height in precent scale

so what is the correct code for php newby like me

#6 ONLINE   multimixer

multimixer

    Lemons or Melons ?

  • Partner
  • 4,387 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted Today, 07:26 AM

tep_image(DIR_WS_IMAGES . 'sub_folder/subsub_folder/' . 'image_name.jpg', 'image_title', 50, 50);

The numbers 50, 50 are width and height

#7   sepatufutsal

sepatufutsal

    dr.

  • Members
  • 5 posts
  • Real Name:sepatufutsal
  • Gender:Male
  • Location:Indonesia

Posted Today, 07:57 AM

ok, I have done to change the scale


<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'up.jpg', 'osCommerce', '50%', '50%') . '</a>

but the problem is how to change directory of the image..
if my folder images is images/testimonial

i have change it DIR_WS_IMAGES_TESTIMONIAL,
but the image is still now show

need advise please

#8 ONLINE   multimixer

multimixer

    Lemons or Melons ?

  • Partner
  • 4,387 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted Today, 08:04 AM

@sepatufutsal

Check again by previous post and you'll see how to add the path to your subfolder. Also it's not 50% but 50 in pixels

Edit: Please remove the spam from your footer, check here

Edited by multimixer, Today, 08:06 AM.


#9   sepatufutsal

sepatufutsal

    dr.

  • Members
  • 5 posts
  • Real Name:sepatufutsal
  • Gender:Male
  • Location:Indonesia

Posted Today, 02:20 PM

@multimixer

thx very much.

I have make it..
with ur sugestion to change the directory :


tep_image(DIR_WS_IMAGES . 'sub_folder/subsub_folder/' . 'image_name.jpg', 'image_title', 50, 50);

so i make it to >>

<a href="' . tep_href_link('images/testimonial/testimonial1.jpg') . '">' . tep_image(DIR_WS_IMAGES . 'testimonial/testimonial1.jpg', 'testimonial1', '50%', '50%') . '</a>

and I add new href link, so my photo will be open in new link

once again thx to @DunWeb, and @multimixer