Revision history [back]

How can a cell output its own ID?

I understand this works:

    C = sage.server.notebook.cell.Cell(0, '2+3', '5', None)
C.id()


But I don't know understand how you can find that out for some arbitrary cell.

So far, the only way I know how is to use the interact decorator, and see what cell ids are used in the HTML.

How can a cell output its own ID?

I understand this works:

    C = sage.server.notebook.cell.Cell(0, '2+3', '5', None)
C.id()


But I don't know understand how you can find that out for some arbitrary cell.

So far, the only way I know how is to use the interact decorator, and see what cell ids are used in the HTML.

EDIT:

Also, where is this javascript interact() function the interact documentation refers to a few times?

How can a cell output its own ID?

I understand this works:

    C = sage.server.notebook.cell.Cell(0, '2+3', '5', None)
C.id()


But I don't know understand how you can find that out for some arbitrary cell.

So far, the only way I know how is to use the interact decorator, and see what cell ids are used in the HTML.

EDIT:

Also, where is this javascript interact() function the interact documentation refers to a few times?

 4 retagged FrédéricC 3595 ●3 ●36 ●72

How can a cell output its own ID?

I understand this works:

    C = sage.server.notebook.cell.Cell(0, '2+3', '5', None)
C.id()


But I don't know understand how you can find that out for some arbitrary cell.

So far, the only way I know how is to use the interact decorator, and see what cell ids are used in the HTML.