mariomoura Posted April 7, 2004 Posted April 7, 2004 Dear Oscommerce Forum I am trying implement in /catalog/includes/languages/english/product_info.php a custom pop up window. Unless use define('TEXT_MORE_INFORMATION', 'For more information, please visit this products <a href="%s" target="_blank"><u>webpage</u></a>.'); I would like to implement an pop up window like "For more information, please visit our multiview window" or "visit our advertisement" from example. I search and find html solution but don't work in OScommerce: <a href="#" onClick="InfoWindow=window.open('definition.htm','InfoWindow','toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, width=540, height=500, left=10, top=10'); return false;">definedword</a> Where. 1) Replace "definedword" with your word or phrase or acronym or.... that you want to use as the link to the window. 2) Replace "definition.htm" with the name of your definition or info page. (i.e. The page you want to open in your pop-up window.) Try to keep the pop-up page in the same folder as the page with your link to it or you will have to include the full path to wherever else this file is located. I try merge this solution in "define('TEXT_MORE_INFORMATION', 'For..." but still don't work. Someone can help me? I think will be useful this solution. Regards Mario
Virtual1 Posted April 7, 2004 Posted April 7, 2004 html does work. I do it in my site. make sure the appropriate javascript is also included.
mariomoura Posted April 7, 2004 Author Posted April 7, 2004 Yes, work well in html. I test in frontpage and after I test in my web. It's everything Ok! But when I try merge in oscommerce don't work. I try a lot of things like replace definition.htm with %s ... Try by yourself. What do I need to do? Please help me!!
mariomoura Posted April 7, 2004 Author Posted April 7, 2004 I am studing how can I include javascript in Oscommerce. I think will be necessary edit this file /catalog/includes/product_info.php and add the javascript, BUT HOW? Can you publish your solution? I and many users will appreciate a lot. Regards Mario
mariomoura Posted April 8, 2004 Author Posted April 8, 2004 Dear Ray, Thak you but don't work yet Because 1) your href="www. is a unique file 2) when I say define('TEXT_MORE_INFORMATION', 'For more information, please visit our <a href="%s" target="_blank"><u>multiview</u></a>.'); I want each product will have a URL in my database so I need use %s I try merge so I try use your idea in catalog/product_info.php I used: <script language="JavaScript"> <!-- window.open("%s","thisName", "directories=0,height=350,width=350,scrollbars=1"); //--> </script> and in /catalog/includes/languages/english/product_info.php I used define('TEXT_MORE_INFORMATION', 'For more information, please visit this products<a href="%s" onclick="window.open('%s' ,'SAY WHAT YOU WANT HERE','width=350,height=350,scrollbars'); return false;">SAY WHAT YOU WANT HERE</a>'); But I receive error I think the way will edit /catalog/includes/product_info.php and create something like "TEXT_CLICK_TO_ENLARGE" And the IDEA is have custom sizeable, of course. What do you think? Regards Mario
dburchm1 Posted April 8, 2004 Posted April 8, 2004 I include this in my product description when I enter it into the database and it uses the javascript on the product info page that is used for the "click to enlarge" images. I ajusted the size of the window to fit my features <a href="java script:popupWindow(\'http://mydomain/catalog/features.html\')"><font size=4 color=blue><p>Features</font></a>
Recommended Posts
Archived
This topic is now archived and is closed to further replies.