Closed
Bug 1194482
Opened 9 years ago
Closed 9 years ago
Live sample "Open in Codepen/JSFiddle" buttons don't send code to service if code comes from another page
Categories
(developer.mozilla.org Graveyard :: General, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: sheppy, Unassigned)
Details
(Keywords: in-triage, Whiteboard: [specification][type:bug])
What did you do? ================ 1. Visit https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/Forms/How_to_build_custom_form_widgets#The_aria-selected_attribute 2. Click the "Open in Codepen" or "Open in JSFiddle" button on the sample at the end of this section of documentation. What happened? ============== A fiddle (or codepen) is opened, but the only content is a comment in the HTML edit box telling you what page on MDN the fiddle came from. What should have happened? ========================== The sample code should be displayed in the edit boxes as appropriate so the user can experiment. Is there anything else we should know? ======================================
Reporter | ||
Comment 1•9 years ago
|
||
This problem seems to occur if the sample is comprised of code broken into multiple pieces. For example, if there are four HTML <pre> blocks, two JavaScript blocks, and three CSS blocks. We do this often, so we can explain the code a bit at a time instead of having to refer back to pieces of one huge chunk of code.
Summary: Live sample "Open in Codepen/JSFiddle" buttons don't work on some pages → Live sample "Open in Codepen/JSFiddle" buttons don't send code to service if sample is in chunks
Reporter | ||
Comment 2•9 years ago
|
||
This should block calling the Codepen/JSFiddle feature finished.
Comment 3•9 years ago
|
||
I created bug 1195351 and bug 1195352 in response to this. Do we have a tracking bug?
Comment 4•9 years ago
|
||
Hi, I think, the problem mention here is not related to code split into chunk. I that specific case, the example display here: https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/Forms/How_to_build_custom_form_widgets#The_aria-selected_attribute is actually remotely taken from: https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/Forms/How_to_build_custom_form_widgets/Example_5 I suspect that "remote" call to be the source of the issue rather than splitting the code in chunk.
Comment 5•9 years ago
|
||
Ok, got it (I'll try to find some time this week to send a patch, no guaranty, so I do not take the bug) Basically when the feature is initialized it checks for the iframe id to retrieve the code within the current page. It should rather relay on the src attribute to get the right, possibly remote, URL's page to get the code from.
Reporter | ||
Comment 6•9 years ago
|
||
Hm. Okay. :davidwalsh seems to think there's also probably a problem with it not working properly if the code is in chunks, but we will tackle that separately.
Summary: Live sample "Open in Codepen/JSFiddle" buttons don't send code to service if sample is in chunks → Live sample "Open in Codepen/JSFiddle" buttons don't send code to service if code comes from another page
Comment 7•9 years ago
|
||
Pull request has been done here: https://github.com/mozilla/kuma/pull/3422
Updated•9 years ago
|
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Updated•4 years ago
|
Product: developer.mozilla.org → developer.mozilla.org Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•