Du befinder dig her:Indlejring af dokumenter på websider >> Brug af Eksportér for at generere HTML kildekode >> Eksportindstillinger

Brug af Eksportér for at generere HTML kildekode

Eksportindstillinger i alle versioner af TI‑Nspire™-softwaren gør det muligt for dig nemt og automatisk at generere den nødvendige HTML-kode og iframes, som er nødvendig for at indlejre et dokument i en iframe. Koden, som genereres ved at bruge Eksportér, producerer en iframe, hver gang en webside indlæses med JavaScript®. Det er mere fleksibelt og robust end en hårdkodet iframe. For eksempel vil anvendelse af JavaScript® gøre det muligt for dig at bruge relativ adresse til at henvise til dine indlejrede dokumenter. Med en relativ adresse vil websiden finde og vise dit dokument, så længe dokumentet bevares i samme mappe som HTML-filen. Dette er især nyttigt ved deling af offline websider.

Eksportindstillinger

Med TI‑Nspire™-software kan du eksportere dokumenter i HTML-format på to måder:

Eksportér webside
Brug denne indstilling til at producere et komplet HTML-dokument, der indeholder et indlejret vindue til dit TI‑Nspire™- eller PublishView™-dokument og supplerende tekst. Denne enkeltstående webside kan bruges uden ændringer eller kan forskønnes ved hjælp af tredjeparts software.
Eksportér HTML til Udklipsholderen
Brug denne indstilling til at producere en kodestump, som kan indsættes på eksisterende websider eller blogs. En kodestump indeholder få linjer HTML-kode, som indlejrer et vindue på en eksisterende side.

Hele HTML-dokument og kodestumpen kan nemt redigeres med en teksteditor eller en HTML-editor. Redigering af HTML-dokumentet gør det muligt for dig at:

Ændre kildens placering på det indlejrede TI‑Nspire™- eller PublishView™-dokument, hvilket kan være påkrævet for at udgive eller dele HTML-dokumentet.
Redigér HTML'en for at åbne TI‑Nspire™- eller PublishView™-dokumentet i et dedikeret browservindue.
Ændre udseendet på det indlejrede eller dedikerede vindue, som indeholder TI‑Nspire™- eller PublishView™-dokumentet.

Visning af kildekode

Efter websiden er oprettet, kan du se og redigere kildekoden. Kildekoden kan redigeres ved at bruge en teksteditor eller en tredjeparts HTML-editor. Visning af kildekode:

¢ I din webbrowsers menulinje skal du klikke på Vis > Kilde.

Bemærk: Indstillingen til at se kildekoden kan variere afhængigt af din standardbrowser.

—eller—

¢ Åbn en teksteditor såsom Notepad, og åbn derefter HTML-filen i teksteditoren.

Kildekoden vises.

Bemærk: I nogle browsere åbnes en teksteditor til visning af kildekoden.

Det følgende eksempel viser en kildekode, som indeholder kommentarer til at hjælpe dem, der ikke er bekendte med HTML, med at forstå og være i stand til at redigere koden.

 

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>

<!--

Thanks for creating a web page containing a TI-Nspire(tm) or PublishView(tm) document. This page can easily be modified to fit your needs. If you are not familiar with HTML, here are some basics to get you started:

HTML DOCUMENTS

HTML documents are text documents that define a web page.

The text itself is known as source code. You are viewing source code now.

HTML documents become web pages when opened in a browser.

HTML documents have a Header (usually hidden information) and a Body (displayed content).

TAGS

The appearance of your page is controlled by "tags".

Tags are surrounded by angle brackets <> .

Some elements require a start tag <> and an end tag </> .

LINES

Lines in the source file mean nothing when displayed as a web page.

Instead, tags are used to control lines on the page.

<br> creates a line break, just like hitting Enter key on your keyboard.

<p> creates a new paragraph. The browser will typically put empty space around this tag.

COMMENTS

Comments are used to explain the source file and are not displayed on the web page.

<!-- begin a comment.

