Question for programmers

Get help using Construct 2

Post » Mon Feb 27, 2017 8:40 am

Im wondering ho can i add code in to Ebay, Allegro to display game window in item description?

i try use iframe but iframe is blocked
so i read about this i try make on my own
but im not programmer so i need tips where i should fix code

Code: Select all
<SCRIPT LANGUAGE="JavaScript">
<!--
document.write('<' + 'I' + 'FR' + 'AM' + 'E ' + 'SRC' + '="' + 'https://igamedeveloper.github.io/allegro/" style="border:0px #FFFFFF none;" name="a" scrolling="no" frameborder="1" marginheight="0px" marginwidth="0px" height="60px" width="468px"' +'<' + '/' + 'i' +'fr'+ 'am'+ 'e'>')
//-->
</SCRIPT>
B
113
S
29
G
48
Posts: 1,882
Reputation: 36,578

Post » Mon Feb 27, 2017 4:25 pm

It's blocked because of browser security measures. You need to change the X-Frame-Options HTTP header in order for it to work properly.

Just understand that you are playing with security fire.
https://www.ravenheart.ca/home
I don't check the forums much anymore, but I will receive an email for PMs.

"Someone once told me I bite off more than I can chew...

I told them I would rather choke on greatness than nibble on mediocrity."
B
23
S
6
G
1
Posts: 1,419
Reputation: 4,857

Post » Mon Feb 27, 2017 4:29 pm

gumshoe2029 wrote:It's blocked because of browser security measures. You need to change the X-Frame-Options HTTP header in order for it to work properly.

Just understand that you are playing with security fire.


He can't change the security headers in ebay, it's not his site.

Delgado, even if you sneak the HTML of an iframe onto a page, it won't work if Ebay doesn't allow iframes to be loaded on their page, as configured by ebay in their site's headers, like gumshoe mentioned. You need to use something else. Can you possibly use an image?
B
8
Posts: 8
Reputation: 332

Post » Mon Feb 27, 2017 4:41 pm

menasheh wrote:
gumshoe2029 wrote:It's blocked because of browser security measures. You need to change the X-Frame-Options HTTP header in order for it to work properly.

Just understand that you are playing with security fire.


He can't change the security headers in ebay, it's not his site.

Delgado, even if you sneak the HTML of an iframe onto a page, it won't work if Ebay doesn't allow iframes to be loaded on their page, as configured by ebay in their site's headers, like gumshoe mentioned. You need to use something else. Can you possibly use an image?


hi, i know how use image, prabably gifs too but i need insert window with c2 project
B
113
S
29
G
48
Posts: 1,882
Reputation: 36,578

Post » Mon Feb 27, 2017 4:51 pm

B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Mon Feb 27, 2017 11:56 pm

menasheh wrote:He can't change the security headers in ebay, it's not his site.

Sure you can. Use an Apache proxy. You can change the headers if you proxy the Ebay site through an Apache proxy. Although, if you use an Apache proxy, then the X-Frame-Options: SAME ORIGIN will work for you, and you won't have to change the X-Frame-Options header.
https://www.ravenheart.ca/home
I don't check the forums much anymore, but I will receive an email for PMs.

"Someone once told me I bite off more than I can chew...

I told them I would rather choke on greatness than nibble on mediocrity."
B
23
S
6
G
1
Posts: 1,419
Reputation: 4,857

Post » Thu Mar 02, 2017 8:52 am

gumshoe2029 wrote:
menasheh wrote:He can't change the security headers in ebay, it's not his site.

Sure you can. Use an Apache proxy. You can change the headers if you proxy the Ebay site through an Apache proxy. Although, if you use an Apache proxy, then the X-Frame-Options: SAME ORIGIN will work for you, and you won't have to change the X-Frame-Options header.


interesting, can you show example?
B
113
S
29
G
48
Posts: 1,882
Reputation: 36,578

Post » Fri Mar 03, 2017 12:50 am

gumshoe2029 wrote:
menasheh wrote:He can't change the security headers in ebay, it's not his site.

Sure you can. Use an Apache proxy. You can change the headers if you proxy the Ebay site through an Apache proxy. Although, if you use an Apache proxy, then the X-Frame-Options: SAME ORIGIN will work for you, and you won't have to change the X-Frame-Options header.


That doesn't seem like a large-scale solution. You could get it to "work," but what if other people view the site? You can't force everyone else to also use an apache proxy... I'm sure there's some detail I'm missing here, but if you can't get the standard ebay.com to do it, how does it help?
B
8
Posts: 8
Reputation: 332

Post » Fri Mar 03, 2017 2:16 am

dont use iframe... use <object> </object> or <embed></embed>

see blog post about this

however iframe will work on a personal website just fine. but is blocked by amazon or ebay... so you should look what they allow to embed on their websites.


try this code for iframe on personal website or even on ebay see if works.


Code: Select all
<iframe class="someclass" src="yourlinktofolderofgame can be /game" frameborder="0" allowtransparency="true" backgroundcolor="transparent" ;="" style="overflow:hidden;overflow-x:hidden;overflow-y:hidden;height:100%;width:100%;position:absolute;top:0px;left:0px;right:0px;bottom:0px; z-index:1; " height="100%" width="100%" allowfullscreen="true" msallowfullscreen="true" mozallowfullscreen="true" webkitallowfullscreen="true"></iframe>
B
78
S
23
G
69
Posts: 1,354
Reputation: 44,027

Post » Fri Mar 03, 2017 8:30 am

gamecorpstudio wrote:dont use iframe... use <object> </object> or <embed></embed>

see blog post about this

however iframe will work on a personal website just fine. but is blocked by amazon or ebay... so you should look what they allow to embed on their websites.


try this code for iframe on personal website or even on ebay see if works.


Code: Select all
<iframe class="someclass" src="yourlinktofolderofgame can be /game" frameborder="0" allowtransparency="true" backgroundcolor="transparent" ;="" style="overflow:hidden;overflow-x:hidden;overflow-y:hidden;height:100%;width:100%;position:absolute;top:0px;left:0px;right:0px;bottom:0px; z-index:1; " height="100%" width="100%" allowfullscreen="true" msallowfullscreen="true" mozallowfullscreen="true" webkitallowfullscreen="true"></iframe>



Interesting i must say, Your proposition dont work but i use code from blog
Code: Select all
<div"> 
  <object data="[insert resource]" type="[insert MIME type]" style="height: 840px; width: 650px;">
    <embed src="[insert resource]" type="[insert MIME type]">
  <p>It appears you don't have a the proper plugin to load this in your browser. You can <a href="[insert resource link]">click here to access the resource.</a></p>
  </object>
</div> 


and i modify to:
Code: Select all
<div"> 
  <object data="https://igamedeveloper.github.io/balon/" type="application/html" style="height: 840px; width: 650px;">
    <embed src="https://igamedeveloper.github.io/balon/" type="application/html">
  <p>It appears you don't have a the proper plugin to load this in your browser. You can <a href="[insert resource link]">click here to access the resource.</a></p>
  </object>
</div> 


finally in description i have that error
Image

PS

i dont know what i should type in "[insert MIME type]"
B
113
S
29
G
48
Posts: 1,882
Reputation: 36,578

Next

Return to How do I....?

Who is online

Users browsing this forum: newt, Yahoo [Bot] and 12 guests