Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Outside coding rejected on my site why ?


rommany

Recommended Posts

Hello

 

Can someone please help im trying to add a survey on my site but the code is being rejected as im getting a error warning.

 

this is the code im trying to add

 

 

<a HREF="http://www.smart-survey.co.uk/view.asp?i=1056orhnu" onClick="window.open('http://smart-survey.co.uk/view.asp?i=1056orhnu', '','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable

=1,width=530,height=480');return false" >

 

Please click here to take our Online Survey

 

</a>

 

Any ideas ? :thumbsup:

Link to comment
Share on other sites

Hello

 

Can someone please help im trying to add a survey on my site but the code is being rejected as im getting a error warning.

 

this is the code im trying to add

<a HREF="http://www.smart-survey.co.uk/view.asp?i=1056orhnu" onClick="window.open('http://smart-survey.co.uk/view.asp?i=1056orhnu', '','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable

=1,width=530,height=480');return false" >

 

Please click here to take our Online Survey

 

</a>

 

Any ideas ? :thumbsup:

 

can you show us where you are trying to add it?

Regards

 

Mark A Reynolds

Link to comment
Share on other sites

Hi Mark

 

I tried too place it on the main index page just where i normally add text, should i be adding it to the index.php or the english/index.

 

Thanks

 

sry this is the error im getting

 

Parse error: syntax error, unexpected T_STRING in /home/jellybab/public_html/includes/languages/english/index.php

Link to comment
Share on other sites

define('TEXT_MAIN', 'blah blah blah<a HREF="http://www.smart-survey.co.uk/view.asp?i=1056orhnu" onClick="window.open('http://smart-survey.co.uk/view.asp?i=1056orhnu', '',& #39;toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable

=1,width=530,height=480');return false" >Please click here to take our Online Survey</a>more blah blah');

 

hope that helped ?

Link to comment
Share on other sites

define('TEXT_MAIN', 'blah blah blah<a HREF="http://www.smart-survey.co.uk/view.asp?i=1056orhnu" onClick="window.open('http://smart-survey.co.uk/view.asp?i=1056orhnu', '',& #39;toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable

=1,width=530,height=480');return false" >Please click here to take our Online Survey</a>more blah blah');

 

hope that helped ?

 

Try this

 

define('TEXT_MAIN', 'blah blah blah<a HREF="http://www.smart-survey.co.uk/view.asp?i=1056orhnu" target="_blank"');

 

Bit weary today but see if that works

Regards

 

Mark A Reynolds

Link to comment
Share on other sites

Sorry mark im a bit confussed, should i close it of with </a> and do i need to add the Please click here to take our Online Survey bit as well ?

 

thanks

 

Told you I was weary

 

define('TEXT_MAIN', 'blah blah blah<a HREF="http://www.smart-survey.co.uk/view.asp?i=1056orhnu" target="_blank">Take our survey</a>');

Regards

 

Mark A Reynolds

Link to comment
Share on other sites

Thanks Mark, it does work but i was hoping it would open in a popup box so they dont get taken away from my site?

 

Regards

 

bit difficult as the href is going to their site - Does it open in a new window?

Regards

 

Mark A Reynolds

Link to comment
Share on other sites

try this:

 

 

define('TEXT_MAIN','<a onClick="window.open('http://smart-survey.co.uk/view.asp?i=1056orhnu','popupWindow','toolbar=0,
location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=530,h
eight=480')">Please click here to take our Online Survey</a>');

 

or you may need to escape the single quote like this:

define('TEXT_MAIN','<a onClick="window.open(\'http://smart-survey.co.uk/view.asp?i=1056orhnu\',\'popupWindow\',\'toolbar=0,
location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=530,h
eight=480\')">Please click here to take our Online Survey</a>');

 

Copy and insert the code as one line (remove breaks)

Link to comment
Share on other sites

try this:

define('TEXT_MAIN','<a onClick="window.open('http://smart-survey.co.uk/view.asp?i=1056orhnu','popupWindow','toolbar=0,
location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=530,h
eight=480')">Please click here to take our Online Survey</a>');

 

or you may need to escape the single quote like this:

define('TEXT_MAIN','<a onClick="window.open(\'http://smart-survey.co.uk/view.asp?i=1056orhnu\',\'popupWindow\',\'toolbar=0,
location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1,width=530,h
eight=480\')">Please click here to take our Online Survey</a>');

 

Copy and insert the code as one line (remove breaks)

 

agreed - just kept it simple so as not to cause any more errors ;)

Regards

 

Mark A Reynolds

Link to comment
Share on other sites

are you sure asp is working on your system? try just an asp page by itself and see what happens. are you doing this for development purposes or are you going to 'host' the site there?

Link to comment
Share on other sites

sry to keep going on about this, ive put the blank back in and it opens in a new window but not sure for how long as when i first added the code that mark gave me it worked but after 5mins it didnt, did they change the code.

 

Im really confussed know.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...