Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Pop Image Not Showing


ajayzone

Recommended Posts

I have no idea what is going wrong. actually i have already used oscommerce on one site and am now using it on another, its so simple i don`t know php , but i know one thing the code on both my site is same but it is same, but for some reason it is working at one place and not working at the other.

what could be the problem. i have included my popup_image.php file, i`m using STS. i have uninstalled sts for popup image but still the image wont pop.

 

you can see it here

 

http://www.fingerprintindia.com/product_in...;products_id=29

 

this is my code. please help i have no idea where i am going wrong.

 

 
<?php

require('includes/application_top.php');

 $navigation->remove_current_page();

 $products_query = tep_db_query("select pd.products_name, p.products_image from " . TABLE_PRODUCTS . " p left join " . TABLE_PRODUCTS_DESCRIPTION . " pd on p.products_id = pd.products_id where p.products_status = '1' and p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "' and pd.language_id = '" . (int)$languages_id . "'");
 $products = tep_db_fetch_array($products_query);
?>
<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
<html <?php echo HTML_PARAMS; ?>>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">
<title><?php echo $products['products_name']; ?></title>
<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>">
<script language="javascript"><!--
var i=0;
function resize() {
 if (navigator.appName == 'Netscape') i=40;
 if (document.images[0]) window.resizeTo(document.images[0].width +30, document.images[0].height+60-i);
 self.focus();
}
//--></script>
</head>
<body onload="resize();">
<?php echo tep_image(DIR_WS_IMAGES . $products['products_image'], $products['products_name']); ?>
</body>
</html>
<?php require('includes/application_bottom.php'); ?>

Link to comment
Share on other sites

Check this line

 

<script language="javascript"><!--

 

should be

 

<script language="javascript"><!--

 

or

 

<script type="text/javascript"><!--

Link to comment
Share on other sites

Check this line

 

<script language="javascript"><!--

 

should be

 

<script language="javascript"><!--

 

or

 

<script type="text/javascript"><!--

 

 

i have no idea as to how this became <script language="javascript"><!--

 

its the problem with the quote tag i think or the text pad it also changed your input see.

but in my code it is like <script language="javascript"><!-- and not <script language="javascript"><!--

 

i am now facing the same problem with both my site the one which was working fine till 3 days back and the one thats not working from the start.

 

could you help please. its as if the pop up just decided it dose not want to pop.

 

you can check it out herehttp://www.safepune.com/product_info.php?c...;products_id=44

 

i migrated the same thing when it was working on another site and the same code is working on that site i am just in a spin

http://www.insigniasecure.com/product_info...?products_id=44

 

please help thanks.

ajay

Link to comment
Share on other sites

The function popupWindow is missing in your header...

 

 

<script language="javascript"><!--

var i=0;
function popupWindow(url) {
window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,
scrollbars=no,resizable=yes,copyhistory=no,width=400,height=400,screenX=150,scre
enY=150,top=150,left=150')
}

function resize() {
 if (navigator.appName == 'Netscape') i=40;
 if (document.images[0]) window.resizeTo(document.images[0].width +30, document.images[0].height+60-i);
 self.focus();
}

//--></script>

 

 

did this but is not working actually as i said the same code is working on my other site i have mentioned above

it is the same code in both the cases.

Link to comment
Share on other sites

Following code exists in the header from insigniasecure.com (check the source code):

<!-- start get_javascript(applicationtop2header) //-->
<script language="javascript"><!--
function popupWindow(url) {
 window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,res
izable=yes,copyhistory=no,width=100,height=100,screenX=150,screenY=150,top=150,le
ft=150')
}
//--></script>

 

This code is missing in safepune.com (check the source code)

 

If you are using a template file, make sure the javascript function is available in that file.

Link to comment
Share on other sites

Following code exists in the header from insigniasecure.com (check the source code):

<!-- start get_javascript(applicationtop2header) //-->
<script language="javascript"><!--
function popupWindow(url) {
 window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,res
izable=yes,copyhistory=no,width=100,height=100,screenX=150,screenY=150,top=150,le
ft=150')
}
//--></script>

 

This code is missing in safepune.com (check the source code)

 

If you are using a template file, make sure the javascript function is available in that file.

 

i am not understanding heard of which file ?

if you mean the popup_image.php the code is not in either of them.

 

i`m using sts for both of them.

 

thanks.

Link to comment
Share on other sites

I have no idea what is going wrong. actually i have already used oscommerce on one site and am now using it on another, its so simple i don`t know php , but i know one thing the code on both my site is same but it is same, but for some reason it is working at one place and not working at the other.

what could be the problem. i have included my popup_image.php file, i`m using STS. i have uninstalled sts for popup image but still the image wont pop.

 

you can see it here

 

http://www.fingerprintindia.com/product_in...;products_id=29

 

this is my code. please help i have no idea where i am going wrong.

 

:thumbsup: In the STS User Manual, a support link is listed for the official osC thread (I have it listed in my signature below as well). Please use this link for all support requests in the future so as to benefit all STS users and to receive quicker responses.

 

Here is a possible solution to your problem:

 

You did not set your template up correctly.

 

The

<!--$headcontent-->

tag is missing. This tag is needed in order to "pull" in the required JavaScript and other osC functional content.

 

Hope this helped,

Bill Kellum

 

Sounds Good Productions

STS Tutorials & more: STSv4.6, STS Add-ons (STS Power Pack), STS V4 Forum STS Forum FREE TEMPLATE

Link to comment
Share on other sites

:thumbsup: In the STS User Manual, a support link is listed for the official osC thread (I have it listed in my signature below as well). Please use this link for all support requests in the future so as to benefit all STS users and to receive quicker responses.

 

Here is a possible solution to your problem:

 

You did not set your template up correctly.

 

The

<!--$headcontent-->

tag is missing. This tag is needed in order to "pull" in the required JavaScript and other osC functional content.

 

Hope this helped,

 

Thanks man i did not think it was the sts problem but i removed the <!--$headcontent--> tag as i put in meta tags and page title by hand. but the <!--$headcontent--> tag creates its own meta and title tag how can i change that. i will post this on sts forum also.

 

Thanks again

ajay

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...