- -> end a comment.

See http://www.w3.org/TR/REC-html40/struct/global.html for more information on HTML.

That's it!

Your page starts below.

-->

<head>

<!-- The line below tells the browser the Title of your Web Page. This may be displayed in title bar of your browser. -->

<title>TI-Nspire&trade; Interactive Web Page</title>

<!-- The lines below help browsers and search engines quickly get information about your page. These are not displayed on the page. -->

<meta name="author" content="Your Name">

<meta name="keywords" content="Your Keywords">

<meta name="description" content="Your Page Description">

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<meta name="keywords" content="&quot;ti-nspire document player&quot;,&quot;nspire document player&quot;,&quot;ti-nspire&trade; document player&quot;,texas instruments, education.ti.com, ti-nspire, ti nspire, nspire, tinspire, nspire cas, ti-nspire cas, computer, software, publishview, publish view, publishview(tm), tns file, tnsp file, document player, ti-nspire player, nspire player, player, interactive math, mathematics, cas, student understanding, interactive classroom, educator's classroom computer">

</head>

<body bgcolor="#FFFFFF" TEXT="#000000">

<!-- Note the background color and text color are included with the "body" tag. You can find out more about color codes here: http://en.wikipedia.org/wiki/Web_colors -->

<!--The lines below create a high level header centered on the page. It is very common to show the page title in this way. -->

<center>

<font size="5"><b>INSERT TITLE FROM DIALOG</b></font> <br>

</center>

<!--The line below creates a visible line across the page. It automatically adjusts to a % of the window width.-->

<hr width="80%" align="center">

<!--Remove comment tags from the line below to create a bold section title. .-->

<!-- <font size="4"><b>Instructions</b></font> <br> -->

<!--The text below will appear above your embedded TI-Nspire(tm) or PublishView(tm) document. You might use this space for instructions for the embedded activity. Spacing and returns are ignored. Word wrapping will happen automatically. -->

<p>

THIS AREA CONTAINS "TEXT ABOVE" FROM WEB PAGE TEXT DIALOG.

</p>

<!--The section below embeds the TI-Nspire document in your web page.-->

<p>

THIS AREA CONTAINS THE CODE SNIPPET THAT EMBEDS THE TI-NSPIRE(TM) OR PUBLISHVIEW(TM) DOCUMENT

</p>

<!--The text below will appear below your embedded TI-Nspire(tm) or PublishView(tm) document. You might use this space for guiding questions related to the activity. Spacing and returns are ignored. Word wrapping will happen automatically. -->

<p>

THIS AREA CONTAINS "TEXT BELOW" FROM WEB PAGE TEXT DIALOG.

</p>

<!--The line below creates a visible line across the page. It automatically adjusts to a % of the window width.-->

<hr width="80%" align="center">

<!--

Insert related links.

Insert links using the examples below as a guide. Type or paste the URL between quotation marks. Type the link text (visible on the page) after the URL bracket and before the ending tag '<a/>'. Note you can use comment tags to hide links without deleting them from the source code.

-->

<p>

<font size="1">

<a href="http://education.ti.com/educationportal/preference/selectCountry.do">Texas Instruments Education Technology<a/> <br>

<!-- <a href="http://education.ti.com/calculators/timathnspired/">MathNspired.com<a/> <br> -->

</font>

</p>

<!--

Insert an email link.

Remove comment tags from the line below, then type your email after "mailto:"

-->

<!-- <a href="mailto:username@yourserver.com">E-mail the author</a> -->

<!--

Insert an image.

Copy and paste the line below into the body of your document where you want the image to appear. Remove the comment tags, then replace the old image source URL or file name a new one. You might also want to provide alternate text (alt=) in case the image file is not available.

NOTE: If your image is not on the web, when you publish your page, you will need to upload your image file along with your html file.

-->

<!-- <img src="type_document_name.here" alt="This text appears if the image is not available" /> -->

</body>

</html>

 

© 2006 - 2012 Texas Instruments Incorporated